Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Very Short ID

Author  Topic 

SamC
White Water Yakist

3467 Posts

Posted - 2014-05-19 : 08:48:58
I searched but didn't find this. I'm sure it's been asked before...

I need a very short identifier [a-z][0-9][A-Z] similar to what the tinyurl uses.

Is there an efficient way to generate a unique short ID in TSQL?

Sam

TG
Master Smack Fu Yak Hacker

6065 Posts

Posted - 2014-05-19 : 16:20:16
I've never seen this asked and not even quite sure what the question is. but I did just see this:

====== TinyURL Generator Is Now Open Source! ======
TinyURL Generator is now hosted at http://code.google.com/p/tinyurl-generator/.

If you want to roll-your-own with t-sql I'm sure it's possible but we'd need some requirements. Do you mean that exact mask? and how unique as that mask can only make 6760 combinations.

Be One with the Optimizer
TG
Go to Top of Page
   

- Advertisement -