Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Transfer character TO Date Format
Message
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
Miscellaneous
Thread ID:
01391975
Message ID:
01391981
Views:
42
>The CTOD function can only convert particular string formats to a date. If it does not recognize string as a date it returns empty date. What is the format of the values stored in TempCrystal.ddepart ?

Hi Sergey,

here is a part of the sql request...

E.ddepart is a datetime Expression that converted in a caractere expression with "TRANSFORM( E.ddepart ,"@E" ) AS ddepart,"

now i want convert to this Field To a date Format ( CTOD() ).
 E.nType = CA_LOC 		, cCA_LOC ,;
   E.nType = RS_LOC 		, cRS_LOC , ;
   E.nType = CS_LOC 		, cCS_LOC , '' ) , 4 ) AS 'cType',;
   TRANSFORM(  E.ddepart ,"@E" ) AS ddepart,;
   TRANSFORM(  E.dretour ,"@E" ) AS dretour,;
   E.nPosCat,;
   E.ncause,;
   E.nType = CS_LOC AS lcourtsej ,;
   c.cpseudcode,;
>
>
>>
>>I want to transform a caractere expression to a date Format.
>>Please see attachment because i have a strange result.
>>
>>
>> m.dte_Sortie =  CTOD( TempCrystal.ddepart )
>>
>>
>>TempCrystal.ddepart is not empty and m.dte_Sortie give a empty string !?
>>thank in advance For help
>>
>>bernhart
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform