Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What's wrong with this statement in SQLEXEC( ) ?
Message
De
23/09/2005 19:12:15
Peter Wagner
Point Informática Ltda.
Limeira, Brésil
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 8 SP1
Database:
MS SQL Server
Divers
Thread ID:
01052565
Message ID:
01052617
Vues:
8
George,
thanks but when I run this statement it also returns the same erro message as it returned for Sergey.
"The conversion of char data type to smalldetime data type resulted in an out-of-range smalldatetime value"
It seems to me that it's necessary remove the slash "/" from the date to make it work.

[ ]'s
Peter

>>Fabio,
>>thanks !
>>So simple and I didn't see it ..
>>
>>[ ]'s
>>Peter
>>
>>>>Sergey,
>>>>If I run those statements:
>>>>
>>>>csql = "select * from prestacoes where data_venc >= '2005/09/23'"
>>>>csql = "select * from prestacoes where data_venc <= '2006/02/28'"
>>>>
>>>>It returns this message:
>>>>"The conversion of char data type to smalldetime data type resulted in an out-of-range smalldatetime value"
>>>>
>>>>How to solve this problem now ?
>>>>
>>>>Peter
>>>>
>>>
>>>
>>>
>>>csql = "select * from prestacoes where data_venc >= '20050923'"
>>>csql = "select * from prestacoes where data_venc <= '20060228'"
>>>
>
>Peter,
>
>While you have your answer, the real problem is that SQL Server 2000 always uses ANSI settings for things like datetimes. So
csql = "select * from prestacoes where data_venc <= '2/28/2006 00:00:00'"
should also work. The time portion of the above is optional.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform