NickBridgens
Registered User.
- Local time
- Today, 12:07
- Joined
- Nov 29, 2001
- Messages
- 13
I am trying to get my head round DoCmd.RunSql. I have a bit of code...
strSQL = "DELETE * FROM Cases WHERE [DateOut] >= #" & DateForDeletion & "#;"
DoCmd.RunSQL strSQL
They work.
Change DELETE to SELECT and it won't ("A RunSQL action requires an argument consisting of an SQL statement").
I am also trying to run a query form which collects filters from various fields if they are filled in to give a big SQL filter. Same problems.
Any clues where I am going wrong?
Cheers
Nick Bridgens
strSQL = "DELETE * FROM Cases WHERE [DateOut] >= #" & DateForDeletion & "#;"
DoCmd.RunSQL strSQL
They work.
Change DELETE to SELECT and it won't ("A RunSQL action requires an argument consisting of an SQL statement").
I am also trying to run a query form which collects filters from various fields if they are filled in to give a big SQL filter. Same problems.
Any clues where I am going wrong?
Cheers
Nick Bridgens