Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Append from a table with autonum
Message
De
07/06/2011 18:12:58
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Divers
Thread ID:
01513452
Message ID:
01513456
Vues:
41
I believe you can use
CursorSetProp("AutoIncError", .F.)
which essentially does not complain about the autonum field problems.



>Thanks for the quick response, Craig. Actually the receiving table also has an autonum field (they are both basically identical tables), so I'm not sure that appending from a temp cursor would help - wouldn't I get the same message?
>
>
>>You have to append to a temp table or cursor, populate the id column there with the values you want for the master table, then append from the temp to the master table.
>>
>>Or, write code to append a record at a time, update the id, then do the next record.
>>
>>>I'm copying table contents from one file to another and ran into an error while copying a table with an autonumber field. It says the field is read-only (which makes sense, I guess), and won't copy the records using an append from statement. Is there a quick/standard way to get around this? I know I could do a file copy, but was hoping to just pull records as needed from the other table.
>>>
>>>As always, thanks in advance.
Jim Nelson
Newbury Park, CA
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform