Why Mirth?
As the administrator of the OpenLDR you are free to choose any method of importing and extracting data you are comfortable using. This example implementation uses Mirth for a few primary reasons. Mirth is a simple but powerful integration engine that is will make it easy for the exchange of code and methodologies between OpenLDR implementations. Mirth is widely used around the world, is free to use, and provides a large and stable infrastructure for the implementers to utilize. Much of the core functionality supplied by Mirth is available for handling many of the basic functionality a programmer would have to build and maintain from scratch. By utilizing Mirth's built-in functionality, such as easily connect to many different data sources or managing files, the developers can focus on the data. It's also very easy to export an entire Mirth implementation and then import it into another Mirth installation, which will promote sharing and standardization.
The original Mirth website is now gone as the primary company maintaining MirthConnect has changed. Downloads of MirthConnect can be found at the following link:
https://www.nextgen.com/products-and-services/nextgen-connect-integration-engine-downloads
Getting Familiar with Mirth
The original videos associated with Mirth have been removed from the original Mirth website. As good videos are discovered we will add links to them here.
Installing Mirth
When downloading and installing Mirth make sure you have the latest version of a Java JRE on your machine. Also make sure the 32/64 bit versions of everything match up (e.g. 32 bit Java JRE, download the 32 bit version of Mirth).
Connecting to SQL Server
Initially we are creating examples using Microsoft SQL Server but MySQL and PostgreSQL are great options; the Mirth example videos show PostgreSQL. When using Microsoft SQL the only thing that's a little tricky is getting the permissions set correctly on SQL Server. Mirth needs its own database and structure to operate. As you'll see in the videos this is the "mirthdb" that you should create before the Mirth installation. After installing and starting Mirth, the Mirth engine will setup the structure and populate mirthdb; all you need to have done is create the database instance and give the Mirth user full permissions to that database instance.
The connection string to the database for Mirth and within your Javascript code might need to have the instance name included. Example: jdbc:jtds:sqlserver://localhost:1433/mirthdb;instance=SQLEXPRESS
This is not always necessary depending on how your SQL Server is configured and and whether you are connecting to a local instance or another computer on the network. It's worth a try if you are having problems making any sort of connection when first installing Mirth.
The following link discusses connecting to MS SQL Server, but it's a slightly old version.
http://www.mirthcorp.com/community/wiki/pages/viewpage.action?pageId=4358193
Additionally here are some screen shots of the permissions set on a local instance of a newer version of SQL Server. When you create the user, make sure you select SQL Server authentication rather than Windows authentication.
It's important to keep in mind that the mirthdb and the OpenLDRData/Dict databases do not have to be on the same server, I am only doing it out of convenience. Also for convenience, I am connecting to the mirthdb and the OpenLDR databases using the same user, but that will seldom be the case in a real installation.