Browse our collections
DECLARE @__GetValueOrDefault_1 int = 12;
SELECT [t0].[CollectionProductId], [t0].[CollectionId], [t0].[ProductId]
FROM (
SELECT DISTINCT [c].[CollectionId]
FROM [CollectionProduct] AS [c]
WHERE [c].[CollectionId] IN (107, 8, 26, 40, 103, 24, 83, 11, 23, 109, 106, 41, 94, 2, 108, 42, 16, 25, 93, 34, 29, 39, 17, 28, 12, 35, 115, 27, 110, 45, 104, 7, 105, 1, 14, 13, 224, 58, 206, 90, 43, 21, 217, 6, 226, 92, 222, 221, 63, 233, 33, 298, 218, 220, 36, 59, 85, 91, 114, 55, 112, 111, 64, 18, 50, 84, 48, 56, 10, 52, 60, 254, 46, 229, 54, 61, 219, 32, 223, 37, 20, 62, 227, 225, 51, 3, 88, 30, 300, 44, 113, 38, 4, 19, 57, 53, 49, 47, 232, 264, 253, 89)
) AS [t]
INNER JOIN (
SELECT [t1].[CollectionProductId], [t1].[CollectionId], [t1].[ProductId]
FROM (
SELECT [c0].[CollectionProductId], [c0].[CollectionId], [c0].[ProductId], ROW_NUMBER() OVER(PARTITION BY [c0].[CollectionId] ORDER BY NEWID()) AS [row]
FROM [CollectionProduct] AS [c0]
) AS [t1]
WHERE [t1].[row] <= @__GetValueOrDefault_1
) AS [t0] ON [t].[CollectionId] = [t0].[CollectionId]