Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
What's wrong with this SPT containing dates
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
What's wrong with this SPT containing dates
Environment versions
Visual FoxPro:
VFP 8 SP1
Database:
MS SQL Server
Miscellaneous
Thread ID:
01134926
Message ID:
01134926
Views:
68
Hi all

Can anybody suggest what may be wrong in this SPT to MS-SQL. It just returns -1 for the SQLEXEC():
StartDate = thisform.fromdate.value
EndDate = thisform.todate.value

TEXT TO cVar NOSHOW TEXTMERGE
   SELECT CAST(RTRIM(charfield) AS char(10)) AS charfld,
      <<m.StartDate>> AS StartDate, <<m.EndDate>> as EndDate
   FROM myTable
   LEFT JOIN ...
   WHERE ...
      AND fld_EntryDate >= <<m.StartDate>>
      AND fld_EntryDate <= <<m.EndDate>>
   ORDER BY ...
ENDTEXT

SQLEXEC(nHndl, cVar, "curname")
Regards
Bhavbhuti
___________________________________________
Softwares for Indian Businesses at:
http://venussoftop.tripod.com
___________________________________________
venussoftop@gmail.com
___________________________________________
Next
Reply
Map
View

Click here to load this message in the networking platform