Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Best way to generate PK on SQL table
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00459598
Message ID:
00459774
Vues:
28
>Do you create the GUID with a row global unique identifier column in SQL using NewId() as the default value for the field? If so, how do you retrieve the value of this field when a new record is inserted?

I think I would call the NewID() function explicitly. I do not know of a way to get the value back if you use NewID as the default for a column. And I would not think this is much overhead, going to the server twice (calling NewID, then inserting the record).
Chris McCandless
Red Sky Software
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform