EasyChart Dynamic pens with SQLTags History

Sorry if this is a “no brainer”, but there don’t see any relevant posts about it.

I am collecting data with SQLTags History- the data appears to be collected in a set of tables, not just one. EasyChart allows you to pick these, which is fine.

What I need is to be able to use the same popup (with chart on it) to display the same three tags from a number of different groups. So in one instance it would show X/Y/SP, X/Y/PV, and X/Y/OUTPUT, in another it would show A/B/SP, A/B/PV, and A/B/OUTPUT.

If anyone can point me in the right direction I would appreciate it.

First - make sure you use Tag Pens for SQLTags history, not DB pens.

Second - The basic idea here is to use either scripting or binding to alter the [tt]tagPens[/tt] dataset on the Chart based upon what group of pens you want to see. A lot of people will create a database table in their database that stores their pen information along with information that lets them query it in meaningful groups.

Any chance there is a way to reference an indirect tag in the easy chart tag path?

I am trying to make a popup chart that references a device based on a root container custom property (deviceID)

Because I have 20ish devices this seemed the easiest way to tackle the problem until I realised I didnt know how to put the tag path into easy chart with a dynamic reference

Is modifying the TAG_PATH column in the tagPens property of the chart the only way?

(I am hoping that some clever person has come up with a quicker way to do this since the last response)

Lucky you, there happens to be a video on exactly this:

HOWEVER, there’s another thing you could do that I happen to like more: instead of an easy chart, use a “classic chart”. Then, bind its dataset to a tag history query binding, which support indirection. Anyhow, both are valid, play around and see what you like.


Thanks for the videos, Colby. I just subscribed to the InductiveAutomation youtube channel. This kind of thing helps me the quickest. Good stuff.