waytech2003
Programmer
I have an Access 2000 database where a date is stored in a 10 character string "01-01-2006" I need to get the records that are between to ranges. I have tried the codes below and it will not work. I is ok if working with just one year (2005) but not a two year spread (Jan 2005 to Jan 2006)
"SELECT * FROM Table1 WHERE " _
"ReportDate Between '" & textbox1 & "' And '" & textbox2 & "' "
"SELECT * FROM Table1 WHERE " _
"ReportDate Between #" & textbox1 & "# And #" & textbox2 & "# "
"SELECT * FROM Table1 WHERE " _
"CDate(ReportDate) Between #" & textbox1 & "# And #" & textbox2 & "# "
Any ideas?
"SELECT * FROM Table1 WHERE " _
"ReportDate Between '" & textbox1 & "' And '" & textbox2 & "' "
"SELECT * FROM Table1 WHERE " _
"ReportDate Between #" & textbox1 & "# And #" & textbox2 & "# "
"SELECT * FROM Table1 WHERE " _
"CDate(ReportDate) Between #" & textbox1 & "# And #" & textbox2 & "# "
Any ideas?