Answer: Rand() function generates random values which is only and only Numeric values whereas
NewId() function generates GUID(unique identifier) which is a combination of both alpha-numeric character.
For Ex:-
Select NewId() as Unique_Id;
will produce
A1F3BE10-888C-45A2-8CCB-FB4A0DF37334
Select Rand() as Random_value;
will produce
0.16028902278382
Asked In: Many Interviews |
Alert Moderator