DEV Community

Cover image for SQL Server: NEWID versus NEWSEQUENTIALID
Andrea Carratta
Andrea Carratta

Posted on

SQL Server: NEWID versus NEWSEQUENTIALID

πŸ—‚οΈ SQL Server: NEWID versus NEWSEQUENTIALID

❓ Conosci la differenza e/o uale utilizzi?

Nel momento in cui definiamo un campo di tipo UNIQUEIDENTIFIER in SQL Server possiamo assegnare due ipotetici valori di default

πŸ“ NEWID()

oppure

πŸ“ NEWSEQUENTIALID()

Entrambi ritornano una GUID, ma con quali differenze?

πŸ’‘ Nell'articolo vi mostro come creare una tabella SQL Server ed assegnare i rispettivi valori di default.

Una volta creata la struttura vi faro' vedere la differenza tra i dati generati.

πŸ’₯ Sei pronto a rivedere il modo in cui definisci le tabelle ed i valori di default?

πŸ”— Troverete tutti i dettali nel post "SQL Server: NEWID versus NEWSEQUENTIALID"

sqlserver #uniqueidentifier #newid #newsequentialid #andreacarratta

Top comments (0)

Warp.dev image

Warp is the #1 coding agent.

Warp outperforms every other coding agent on the market, and gives you full control over which model you use. Get started now for free, or upgrade and unlock 2.5x AI credits on Warp's paid plans.

Download Warp

πŸ‘‹ Kindness is contagious

Explore this insightful write-up, celebrated by our thriving DEV Community. Developers everywhere are invited to contribute and elevate our shared expertise.

A simple "thank you" can brighten someone’s dayβ€”leave your appreciation in the comments!

On DEV, knowledge-sharing fuels our progress and strengthens our community ties. Found this useful? A quick thank you to the author makes all the difference.

Okay