• Thanks Jeff, perfect solution. Testing it now.

    I also found this explanation, pretty much in the same line, that also seems easy enough:

    http://blog.sqlauthority.com/2012/11/20/sql-server-using-rand-in-user-defined-functions-udf/