ADO - SELECT FROM [Tablename] WHERE [MyDate] < ...
Hi, i post from Italy, and i have the following question for you about Excel VBA
I am trying to import records from a closed Access DB, but i don't know how to select DBfields according to a specified date.
i want to select only the records where the field 'DateOfBirth' is < than 'MyDate', f.e. 01/02/1975.
i tried with the following code, but the VBA has gone debugging.
szSQL = "SELECT * FROM RAS WHERE [MyDate] > [DateOfBirth]"rs.Open szSQL, cn, adOpenKeyset, adLockOptimistic, adCmdText
could you please tell me where is the error?
thaenks in advance