Apr 03 2008

Hacking the 4.0 Data Migration Manager to Migrate Email Attachments

Published by Phil at 1:24 pm under Data Migration, MSCRM 4.0, Unsupported

According to the Data Migration Manager help documentation, “You cannot migrate attachments to e-mail messages, sales literature items, or to any record type that does not support notes.”

So what do you do when you’re doing a data conversion and you need to migrate email attachments?

Well, there’s got to be an more elegant way than this out there, but the first thing that came to mind for me was to migrate the attachments as notes by following the instructions here: http://blogs.msdn.com/crm/archive/2008/03/11/migrating-notes-and-attachments-using-data-migration-manager.aspx

For the csv file, I had three columns. The GUID of the email’s ActivityID, the filepath+filename of the attachment relative to the “Attachments” folder, and the name of the file. I then mapped the ActivityID guid to “Title”  the filepath+filename to “Document” and the file name to “File Name”.

Then, all you need to do is go into the database and INSERT INTO ActivityMimeAttachment FROM AnnotationBase where applicable and you’re good to go! Reply to this message if you want more details or code snippets on the specifics of this hack. Fair warning, this is very unsupported.

12 Responses to “Hacking the 4.0 Data Migration Manager to Migrate Email Attachments”

  1. Christianon 26 May 2008 at 11:02 pm

    Hi Phil,

    I am currently trying to migrate emails with attachment in my CRM environment and I was wondering whether you can share with me more details/code snippets on how you did the above mentioned steps.

    Note: I managed to successfully migrate notes + attachment! =)

    Hope to hear from you soon.

    Kind Regards,
    Christian

  2. Philon 05 Jun 2008 at 9:59 am

    Hi Christian,

    Sorry for not replying sooner — I was on vacation until this morning. I’ll follow up via the email you posted with more details if you still need them.

    Phil

  3. Shashidharon 01 Aug 2008 at 2:40 am

    Hi Phil,

    Many Thanks for the post and i would really interested to know the steps that need to be followed to migrate the email attachments as currently i am working on a CRM migration project which requires this funtionality to be implemented. Please send me the steps/code snippets to **********@rediffmail.com. Many Thanks for your co-operation.

    Thanks,
    Shashi

  4. Philon 07 Aug 2008 at 12:58 pm

    Thanks Shashi, will follow up via email. I’ll obscure your email address so that you don’t get spammed…

  5. Gregon 28 Oct 2008 at 7:58 am

    Hi Phil - intrigued by this too. Any chance you could share your approach? I’m hoping my email address will come across automatically since it is in the comments form :)

    I’ve been doing a lot of work with emails in CRM4 but wasn’t sure how to approach this import issue…

    Thanks

    Greg

  6. Philon 29 Oct 2008 at 8:43 am

    Sounds good, Greg. Will follow up via email.

  7. Jiton 19 May 2009 at 4:23 am

    Hi,

    Seems Interesting, can you send some more details on how you achieved this. I am also trying to do the same for 30000 open cases.

    Your details about the approach and steps you took will be helpfull

    Thanks

  8. MyQueryon 11 Aug 2009 at 12:37 am

    Hi..could you please share the code snippets which u have used to migrate emails and attachements

  9. Kristoffer John De Veraon 24 Nov 2009 at 10:19 pm

    Hi,

    Great article.

    I would want to ask how were you able to migrate the emails?

    My companies emails contain html so i find it hard to save it in a csv file.

    Also there are emails (set in the To, From, CC, etc.) that are not in the system which cause reference error.

    Hope you can help.

    Thanks in advance.

  10. Bryan Garciaon 04 May 2010 at 9:45 am

    Thanks for the post. I am interested to know the steps that need to be followed to migrate the email attachments and I would appreciate it if you can share the steps/code with me. I am working on a CRM migration project which requires me to import email attachments.

  11. Mike Prieskornon 15 Jul 2010 at 11:53 pm

    Hi Phil,
    I would like to merge two CRM 4.0 systems with DMM and I need all attachments and bigger descriptions in activities. Could you help me with your code snippets to do this?

    Thank you for cooperation
    Mike

  12. surion 27 Aug 2010 at 12:07 pm

    Hi.. We are looking for a solution where we would like to move email attachments into another crm environment .. can you please share what you have done
    Suri

Trackback URI | Comments RSS | del.icio.us | Digg it | Furl | iFeedReaders | Wykop

Leave a Reply