One of the methods. SQL Fiddle
SELECT Items.[ItemID], UserID FROM Items OUTER APPLY (SELECT TOP ([Num_Users]) * FROM Users ORDER BY Newid()) A
You can also use CRYPT_GEN_RANDOM(4) instead of Newid() for more randomness, but there are some problems with this on non-modern versions of SQL Server 2008.
source share