Saturday, January 21, 2006

Patrick Wellink : GUID is not Always GOOD !!!!!!! (a true RTFM story): "No CITY and Country would neve be good clustered indexes.

As a rule of thumb, every table should have a clustered index. Generally, but not always, the clustered index should be on a column that monotonically increases--such as an identity column, or some other column where the value is increasing--and is unique. In many cases, the primary key is the ideal column for a clustered index.


City and country both share the same caracteristics. 'They don't Increase monotonically' and 'are not unique' that is why I would never create a clustered index on them.

Second....

I have seen the performance hit on a logging table. The logging table would grow to over 1.5 million records. The last insert took over 30 seconds and caused a Timeout.

So you really have to know hat you are doing if you are playing around with guids. If you do, it is ok to use them.
"

0 Comments:

Post a Comment

<< Home