Saturday, 2 April 2016

Mirth Connect using SQL Server

When you first install Mirth Connect (update: now NextGen Connect)  is comes with its own Derby database.  This is fine when you are mucking around and developing channels, but I have seen my fair share of production sites going down because Derby is not up to task.  After a bit of research I even found Mirth themselves recommend that you replace this database before going live. (update: Yes, I know, I use HL7 Soup's Integration Host now too, but a lot of people are stuck with NextGen Connect) 

The first thing I do with Mirth now on a fresh install is to configure it to point to SQL Server.

Fortunately this is pretty easy to do.
Load up Mirth Connect Server Manager, then navigate to it in your task bar.




Right click it, and select "Show Manager"



Navigate across to the "Database" tab and fill it out with the settings and connection string to your SQL Server.


One thing to watch for is if your SQL is not the default instance you can't just use the normal / syntax of specifying it along with the server name. Use the following instead:
jdbc:jtds:sqlserver://SERVERNAME;instance=INSTANCENAME;DatabaseName=mirthdb


Now just restart the Mirth service from the Server Manager and Mirth will build and prepare the database for you.

If you need to migrate an existing database, and keep all the data then I suggest you take a look at this link I found.

8 comments:

  1. Really appreciate all the stuff made by this blog to let people know more about this topic. I added little more relevant points to my knowledge which definitely going to help me in coming future.
    vSan 6 Standard for 1 processor

    ReplyDelete
  2. Thanks. You solved my connection issue when I tried to move to sqlexpress.

    ReplyDelete
  3. for me it is not working on port 1433

    ReplyDelete
  4. Thanks very much for this! Our DB instance is not the default instance on the server, so this was super helpful.

    ReplyDelete
  5. Don't you just use Integration Host now. Good to see you back.

    ReplyDelete
  6. Thanks for this topic . Where can i find this database / tables in sql server management studio to control it ? is it possible ?

    ReplyDelete
    Replies
    1. It's been a while since I used Mirth sorry, but I think it would be the same way as HL7 Soup does it. The connection string contains the default DB name "DatabaseName=mirthdb" so it will be in that. If I recall, it wasn't the most friendly of DB structures.

      Delete
  7. Cool and I have a swell offer: Who Repairs House Windows home renovation contractors gta

    ReplyDelete