How to fetch random record form a tblDNFRec

Amatya
Posted by Amatya under Sql Server category on | Points: 40 | Views : 502
How to fetch random record form a tblDNFRec .

Select top 1* from tblDNFRec order by NEWID()
The value returned by NEWID is different for each computer. The NEWID() function in SQL Server creates a unique value of type uniqueidentifier.

Thanks
Amatya

Comments or Responses

Login to post response