简体   繁体   中英

SSRS expression to get 2% report only daily

I have an SSRS report that run every day calculates employees interaction with sales sent report in excel.it will generate report how many times sales has been resolved by employees in a format of [NAME, STATUS,USERID. EDITDATE ]. what i am trying to achieve is i wont only to receive 2% of the entire report daily for all username (Employee). EXAMPLE if JOHN DOE oversaw 1000 sales today i wont only 2% of what he adjudicated.

[在此处输入图片描述]![1]

WITH CTE AS (
SELECT *,ROW_NUMBER() OVER (PARTITION BY [USERID] ORDER BY RAND()) AS Rn
FROM yourTable
)

SELECT * FROM CTE WHERE  Rn = 2

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM