Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unique numbers

Status
Not open for further replies.

wuah

Programmer
Mar 15, 2001
42
DK
Is there anyway to create a unique number without a database with auto number?

I'm thinking to do something with time. ?

Any suggestions?

Help

/Rasmus
 
You could take the current date/time and convert it into a numeric or alphanumeric value.

Dec 14, 2001 at 12:39:58
12/14/2001/12/39/58 or
1214200112393958

It all depends on how often you will be creating a unique value. If you decide to use date/time make sure you consider the regional settings of the web server.
If you use the Date() function it could return
12-14-01 or 12/14/01 or 12/14/2001, etc.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top