SELECT TOP 10 userID FROM user ORDER BY NEWID()
or
SELECT TOP 10 NEWID() [egg], userID FROM user ORDER BY [egg]
or
SELECT TOP 10 NEWID(), userID FROM user ORDER BY 1
only tried the above with TSQL
2741 users tagging and storing useful source code snippets
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)
SELECT TOP 10 userID FROM user ORDER BY NEWID()
SELECT TOP 10 NEWID() [egg], userID FROM user ORDER BY [egg]
SELECT TOP 10 NEWID(), userID FROM user ORDER BY 1
You need to create an account or log in to post comments to this site.