>Hi everybody
>I have created a VFP9 view to get data from MS-SQL Server 2005. I want to filter records for a datetime filed. I have written datetime value like {^2011-01-01 00:00:00} but it does not accept. Any idea please. I do not want to use local view after it to make filter.
>
>Regards,
Use DATE() or DATETIME() function to generate the value you want and then use Parameters instead of built-in values:
ldDateTime = DATETIME(2011,1,1)
SQLEXEC(Handler, "SELECT * FROM YourTable WHERE DateTimeColumn = ?m.ldDateTime","crsCursor")
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.