Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
TableUpdate and SQL string is too long
Message
De
10/11/2004 12:34:50
 
 
À
10/11/2004 10:06:35
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00959751
Message ID:
00960100
Vues:
11
Hi Hilmar, that was the trick, thanks a lot for pointing that out.

This is what's going on: when you check "Key and updatable fields" in the view designer, the SQL statement includes all fields in the WHERE clause to check for conflicts with other users. That means a long SQL statement.

When checking "Key fields only", then SQL only includes a few (or one) field in the WHERE clause to check for conflicts with updates of other users.

This is why I did not have the error when I used tableUpdate(.t., .t.), i.e. forcing all rows, as is almost the same as saying "Key fields only" (conflicts in the primary key are very, very rare).

What I loose using "Key fields only" is the automatic conflict management, which I can do elsewhere. But at least the view is working, and I know why it is working know. Thanks a lot.

Regards,
Javier.

>>Hi Hilmar, with your answer I have two more questions:
>>- Is the SQL statement out of limits with 100 fields? I think VFP limit is of 8 KB per statement, which is a lot
>>- Why does the error go out when I force all rows to be updated?
>
>I don't know the answers. But I still think that you should try "key fields only", to see if that works better.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform