Ignition SCADA Integrates with SQL Databases

Inductive Automation’s Ignition SCADA platform is an amazing product that integrates very easily with SQL databases. This easy integration tends to expand the opportunities and applications beyond traditional SCADA. For us, this has become workflow planning and execution, off-line data entry, operator logs, data analysis and reporting. With all this great data sitting in a database, it begs the question of extracting and reporting in order to create end-user value.

Microsoft Excel is the preferred tool of many end-users. It is hard to argue using Excel and our job as system integrators is to provide the data in a format that is useful. Ignition’s tools to write Excel files are fairly limited and we did not want to create separate applications outside of Ignition that the customer did not want and we did not want to support.

Python + Java = Jython

This is where the power and flexibility of Ignition shines. Ignition utilizes the computer language Python, specifically Jython. Ignition allows the end-user to easily integrate third party Java classes or pure Python packages. Jython allows you to use Java, so first we found some Excel export classes in Apache. Personally, we would prefer programming in pure Python rather than Java in Jython. We figured since Python is so popular, more than likely somebody had already developed a tool. Then we found XLSXWriter, a pure Python package. This is an amazing tool that not only let’s you write data but also create named Excel worksheets, formulas, cell formatting and charting. So you could create a whole report! My main issue was writing large data files and this module has a “memory” mode that streams data to a file. Sure it is a little slow writing out large datasets, but that is OK.

Please note XLSXWriter’s BSD license. We include the BSD license, copyright and disclaimer in the Ignition client and Gateway.