Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Max Length of SQL Pass-through string
Message
From
04/02/2002 12:41:38
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
04/02/2002 12:39:50
Arden Weiss
Liberty Computers Ltd.
Maryland, United States
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00614909
Message ID:
00614912
Views:
21
>A newbie here trying to use SQL pass-through to SQL Server 2000 with VFP7.
>
>I got it working, but there seems to be a 270 character max length to the string that I include in the SQLExec(hConn, "CREATE TABLE PTEST (field list....)") command. I get an invalid command error message when the string get to long.
>
>Is there a VFP setting to increase this length that I am overlooking?
>
>
>The workaround, of course, is to create and "SQLExec" a stored procedure, which is what I did. However, it would be nice to know if the 270 or so characters is a real limit or not -- and if not what is the max limit -- and where can that be set (further I would expect the limit to be 255 not 270).
>
>Puzzled here in Paradise -- and thanks in advance for any help.

Arden,
Dividing string into multiple works :

SQLExec(hConn, "CREATE TABLE PTEST (field list"+"....)")

For any quoted part limit is 255.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform