Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Check for dates
Message
 
 
General information
Forum:
Visual FoxPro
Category:
Client/server
Title:
Miscellaneous
Thread ID:
00805497
Message ID:
00805502
Views:
23
>What technique do you guys use to check for a date range in SQL2000?
>
>Let's say I want to bring records between 1/1/2003 and 1/10/2003? What Transact SQL (not foxpro syntax) syntax would you use to bring back those records? I'm using sql passthru.
>
>Thanks

The easiest way would be to use SQLEXEC parameters.
lcDateStart = {^2003/01/01}
lcDateEnd   = {^2003/01/10} + 1
lcSql = [SELECT * FROM mytable WHERE mydate >= ?lcDateStart AND mydate < ?lcDateEnd ]
? SqlExec(lnConn, lcSql, "aaa")
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform