Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Random 10 Char Values
Message
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Divers
Thread ID:
01017716
Message ID:
01017730
Vues:
25
Hi,

> does this code will not return duplicate? just like sys(2015) w/c is base on time? I want to put it on a unique field.

Yes, it does return duplicate values. If you need a unique value, you can use NEWID(). This value is virtually guaranteed to be unique. However, it's more than 10 characters long (36 precisely). You can reduce it to 32 characters if you remove the "-", or 16 bytes if you use a uniqueidentifier field type which stores the same value in binary format.
--
Christof
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform