Walter Meester
HoogkarspelPays-Bas
Information générale
Catégorie:
Codage, syntaxe et commandes
David,
>If you want a unique, primary key, and don't need an incremented, numeric key, you can use SYS(2015) for the default value. It is faster than using a table to maintain an incremental key, and won't generate duplicates if the NextID table ever gets messed up.
Yeah, I know. Very, very nasty. And the clients can't do anything to resolve the problem if he can't change it on its inputform.
>There is a very tiny possibility that multiple users can generate a duplicate key if they both call the function at the exact same millesecond.
Not if you use a RLOCK() before increasing the value.
Walter,
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement