GUID vs. Auto-Increment Primary Keys.

This all started off from reading yet another wonderful post over at Better Explained, which is currently my favorite blog of the moment. My Google reader starred items list overflows with entries to-read from this blog. I wanted to brush up on the semantics of GUIDs/UUIDs because I'm currently implementing RDF output for one of our products from work and keeping the object URIs unique and consistent is a good thing. I'm using a simple MD5 hash for that.

The interesting aspect that cem out of this is the discussion of using GUIDs as database primary keys. We'd tried that a couple years ago but abandoned the implementation for a number of reasons.

I'll come back and finish this post some day, but I really just want to capture a bunch of links in one place. It would be cool if those social bookmarking services would allow you to cluster a bunch of links together into a single posting. At any rate, I'll use a blog for this instead and see how it works.

The general sentiment here is is that using UUID's instead of auto-incrementing ints decentralizes id assignment, enabling scale and avoiding having to re-key data when it's merged. The tradeoffs related to space are worth it and the performance impact is likely to be minimal
top