Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Query error using DTOC()
Message
 
 
To
23/01/2002 19:35:21
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00609459
Message ID:
00609469
Views:
11
The string created by DTOC() function is not good for comparison. You can compare date directly.
SELECT * FROM schedule WHERE beg_date >= {^2001/01/01}
>SELECT * FROM schedule WHERE DTOC(beg_date) > '01/01/2001'.
>This is giving me all the records from the table (25226)
>
>SELECT * FROM schedule WHERE YEAR(beg_date) > 2001
>This is giving me the correct number of records (2080)
>
>Both are valid queries. Correct ?
>What did I do to make the DTOC query not work anymore ?
>Am I going crazy ?
>
>Thanks, Ken
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform