nakedbamboo
Technical User
I have a query that I am trying to get to work. I had it working perfectly until I added a piece and I would like to figure out why it is not working. Below is a snippet of the query that uses a form as its source.
(((Alumni.CurrentCity)=[Forms]![AlumniSearch]![CurCity])) OR
(((Alumni.CurrentState)=[Forms]![AlumniSearch]![CurState])) OR
(((Alumni.PermCity)=[Forms]![AlumniSearch]![PermCity])) OR
(((Alumni.PermState)=[Forms]![AlumniSearch]![PermState])) OR
(((Alumni.[Undergrad Grad Date])>=[Forms]![AlumniSearch]![UDD] And (Alumni.[Undergrad Grad Date])<=[Forms]![AlumniSearch]![UDD2])))
Everything worked good until I added the last criteria. I am trying to get all records between two dates: UDD and UDD2 on the search form. The dates are a custom format (mm/yyyy) created with a mask (00\/0000;. The query appears to function as long as the two dates don't span different years, i.e. I can search 01/1999 to 12/1999. But if I search for 12/1998 to 12/1999, it will not return any results. I am wondering if it has to do with the custom format. Any guesses as to what the problem may be? If it is the mask causing the trouble, how would I do this with only a month and year entered? Thanks for any help.
(((Alumni.CurrentCity)=[Forms]![AlumniSearch]![CurCity])) OR
(((Alumni.CurrentState)=[Forms]![AlumniSearch]![CurState])) OR
(((Alumni.PermCity)=[Forms]![AlumniSearch]![PermCity])) OR
(((Alumni.PermState)=[Forms]![AlumniSearch]![PermState])) OR
(((Alumni.[Undergrad Grad Date])>=[Forms]![AlumniSearch]![UDD] And (Alumni.[Undergrad Grad Date])<=[Forms]![AlumniSearch]![UDD2])))
Everything worked good until I added the last criteria. I am trying to get all records between two dates: UDD and UDD2 on the search form. The dates are a custom format (mm/yyyy) created with a mask (00\/0000;. The query appears to function as long as the two dates don't span different years, i.e. I can search 01/1999 to 12/1999. But if I search for 12/1998 to 12/1999, it will not return any results. I am wondering if it has to do with the custom format. Any guesses as to what the problem may be? If it is the mask causing the trouble, how would I do this with only a month and year entered? Thanks for any help.