How do you sort 2 date fields in assending order (query or report)

I have 2 DOB fields (client and spouse) in a table that I currently print off 
the birth month and call them on their b-day.  I really wish I could figure 
out how to get them to print/display in assending order of date (ie: 11/1 
followed by 11/2) even if the spouse is before the client.  Is this possible 
without having to do a bunch of programming?  Thanks!
0
Utf
11/17/2009 7:27:01 PM
access.queries 6343 articles. 1 followers. Follow

1 Replies
1859 Views

Similar Articles

[PageSpeed] 56

Yep.   Use a calculated field like this --
  DOB_Sort:   IIF([Client_DOB]<[Spouse_DOB], [Client_DOB], [Spouse_DOB])
 
-- 
Build a little, test a little.


"KnowEnough2BDangerous" wrote:

> I have 2 DOB fields (client and spouse) in a table that I currently print off 
> the birth month and call them on their b-day.  I really wish I could figure 
> out how to get them to print/display in assending order of date (ie: 11/1 
> followed by 11/2) even if the spouse is before the client.  Is this possible 
> without having to do a bunch of programming?  Thanks!
0
Utf
11/17/2009 7:32:01 PM
Reply:

Similar Artilces:

Outlook 2002 Contact Phone Number Field Formatting
Why don't phone numbers entered in the phone number contact fields on Outlook 2002 automatically format to include the paren's and hyphens? If this is suppose to happen, what is the setting to make it happen? They do here and always have. What are you seeing? --� Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. After searching google.groups.com and finding no answer mike <michael.kelner@fmr.com> asked: | Why don't phone numbers entered in the phone number | contact fields on Outlook 2002 automatically format to | include th...

Cash Sales Entry #2
How to do a cash sales entry? You mean a cash-basis accounting type of entry or a sales transaction where you are receiving cash (as opposed to check or credit card)? New User wrote: > How to do a cash sales entry? ...

