Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Where is the dbf of my cursor?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00132835
Message ID:
00133388
Vues:
14
>Carlos,
>
>Perry and Nancy are correct in their advice. You have been and are depending on an undocumented side effect which can fail at any time. If you need an actual table as the result of your select then select into a table.
>
>The help file is mnisleading when it says that there will be a dbf on disk. Your DBF() function is telling you what name the dbf will get when the result set is large enough to require a dbf. The use agin trick is no longer needed in VFP. You can use an updatable view istead, or you can select into table.
>
>You have encountered the reason that USE AGAIN is not a good solution for creating modifiable tables. If your only purpose is to add fields to the result you can do that within the SELECT syntax.
>
>SELECT Field1, Field2, 000.00 AS Balance ... INTO CURSOR MyResult
>
>Of course the cursor will be read only as it should, change the code to;
>
>lcTable = SYS(2015)
>SELECT Field1, Field2, 000.00 AS Balance ... INTO TABLE (lcTable)
>
>will give you an updatabel table as the result.


SELECTING into a table now gives you the problem of multiple users trying to share the same table name. With a cursor, each user keeps his own data with no conflicts from the other users.
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform