Create the following function (this function was written to reflect Fed.
Gov. Quarters so change the values to correspond with your quarters)
-------------------------------------------------------
Function GetQuarter(DateToTest As String) As String
Select Case MONTH(DateToTest)
Case 10, 11, 12
GetQuarter = "Q1"
Case 1, 2, 3
GetQuarter = "Q2"
Case 4, 5, 6
GetQuarter = "Q3"
Case 7, 8, 9
GetQuarter = "Q4"
End Select
End Function
----------------------------------------------------------
In your query use the following as a field value
GetQuarter([join_date])
or in your code you can use the following
if GetQuarter(Join_date) = "Q1" then
.........
end if
"Allison" <(E-Mail Removed)> wrote in message
news:70f101c3e6ab$8ebc0a30$(E-Mail Removed)...
> Does anybody know how to use wildcards with dates? I am
> trying to write a piece of code that will return
> join_date is any time in January quarter = Q1 etc.
> My join_date is formated mm/dd/yy. Any suggestions would
> be greatly appreciated!
|