Where's the Sort by New Message option?
Not sure when the layout of the newsgroups changed but I can't seem to find the ability to sort by new message in a thread instead of sorting by just the original thread date. That was hugely helpful as I could follow along and see what threads were still active. If you're gonna hang around in the newsgroups (any newsgroups), you may want to start using a newsreader. Microsoft Outlook Express can do it for you. Saved from a previous post: You may want to connect to the ms newsserver directly: If you have Outlook Express installed, try clicking on these links (or copy and paste i...

Linking Outlook fields from the "Contact Folder" to a custom form in Outlook...
Using Exchange Server 2003/Outlook 2003, we have created a custom Help Desk form in Outlook. We would like the ability to link specific fields from the Contacts Folder (Example B), in a drop-down list box if possible. We are far from knowing that something like this is even possible. Would appreciate *any* suggestions. Thank you. ...

Chinese antique #2
Q2hpbmVzZSBhbnRpcXVlCndvcmxkIGZpcnN0LCB0aGUgYW50aXF1ZSBjaGluYXdhcmUgc2VyaWVz IHBsZWFzZSB3YXRjaCEKRW50aXJlIGZpZGVsaXR5IDEwMCUgQW50aXF1ZSAoMTkxMi0xOTQ5KSBS ZXB1YmxpYyBvZiBDaGluYSBwb3JjZWxhaW4KdGVhcG90IDg4OCBjaGluYXdhcmVzIDQwMCBwbGVh c2Ugd2F0Y2hpbmchCldlYnNpdGUgaHR0cDovL3d3dy54ang1ODguY29tCkUtbWFpbCB4anhfNTg4 QHRvbS5jb20KQ2l0eSBTaGVuZ3pob3UgWmhlamlhbmcgQ2hpbmEKCsirx/LOqNK7oaK5xbattMnG 98+1wdDD8bn6tMmy6Lr4ODg4sNHH67nbyc2joQrIq8fyzqjSu6GiyKuxo9XmucW2rbTJxvfPtcHQ w/G5+rS/ytbWtLTJsui6+Dg4OLDRoaK0ycb3NDAwvP7H67nbyc2howq5xdLV0Pm5xbatytWy2Nau trwKzfjVvqO6aHR0cDovL3d3dy54ang1ODguY29tCrXn08qjunhqeF81ODhAd...

Sorting
Hi, is it possible to use variable for sorting? Something like: declare @sort varchar(10) SET @sort='column1 DESC' SELECT ROW_NUMBER() OVER (ORDER BY @sort)AS rowId, * FROM table Is dynamic SQL only option? Thank you, Simon On 15/04/2010 11:28, simon wrote: > Hi, > > is it possible to use variable for sorting? > > Something like: > > declare @sort varchar(10) > SET @sort='column1 DESC' > > SELECT ROW_NUMBER() OVER (ORDER BY @sort)AS rowId, * FROM table > > Is dynamic SQL only option? You can use CASE to he...

Summarizing a Report
I have a database linked to an excel file for the table. The excel file contains the results for a school archery tournament. Each school is allowed to have 24 archers but only the top 12 count as a team score and 4 must be male and 4 must be female. My report works fine giving me the top 12 and a team total for each school and division, but it does not ensure the gender ratio is met. Any ideas?? Also, I would like to create a report that shows just the schools and team totals, but the only place I currently have team totals is in a report. -- Thanks, Cubbie You w...

How to Merge Date from 3 columns to 1
I have a spreadsheet where the date is spread over 3 columns I,J & K and I wish to merge them to Column B in the format dd-mmm-yyyy as shown below. B I J K 02-Feb-2003 02 Feb 2003 27-Mar-1999 27 Mar 1999 01-Apr-1978 Apr 1978 01-Jan-1998 1998 14-Jun-2002 14 Jun 2002 Where there is a blank for the day in 'Column I' I need it to copy as 01 and where there is a blank for the month in 'Column J' I need it to copy as Jan. Where all 3 column...

How to sort account list?
I'm using MS Money 2004 Small Business. In the account list, my accounts are catagorized by and in this order: - bank accounts - credit accounts - investment accounts - loans and liabilities - asset accounts TOTAL BALANCE In the above view, I cannot easily determine totals for assets and liabilities. The following view does this. - bank accounts - investment accounts - asset accounts SUBTOTAL -loans and liabilities SUBTOTAL TOTAL BALANCE How do I get the above view? Thanks, Brett I don't use Small Business. But you can run a Net Worth report to get total assets and ...

link comments? #2
is there a way to link comments in excel? maybe a tool or something? haven't been able to find one, but i'm hoping someone else has. Thanks in advanc -- Message posted from http://www.ExcelForum.com No, but here are some answers to some similar questions, if they don't do what you want at least you can make your question less ambiguous as to what is supposed to be showing where knowing that it can't be a link. http://google.com/groups?threadm=406E16B7.2F2F026B%40msn.com http://google.com/groups?threadm=008e01c2aa5d%24906517e0%248ef82ecf%40TK2MSFTNGXA04 http://goog...

How to prevent ole container hwnd receive certain messages? #2
I used CSubclassWnd of Paul DiLascia to subclass(in fact use SetWindowLong to replace WindowProc) hwnd returned from IOleWindow::GetWindow. In the WindowProc I prevent it by LRESULT CShellEmbedding::WindowProc(UINT msg, WPARAM wp, LPARAM lp) { if (msg == WM_WINDOWPOSCHANGING) return 0; return CSubclassWnd::WindowProc(msg, wp, lp); // Important!! } but spy++ still tell me that hwnd of ole get the send WM_WINDOWPOSCHANGING message and return. So Is it right way to eat message in win32 or ole container hwnd does special things? "Su Wei" <suwei@sina_com> wrote in message new...

COUNT function 2 Columns
I have two columns of data, CATEGORY and NUMBER, and want to be able to COUNT the number instances where CATEGORY = X and NUMBER = Y. I know how to use the COUNT function on each column, but I don't know how to use it on two columns. Thanks! James, how about something like this =SUMPRODUCT((A2:A25="test")*(B2:B25=24)) -- Paul B Always backup your data before trying something new Please post any response to the newsgroups so others can benefit from it Feedback on answers is always appreciated! Using Excel 2000 & 2003 ** remove news from my email address to reply by ema...

Row names will not move with sort
Each row in my summary table in Sheet1 is hyperlinked to a corresponding table in Sheet2 with additional details. I need to move the rows in my summary table (Sheet1) and preserve the links to and from the details tables (Sheet2). I found that I can move rows in Sheet1 with cut & insert and the hyperlinks are maintained. I can travel from a row in summary table (Sheet1) to details table (Sheet2) and back, even after the corresponding row (Sheet1) was moved. But if I sort the rows in Sheet1 the links from Sheet2 back to corresponding rows in Sheet1 lead to presorted locations. Apparen...

Probably very easy question conerning auto-changing dates
I've got a list of dates in column B. Row 1 is labeled "date", Row 2 starts my date data (May-04). I want a list in column B of the preceding 23 months, so columb B ends with Jun-02. Obviously, I can manually input this information. What I can't figure out is how if I go and change the first date (say, to Jun-04) it will auto-change my list of dates accordingly (so my list would now end in Jul-02). NOTE: I know how to create a handle-fill, but it won't update any changes I make to the dates, nor can I get it to go backwards, chronologically. Thanks, Jacob jfarino@ameris...

Quickbooks #2
Does MRMS support the class field somehow for integrating with QB2003 or higher? Multiple SO's to connect to the same QB file but need to know which SO the information came from. Since we're looking to integrate with QB what G/L entries may be created at the HQ level that we may need to be concerned with? Thanks, Mike McCormick RMS does not integrate with QB at the HQ level only at the store level as far as I know... mt "Mike McCormick" <mike@muellercpa.net> wrote in message news:OsfSLlr7FHA.1416@TK2MSFTNGP09.phx.gbl... > Does MRMS support the class fiel...

Weekdays #2
Hello, I have in column "A" row "10" the date as follow: 15-Feb-05. It is possible to get in column "B" row "10" the day of the week as follow: Monday ? Regards, Hi Jeff Try putting in B10 =CHOOSE(WEEKDAY(A10),"Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday") However, you may find that it is a Tuesday, rather than a Monday - at least in the UK!!! -- Regards Roger Govier "Jeff" <Jeff@discussions.microsoft.com> wrote in message news:790A5...

sorts not sorting
OK- Thanks to everyones help I now i have a list i can work with... but there are a few problems.... the zips are all 5 digit and now i have to sort them... the problem is, THEY WONT SORT CORRECTLY!!!!!!! The numbers are not in order... some are but a lot are not... is there anyway to fix this???? i need to sort them by zip code but cant seem to get them to do it correctly.. any ideas??? ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ You are going to be far better of...

Using a ComboBox for parameters for a query
HI, I have a form that i want to show query results based on the parameters of names, or dates. I was wondering how to make the query change based on what i chose from combo boxes. Also, how do you make the results show up on the form itself. Thanks in advance. ...

import- number- sort?
I imported this data into a spread sheet- I tried to format it to number, but when I sort it- I get : 37.08 4.33 4.79 4.8 42.56 5.94 Whats up with this? Thanks Brent Hi Brent, Install the TrimAll macro, select the column and invoke the macro from Alt+F8 http://www.mvps.org/dmcritchie/excel/join.htm#trimall Directions to install and use a macro at http://www.mvps.org/dmcritchie/excel/getstarted.htm#havemacro I expect that you have spaces or CHAR(128) "Required Blank" characters in you data you can check is =LEN(A1) --- HTH, David...

2 copies coming into Inbox
I recently paid for a hotmail account so I could have larger storage and not get cancelled for any reasons such as not checking it often enough. I followed the instructions and put my service on Outlook Express. Now I'm receiving 2 of every message. What's up? Can I fix this? Thanks Darla ...

date formula #2
Hi i am trying for a way to work out how i can formulate the date, ie. if today is 17 November 2003, i want to import data from date 1 Novemeber 2003 how would i do this and what formulae would i use? any idea ----------------------------------------------- ~~ Message posted from http://www.ExcelTip.com ~~View and post usenet messages directly from http://www.ExcelForum.com =today()-1 GB "jaggosai" <jaggosai.x32sz@excelforum-nospam.com> wrote in message news:jaggosai.x32sz@excelforum-nospam.com... > > Hi i am trying for a way to work out how i can formulate the dat...

Set Tab Order
Is their a way to set the tab order in an Excel spreadsheet when I have protected the sheet - so you skip over locked cells to get to only the uprotected cells? Hi in the protection dialog uncheck 'select locked cells' -- Regards Frank Kabel Frankfurt, Germany <anonymous@discussions.microsoft.com> schrieb im Newsbeitrag news:13a4701c44434$ad8773a0$a301280a@phx.gbl... > Is their a way to set the tab order in an Excel > spreadsheet when I have protected the sheet - so you skip > over locked cells to get to only the uprotected cells? ...

Merge Calendars #2
This is a multi-part message in MIME format. ------=_NextPart_000_000A_01C933B3.3076E2B0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable I have 1 laptop and 1 PC. Can I merge Outlook Calendar Data into one = machine? I have Windows XP SP3 on both machines connected in a home network. Both have MS Office 2002 (XP) SP3. Could I use a internet base program to help me on this task? I want to do this before I upgrade to MS Office Pro 2007. Thanks, Carlos. ------=_NextPart_000_000A_01C933B3.3076E2B0 Content-Type: text/html; charset="...

Customising Crystal Reports + File Location
Hello, We have installed Crystal 9 with the CRM Enhancement pack on top of it. What i was wondering is there a list where i can know which report in crm is for what? All i see is lots of folders with funny names like 9e4361ec44fd1190.rpt is there anyway you can get logical names from? Should you create your own report where would you save in in CRM to be able to access in via the crm menu? Thanks and Regards -- Fakhruddin Zavery Sr. Systems Analyst / Programmer CATS Tanzania Ltd. NIC Life House 4th Floor P. O. Box 2569, Dar es Salaam, Tanzania Tel. +255-22 2137915, 2112631 Fax +255-22 ...

sorting macro #3
I need to sort on 8 cells in a row and on 1500+rows. I can do it one at a time but I know there must be an easier way. Can ANYONE HELP? C3:J3 I need these cells sorted and then down to C1532:J1532 I did create a macro to sort after I selected them but still one at a time. Does it have to be a macro? I can edit a macro but don't really know how to program them. Yes, it has to be a macro. The following should do it. This macro loops through all the entries in Column C, and in each row it sorts the values in Columns C:J. HTH Otto Sub SortRows() Dim rColC As Range Dim i As...