Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Last NN entries
Message
De
10/05/2000 13:11:00
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00368038
Message ID:
00368219
Vues:
26
>>In these scenarios, the PK must either be generated with a node multiplier to guarantee uniqueness, or using CoCreateGUID.
>
>Hi Erik,
>
>PMFJI, what's a node multiplier and a CoCreateGUID? I know what a GUID is, I've just never heard those terms before.
>

Some value that is assigned to each entity that can create a new record. That entity then appends the value to the PK to stamp it as globally unique. As long as each "node" has a unique node value, none of the PKs should be duplicate.

Alternatively,

lcGuid = SPACE(16)
DECLARE INTEGER CoCreateGuid IN "Ole32.dll" STRING @
=CoCreateGuid(@lcGuid)
lcNewPK = lcGuid

Creates a globally unique 128 bit identifier using the same algorithm used by all other windows computers. This value is virtually guaranteed to be unique across space and time. IOW, noone, nowhere, on any machine will ever create the same value.
Erik Moore
Clientelligence
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform