How newid() Function Work in Back Ground ?
What is the difference between rand() and newid() ?
Which is more efficient?
Thanks in advance.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The problem with rand is that it returns the same value for all the rows for a call. newid will be different for every row. This article explains things clearly
https://web.archive.org/web/1/http://articles.techrepublic%2ecom%2ecom/5100-10878_11-6089823.html#