The Below Query will help you to find the Incoming and Outgoing Emails from CRM on Daily basis. Execute the Query on Respective CRM Organization_MSCRM Database.

Specify the No of months required in DATEDIFF("MONTH",CreatedOn,GETUTCDATE()) <= 1

select

cast( convert(varchar(10),createdon,111) AS datetime) [CreatedOn],

Sum(case when DirectionCode=0 then 1 else 0 end )[IncomingEmailCount],

Sum(case when DirectionCode=1 then 1 else 0 end) [OutgoingEmailCount]

from

Email(nolock)

where

DATEDIFF("MONTH",CreatedOn,GETUTCDATE()) <= 1

group by

cast( convert(varchar(10),createdon,111) AS datetime)

order by cast( convert(varchar(10),createdon,111) as datetime) desc

Results: