Q&A about the site for power users of Apple hardware and software
SELECT AVG(CAST(DATEDIFF(DAY, DeletionDate, CreationDate) AS FLOAT)), ReviewTaskTypeId FROM ReviewTasks WHERE CreationDate BETWEEN ##DateFrom:string## AND ##DateTill:string## AND DeletionDate IS NOT NULL GROUP BY ReviewTaskTypeId