As has been discussed numerous times before and is a known fact - having a clustered index on a uniqueidentifier primary key column, in sql server,will affect performance.
What I would like to do is observe this issue by issuing inserts and measuring certain metrics. I have 2 tables with a uniqueidentifier PK; one with 'newid()' as the default and the other with 'newsequentialid()' as the default value. I plan to insert about a million rows in each and observe the INSERT performance.
What should I be querying for in particular? How can I best observe the performace gain of having sequential GUIDs over random GUIDs? Are there certain system views, stored procedures that give stats about the index page splits and/or other relevant information?
Although the below link will give the comparision between int and guid, but you can follow the similar approach and give it a try.
https://dba.stackexchange.com/questions/9821/why-do-sequential-guid-keys-perform-faster-than-sequential-int-keys-in-my-test-c
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With