Month number in quarter

B

Bill Gates

Hello,

I have a date called invoice date and show the dates that are in a specified
quarter. How do I then check what month of the quarter the date is in. For
example, July is in quarter 3 and is the first month in that quarter. Is
there a function that will allow me to calculate this without a rediculously
large if statement?

Thanks in advance
 
N

Nikos Yannacopoulos

IIf(Month(dt) Mod 3 = 0, 3, Month(dt) Mod 3)

where dt is the date, will do it.

HTH,
Nikos
 
Top