>>Hi all,
>>
>>I am creating a text string that I pass to SqlExec() to a SqlServer2000 database. This code runs fine when ran interactively from VFP8 but causes an invalid datetime string error when ran from VFP9. I run both versions of VFP without any bootup settings, meaning I am using the default VFP settings.
>>
>>
>>"CONVERT(datetime,'" + ttoc(datetime()) + "',101)" - works in V8 not in V9
>>"CONVERT(datetime,N'" + ttoc(datetime()) + "',101)" - works in V8 not in V9
>>
>
>What TTOC(DATETIME()) returns in each version?
I checked and I need to use TTOC(datetime(),2) for it to work in both version of VFP.
ramil
~~ learning to stand still