Recently, in one project i need to get random records from sql server table and i found a good way to do same.
SELECT TOP <n> <column list>
ORDER BY NEWID()
The main function is NEWID() which return GUID.
Ex. Select Top 10 * From Employees Order By NEWID()
This is my first post on http://weblogs.asp.net/
I m so excited about this.
I'll update and share the best things in technology, that i can.