Wednesday, May 23, 2012

Random value in a range

Update a value in SQL Server 2008 with a random value in a range:

ABS(CHECKSUM(NEWID())) % 300 + 110 (that will add numbers between 110 and 409

No comments:

Post a Comment