Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Last NN entries
Message
From
10/05/2000 13:11:00
 
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00368038
Message ID:
00368219
Views:
27
>>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
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform