Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP & SQL Server: Dates
Message
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00402704
Message ID:
00402726
Views:
8
>
>lcInstruction = "Update clients set date_payment = '" + ttoc(ldDatePay) + "' where codCli = ....."
>
>When i do a SELECT instruction from my table, i see that the date value is 2000-08-09, but the value of my update is wrong. And, to help wprst a little bit, TTOC() function doesn't give a dam with the SET DATE ...
>

Ricardo,
I use the SQL Server T-SQL function CONVERT() for my datetimes.
lcsqlexec = [update clients set date_payment = convert(datetime,']+;
   transform(ldDatePay)+[' where codCli = .....]
lnretval = sqlexec(lnsqlconn,lcsqlexec)
HTH.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Reply
Map
View

Click here to load this message in the networking platform