Description
Retrieves image usage by user and model for a specific period and client.
Query :
Retrieves image usage by user and model for a specific period and client.
Query :
Select SU.RoleName, SU.Username, I.ModelName, SUM (AP.ImageCount) as ImageCount from AssetPurity AP join vwSecurity_UserList SU with (nolock) on SU.Userid = AP.CreatedbyUserid join IRModelType I WITH(NOLOCK) ON AP.IRModelTypeId = I.IRModelTypeId where AP.clientid = 228 and AP.CreatedOn >= '2026-03-01' and AP.CreatedOn < '2026-04-01' and StatusID = 13 GROUP BY SU.RoleName, SU.Username, I.ModelName