Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error 1812 - SQL: Statement too long
Message
From
20/11/2004 20:28:17
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
20/11/2004 19:33:00
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Client/server
Environment versions
Visual FoxPro:
VFP 8
OS:
Windows XP
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
00963256
Message ID:
00963268
Views:
11
>>Roy,
>>Check sys(3055). Also if it's not a must for you to check with modified fields change wheretype to KeyFieldsOnly (would be a simple fix).
>>Cetin
>
>Just a few days ago, I was participating in another thread, about the same issue.
>
>If I understand correctly, changing the WhereType to KeyFieldsOnly would make you lose the automatic update management. IOW, VFP would not detect if another user has made changes. Do you understand it this way, too? What would be the solution?

No you wouldn't lose automatic update management.
Yes it wouldn't check other modified fields.
IMHO this setting (WhereType=1 KeyFieldsOnly) is what most applications need for most of the tables. I would prefer tracking other users' changes via a timestamp column rather than generating a long where clause (think you've 100 fields table and a where clause checks all of them).

Roy,
sys(3055) from help remarks section:
"For example, calling TABLEUPDATE( ) for a local table or view that doesn't use key fields generates a long WHERE clause to find the update row. The default number of fields supported in the WHERE clause is 40. If you receive the error 1812 - SQL: Statement Too Long, you should either use a key field for the update or increase the complexity of the WHERE clause with SYS(3055). If you use SYS(3055), increase its value to 8 times the number of fields in the table:

= SYS(3055, 8 * MIN(40, FCOUNT( )))"

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