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 MikeeOK on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Customised Quarters 1

Status
Not open for further replies.

MikeAuz1979

Programmer
Aug 28, 2006
80
AU
Hi,

What I'm trying to acheive (Access 2000) is to group daily data to a specific quarter where the quarters are:

Q1 06 Mar06-May06
Q2 06 Jun06-Aug06
Q3 06 Sep06-Nov06
Q4 06 Dec06-Feb 07

So the result I'm after looks like:

Date Quarter Year
01-Mar-06 1 06
23-Jan-07 4 06
05-Mar-07 1 07

This is similiar to thread701-892514 but that had different quarter periods for each customer wheras this has set quarters. (and I couldn't figure it out from this other thread.)

Thanks heaps for any help!
Mike


 
You should be able to just subtract 2 months from your date and then find the quarter:
DateAdd("m",-2,[DateField])

Format(DateAdd("m",-2,[DateField]),"q")


Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top