> I'm currently working on a project where I need a generated unique > identifier for an order and to not use the traditional database > primary key of id[...] > The UUID gem's shortest id is 32 characters and seems a quite lengthy.
Think of it like a URL shortening service. Take several field values, concatenate them, and hash the result. Then encode the result in something like base 36, because that's compact and also URL-safe. the result should only be a few characters long. Store in another column and everyone's happy. Ted --~--~---------~--~----~------------~-------~--~----~ SD Ruby mailing list [email protected] http://groups.google.com/group/sdruby -~----------~----~----~----~------~----~------~--~---
