Well you can put them into a struct and keep generating until you get 1000 in the struct. Since the struct only allows for unique keys, you won't have more then one of the same number.
Russ > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Wednesday, July 25, 2007 5:40 PM > To: CF-Talk > Subject: Generate Random Number 1000 - No Duplicates > > I need to generate 1000, unique 8 digit numbers. I'm looking for a > function that will do this. > Rand generates in the range of 0 - 1. RandRange would work, but how do I > assure that there > aren't any duplicates. I'm outputing this data from a query to a xls. > > Thanks > > D > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| ColdFusion 8 beta - Build next generation apps today, with easy PDF and Ajax features - download now http://download.macromedia.com/pub/labs/coldfusion/cf8_beta_whatsnew_052907.pdf Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:284594 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4