Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

sort date field on two criteria(calculated date range)

Status
Not open for further replies.

punky

Programmer
Mar 21, 2001
29
US
I have a field called DateOfIssuance, it is mmddyyyy.
I need to sort it so the date range can span from one
year to the next. ie: mmdd must be greater than
May 15 and year must be calculated as (year + 1) with
new mmdd less than May 16 of the next year.

How do I create a new sort field for this date so the span is from ie: May 16, 2001 thru May 15, 2002.





 
Assumiing that you know the start date, dateadd (with appropiate arguments) will get you to the desired enddate. Just look it (DateAdd) up in the HELP system.


MichaelRed
redmsp@erols.com

There is never time to do it right but there is always time to do it over
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top