Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Insert record and return value
Message
De
29/09/2004 13:56:18
 
 
À
29/09/2004 13:22:01
Jerry Tovar
Dana Corporation Dana It
Maumee, Ohio, États-Unis
Information générale
Forum:
ASP.NET
Catégorie:
ADO.NET
Divers
Thread ID:
00946845
Message ID:
00947277
Vues:
14
Jerry,

As a follow-up, you might want to post a message over on the VFP forum regarding ways to determine the auto-inc value from an insertion. I know the question has been asked before, and I don't recall any responses, but you might want to try anyway.

I mentioned further down this thread yesterday that one way might be to do your insertion as part of a stored proc, maybe inside a transaction, and then find some way to 'get to' the row you just inserted.

Perhaps the table you're inserting into has a combination of columns that are unique (invoice #, order #, ssn #, etc.)...you could query against the value that you inserted to get the auto-inc value. If not, 'maybe' you could do a MAX on the auto-inc column or something like that, but I would want to do a great deal of testing, especially if it's in a multi-user environment.

But I have not tried these myself, you may want to ask others on the fox forum and/or give these a try yourself).

Again, sorry for taking you down a dead-end! (I just posted a final message, after seeing this topic discussed on the fox forum today, that may be of some help)
Kevin
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform