Import Outlook folder or PST into SQL?

  • HI all,

    I've got an archive of old emails from a previous employer I want to import in SQL for a little side project - to make the emails easily searchable, queryable, and to do a few things with the contacts. I've stripped all the attachments out because I didn't want to store them or have them cause issues.

    I don't know of a way to do this - exporting the folder in Outlook to CSV is garbage. That CSV file is so mangled with junk...

    I tried access, but get this error in 2013 when trying to import for an external source

    Microsoft Access can't find the wizard. This wizard has not been installed, or there is an incorrect setting in the Windows Registry, or this wizard has been disabled.

    I don't have any addin - I installed Access from the web....i can't imagine an incorrect setting, but I've tried repairing and search Google with no luck...

    Anyone know of any other way? Or a fix to the above Access problem?

  • Initial thought: I would go find another side project to work on...

    No clue about Access issue and you are not likely going to get much help on that from this forum. I would go to MSDN form if you are looking to just solve the specific Access issues.

    If you want to query the contents of an Outlook folder you can use PowerShell. If the PST is attached to the profile in Outlook that you are working with in PowerShell I expect you should be able to hit that as well.

    Shawn Melton
    Twitter: @wsmelton
    Blog: wsmelton.github.com
    Github: wsmelton

  • No. There are over 20,000 emails and a huge amount of contacts. They for some reason (contacts) don't appear in outlook. Also the data is fairly important for consulting projects. I just don't wanna use Outlook as the means for searching.

  • If I remember correctly, your MSAccess error is telling you that it can't find a wizard. to get the import/export wizard you have to "install advanced features" when installing Access. Again, IIRC this also installs linked table manager and a few other tools.

  • It's been a long time ago, but I vaguely recall using LINQ (or OLEDB directly) to query data from Outlook.

    http://thedatafarm.com/data-access/using-linq-to-query-outlook-emails-joined-with-sql-data/

    "Do not seek to follow in the footsteps of the wise. Instead, seek what they sought." - Matsuo Basho

  • If you just want a decent searchable index, you could always just link Outlook to a Gmail account and drag the PST folders in:

    http://www.theatlantic.com/technology/archive/2010/01/moving-pst-files-into-gmail-you-can-try-this-at-home/34209/

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply