Short Guid

In my daily perusing of DotNetKicks and related blogs for the desire to continue to expand my knowledge of C# development I came across Short Guid. This is a very simple concept but not one I’d have ever considered myself. In summation the idea of Short Guid is

Is take a regular guid like: c9a646d3-9c61-4cb7-bfcd-ee2522c8f633

And shortens it to a smaller string like this: 00amyWGct0y_ze4lIsj2Mw

This was basically all handled by just converting the guid to a btye array then base64 encoding of it handling 2 special cases of specific characters to be encoded easily for URLs. See the full article on Dave Transom’s blog at:

ShortGuid – A shorter and url friendly GUID class in C#

Which was based off the orginal idea on Mads Kristensenblog at:

A shorter and URL friendly GUID

BloggingContext.ApplicationInstance.CompleteRequest();

Advertisements

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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