Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
ADO Properties - string length limits
Message
From
27/01/2003 14:20:59
Jorge Haro
Independent Consultant
Juarez, Mexico
 
 
To
25/01/2003 20:18:17
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00745481
Message ID:
00745916
Views:
16
Your best bet is to use stored procedures, that will take care of the length problem, and seems to be the most recommended method anyway. I ran into similar problems but it was usually because I stored the source in a property of a VFP object, so I had to break up statements in 2 or 3 properties and turned them into one statement wich I would place in Recordset.Source at runtime, still you're better off working with stored procedures IMO.

>I am still messing with ADO for my VFP to SQL Server application and am starting to run into some problems when long (500 or so character) strings are assigned to things like RecordSet.Source or Command.commandText.
>
>I have statements like "select -a number of fields- from x where -big where statement-" which works great until the total number of characters reaches just under 500. Then the statment appears to be chopped off and I get an invalid statement SQL error. I'm trying to avoid transfering more data than I have to do I'd rather not do the filtering on the client.
>
>Are such ADO limits documented somewhere? Is there a way to break things up (separate the field list from the where clause)? Is there an ADO technique which allows larger strings? Should I bag it and use SQL passthrough which I don't know anything about...
>
>Thanks again,
>Pat
Previous
Reply
Map
View

Click here to load this message in the networking platform