views:

34

answers:

1

So I think I already know the answer to this question...

Running AdventureWorks2008 (latest version) on mssql server 2008. I am thinking that the rowguid column in a lot of the tables is to ensure that there is a primary key. I am probably dead wrong as the column appears to be a constraint.

Correct me if I am wrong and also please correct me with an answer I can learn from. Am just surveying this so far in SQL Management Studio...are there any queries that will back up how wrong I am? I am not a DBA so I am lost :)

+2  A: 

In general the rowguid column is used in replication, if you start to use replication the rowguid column will be created. From Books On Line

Merge replication requires that each published table have a ROWGUID column. If a ROWGUID column does not exist in the table before the Snapshot Agent creates the initial snapshot files, the agent must first add and populate the ROWGUID column. To gain a performance advantage when generating and applying snapshots during merge replication, create the ROWGUID column on each table published during merge replication. When creating the column, specify:

The column title as ROWGUID.

The data type as UNIQUEIDENTIFIER.

The default as NEWID().

The ROWGUIDCOL property.

An index on the column. The ROWGUID column is used frequently for relating to merge tracking data during tracking and synchronization of changes made at the Publisher and at Subscribers.

SQLMenace
OH...I should have known that...I feel like a dumbass with my many MCSE renewals. HRM!
ThaKidd

related questions