Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sql
Message
From
22/07/2002 15:12:09
 
 
To
22/07/2002 11:50:29
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Title:
Re: Sql
Miscellaneous
Thread ID:
00681185
Message ID:
00681315
Views:
24
>I need to execute an sql statment in a recordset.for example
>rst.open "SELECT * FROM rst WHERE field1 >= variable1 AND field1 <=variable2"
>
>Is this right.

Can't be done. You can use a Filter like so:
rst.Filter = "field1>=" & variable1 & " AND field1<=" & variable2
If var1 and 2 are strings then you need to enclose the values within quotes.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform