Skip to content

Generating a Universal Unique Identifier

September 28, 2009

A Universally Unique Identifier (UUID) is a formatted string used to identify something with reasonable confidence that the identifier will never be unintentionally repeated by anyone for anything else. This is useful for example in creating table-entries with unique IDs, which you might need to merge with another table and not have conflicting ID’s or need to generate new ID’s.

B_UUID is the second installment in my B-Suite of custom types, and is a pure-Lasso method of generating a version 4 (random) Universally Unique Identifier (UUID). The usage is very simple, you simply call the prototype, and the call is replaced by a new UUID.


=> 12c9ca38-ef23-42f2-951b-f6dad1ced320

For the most up-to-date version of this code, I recommend checking the source out from my Google Code account linked to above. As an alternate, you can also view/copy the source from

Other methods of creating a UUID in Lasso

  1. On most operating systems, using Jason Huck’s Shell tag, or the built in OS_Process tag, the `uuidgen` command can be used to return a version 4 UUID.
  2. Steffan Cline has recently posted a cross-platform LJAPI module, GetUUID, that is most likely faster than any solution written in Lasso Script, or certainly any solution that needs to open a shell.
  3. My understanding is that when LassoSoft releases Lasso 9 (most likely October, 2009) that the built in Lasso_UniqueID will generate a version 4 UUID, similar to B_UUID.
No comments yet

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: