LarryViles
Programmer
In Access 2003 I have the following statement as part of a report. I wish to change the literal '8' to a more user friendly variable (like ThisMonth). Every attempt to do so results in an error message.
rst.Open "SELECT [Birthday Query Sub].[1stResident], DatePart('d',[1stBirthday]) AS Birthdate FROM [Birthday Query Sub] WHERE (((DatePart('m', [1stBirthday])) = 8)) ORDER BY DatePart('d',[1stBirthday]);"
Larry
rst.Open "SELECT [Birthday Query Sub].[1stResident], DatePart('d',[1stBirthday]) AS Birthdate FROM [Birthday Query Sub] WHERE (((DatePart('m', [1stBirthday])) = 8)) ORDER BY DatePart('d',[1stBirthday]);"
Larry