Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Parsing SQLPREPARE()
Message
 
 
To
21/05/1998 06:30:23
Robert Byrd
National Association of Homebuilders
Washington, District of Columbia, United States
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00100744
Message ID:
00100934
Views:
37
>If I have a SQLPREPARE() statement such as:
>
>SQLPREPARE('select na_id, na_liid from list','foobar')
>
>and I want to parse it as follows:
>
>SQLPREPARE('select na_id, ;
>na_liid ;
>from list', ;
>'foobar')
>
>it will compile but will not execute.
>
>If I have a SQLPREPARE() statement such as:
>
>SQLPREPARE('select na_id, na_liid from list','foobar')
>
>and I want to parse it as follows:
>
>SQLPREPARE(''select na_id, ' + ;
>'na_liid' + ;
>'from list,'' +, ;
>'foobar')
>
>it too will compile but will not execute.
>
>Is there a way to parse long SQLPREPARE() statements to make them more readable and printable. Or am I parsing it incorrectly?
>
>Bob
>
>it will compile but will not execute.

SQL is picky about the use of single and double quotes. For example:
select oddfieldname as "GoodFieldName"
has to have the output field name in full quotes. But
...where somefield = 'somevalue'
needs to be in single quotes. Most likely your problem lies in how and where you use which set of quotes.
Mark McCasland
Midlothian, TX USA
Previous
Reply
Map
View

Click here to load this message in the networking platform