>Hi Nadya,
>
>If you truly need uniqueness spanning multiple tables, look at using a GUID. I think Rick Strahl has some GUID API code on his website and they might have some here as well.
My article on primary keys (
http://www.utmag.com/May2002/Page14.asp) lists the functions for creating a GUID.
Note that a GUID is fairly big for a PK - 16 bytes. A shorter PK, useful for disconnected sites, might be to assign each site a unique number, and then use something like bintoc(site, 2) + bintoc(SerialNumber("TableName")), where SerialNumber uses the usual approach of saving the sequences in a table. This makes a total of 6 bytes (if more than 65,000 sites are required, 8 bytes).
I must add that I never tried this in practice, though.
Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)