Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to connect to dbase3 files through ODBC from vfp?
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Novell 6.x
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01281313
Message ID:
01301722
Views:
7
>Hi Fred
>It fails with error 1229 ( too few arguments ), it says it expects 2...
>I think i found the reason for the error, i got the same error in a SELECT statement involving a character string:
>lnResult = sqlexec(lnHandle, [select * from countries where show="Y"], "myCursor" ) &&& this fails with same error 1229
>lnResult = sqlexec(lnHandle, "select * from countries where show=chr(89)","myCursor" ) &&& no error...
>I have character values in my INSERT command, so that's probably triggering the same error message.
>While i'd like to know how to pass the strings in my sql command, the main issue remains: when i insert a record in a specific db3 table, how do i update respective Index files??

For SQL, you need to use single quote, not double quote.
lnResult = sqlexec(lnHandle, [select * from countries where show='Y'], "myCursor" ) &&& this fails with same error 1229
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform