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)
 Randomize a Temp Table

Author  Topic 

qman
Constraint Violating Yak Guru

442 Posts

Posted - 2009-09-22 : 14:42:12
I have a sort of odd request...

I have a temp table containing thousands of records. The data in this table needs to be manipulated so that it is non identifiable to the user. This really means updating the existing records with other columns of the same table so that the resulting table is randomized.

Anybody have an idea as to how to accomplish this?.
I realize this sounds like an odd request.

Thanks

ashw1984
Starting Member

6 Posts

Posted - 2009-09-22 : 15:56:16
hi there
to randomize a set of data
simply use this

order by newid()

using this and a series of cross joins could have the desired effect

ASH
Go to Top of Page
   

- Advertisement -