Usa el AVG
función
SELECT avg(cast(lastprocesseddate as date)-cast(importeddate as date))
FROM feedqueueitems
WHERE eventid = 2213283
ORDER BY written DESC;
En la base de datos con la zona horaria +1 para la fecha importada y la última fecha procesada es UTC
SELECT avg(cast(cast(lastprocesseddate as timestamp with time zone) at time zone '+01:00' as date)-cast(importeddate as date))
FROM feedqueueitems
WHERE eventid = 2213283
ORDER BY written DESC;