Reporting: a table with unique data/calculations for each cell

Hi everyone,

I am using Ignition reporting to create an auto-generating production report. What is the best practice to import the data as shown in the image. I tried using individual parameters for each cell in the top table, and in the bottom table I created a SQL query to do the same thing.

I am trying to do this for a dynamic range as the production period for each batch will vary, is the system.tag.queryTagCalculations or TagHistory more appropriate? Any further guidance would be very appreciated.

How/where is the data being stored? That will probably determine how you accomplish this.

It's being stored in sqlt_data_1_2025_03 in a MS SQL database, each tag has the historian enabled so I am retrieving from there. I want to generate the report as the batch is running - so should I be retrieving data from elsewhere to have it running live?

This seems odd. Normally reports are generated after the batch is complete.
An exception might be where you want a periodic report on a long-running batch.

Are you sure you shouldn't be using Vision or Perspective to show the current status of the batch?

OK... so this is data from the history system.

Don't try and query the table directly.

You should be able to use a Tag Historian Query data source, and then use the reporting system to grab the min/max/avg from the datakeys. Make sure that you select the "Show Calculation".

If this is specific batching data, you may want to rethink how the data is going into the database to aid in this. Maybe log data using a transaction group or something similar that is tied to a batch record. Just a thought.

1 Like

You're right, the report should be generated once the batch is complete. There is a 'batchnumber' OPC tag that I am monitoring; a tag value change triggers the batchStart and batchEnd times to give the range.

Appreciate the help, I will try using the Tag Historian Query.

If your setpoints and specification limits are set by recipes, you should probably be handling those in a separate table, and using separate queries to retrieve those per batch. Such time-coordinated values are not well-suited to the tag historian.

2 Likes