web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Unanswered

Reduce HTML content of emails

(0) ShareShare
ReportReport
Posted on by 2,461

We are experiencing rapid growth of our database storage. The capacity report shows that a majority of storage is consumed by table ActivityPointer. Our analysis of the data in that table shows that the data is mainly in the description field of email activities. On average, one email has a size of about 200 KB. Analysis of a few samples indicates that most of the size is caused by mostly unnecessary html code.

Our plan to mitigate the storage growth is to remove the unnecessary html code and just keep the parts that are actually necessary to display the email in the intended layout. A proof of concept with Tidy HTML shows promising results and should reduce storage needs by about 70%.

Is there a third party solution or product available that does this or something similar? Bonus points if the solution offers archiving of the original email, adds compression for the content of the description field and/or provides telemetry on number of records processed and data reduced/saved.

If no third party solution is available, we plan to implement this ourselves. Current approaches are using an Azure Function that gets triggered by the Azure Service Bus integration of Dataverse or a Power Automate flow. Alternatively, a custom workflow activity could be implemented that does this, thus removing the need for additional Azure components.

Appreciate any thoughts or preferences for one of these approaches.

I have the same question (0)
  • prt33k Profile Picture
    6,907 on at

    Hi,

    Have you checked the activitymimeattachment/attachment table too? Usually the email will have image which are the main reason for increased size and that can be then moved to sharepoint/azure blob.

    There is a third party solution for this : www.mscrm-addons.com/.../AttachmentExtractor

    Custom approach is fine too however you need to consider that once email is received it then goes to 'Closed' state and will not allow direct edit. You might need to switch the status back and forth to get this to work.

    Thanks,

    Prateek

  • Florian Hopfner Profile Picture
    2,461 on at

    Thanks, the closed state is a good hint.

    Yes, the attachement table has a similar size, but since it is counted against file and not database storage, we see no need to reduce its size.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 108 Super User 2025 Season 2

#2
Jimmy Passeti Profile Picture

Jimmy Passeti 50 Most Valuable Professional

#3
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 49 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans