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,...
Answered

activitymimeattachment With Id Does Not Exist

(0) ShareShare
ReportReport
Posted on by 120

Hello colleagues,

I'm writing you because I start to have an strange issue in MS CRM, for some emails when we try to delete them (even as System Admin) we got the below error message. Do you know why I'm having this error? any light in how to fix it?

Thanks in Advance.

s:Clientactivitymimeattachment With Id = 5ecb4000-7814-4f0c-b9fe-35115b5fd4ac Does Not Existaa049339-13f0-459f-8eb6-bf4a95d9c9c5-2147220969activitymimeattachment With Id = 5ecb4000-7814-4f0c-b9fe-35115b5fd4ac Does Not Exist2020-08-05T16:11:39.1202952Zfalseaa049339-13f0-459f-8eb6-bf4a95d9c9c5-2147220969activitymimeattachment With Id = 5ecb4000-7814-4f0c-b9fe-35115b5fd4ac Does Not Exist2020-08-05T16:11:39.1202952Zfalse

I have the same question (0)
  • a33ik Profile Picture
    84,331 Most Valuable Professional on at

    Hello Victor,

    Let me guess - did you do import of email attachments from other systems for emails that you can't delete?

  • Viktorparada Profile Picture
    120 on at

    Hi Andrew, how have you been?

    To be honest I'm quite sure that isn't the case, as far as I remember we migrate our system from 2013 to 2016 4 years ago and until now this issue never happens. This issue start some weeks ago happening to new email as to the old emails in a random way.

    I look into the DB (as our solution is a on premise) and as far as I can go all the linked GUIDs for the related tables are there, I guess I'm missing one but to be honest I don't know where to look more.

    Do you have any idea/suggestion?

  • Miguel Lourenco Profile Picture
    on at

    Most probably there are some orphaned records.

    I would delete them from database with:

    DELETE FROM ActivityMimeAttachment WHERE AttachmentId NOT IN (Select AttachmentId FROM Attachment)

    Do a backup first, execute the script and test if everything is ok.

  • Viktorparada Profile Picture
    120 on at

    Hi Miguel, first of all thank you for sharing your feedback.

    This approach didn't fix the issue, the result of the execution was zero rown, however I can still see emails with attachments in the system and I'm not able to delete them.

    Do you know what are all the tables where is maintained the field ActivityMimeAttachmentId? I ask you this because looks like the GUID maintained is wrong/missing in one of the tables at least.

    How I know this, well because executing this script I'm able to get the ActivityMimeAttachment record

    SELECT *
    
    FROM [dbo].[ActivityMimeAttachment]
    
    WHERE [ObjectId] = '422077B9-D651-E811-80EB-005056934E24'

    and executing this script I'm able to get the linked attachment

    SELECT *
    
    FROM [dbo].[Attachment]
    
    WHERE [AttachmentId] = '4A2077B9-D651-E811-80EB-005056934E24'

    2020_2D00_08_2D00_06_5F00_11h32_5F00_18.png

  • Verified answer
    Miguel Lourenco Profile Picture
    on at

    Can you check if you have the auditing enabled for the attachment entity?

    If true, can you try to disable and try to delete again?

  • Viktorparada Profile Picture
    120 on at

    Hi Miguel, I didn't never think about the Audits, you was right, taking out the Attachment entity from the Audits fix the issue.

    Thank you so much

  • Miguel Lourenco Profile Picture
    on at

    Awesome :)

  • yleclerc Profile Picture
    1,549 on at

    Hi all!

    Turning off the audit for the attachment entity did not work for me. I even tried to turn off Auditing in the whole system. No luck.

    As Andrew mentioned, the emails come from another system (Outlook synchronization).

    Any other ideas?

  • yleclerc Profile Picture
    1,549 on at

    Anyone has other ideas? A user activated the Outlook sync with CRM, and 7,000 emails were sent to CRM. And we can't delete the ones that have attachments.

    I turned off Auditing. Also tried bulk delete job. Nothing works so far.

    Thanks!

  • JMatlon Profile Picture
    15 on at

    We're also seeing the same issue (CRM 2016). The Guid referenced has a match in the activitymimeattachment table, so I'm not sure what's going on with this.

    I'm assuming this was introduced with an update.

    Did you ever find a resolution?

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
Pallavi Phade Profile Picture

Pallavi Phade 98

#2
Tom_Gioielli Profile Picture

Tom_Gioielli 60 Super User 2025 Season 2

#3
Gerardo Rentería García Profile Picture

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

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans