primary key field.. Since you are using this as a login, you could try
making a string comprised of the user name and the time created its
created..
For example:
<cfset randomSecond="#timeformat(now(), "HHMMSSl")#">
- This will generate a time string down to the millisecond
<cfset uniqueID="#randomSecond#--#UserID#">
- If you had a UserID of "tom", and the entery was created at exactly
1PM, the final string might look something like: tom--1300324
This should be suffeciently random enough for purposes of login.
If you are querying to see if the ID matches any others in the database,
if it returns any results at all, it is not unique.
Suppose your query was something like:
select *
from table
where ID = '#uniqueID#'
If it returns any records at all, the ID is not uniqueID is not unique.
I.E.,
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
