cancel
Showing results for 
Search instead for 
Did you mean: 

MII Trends - add data onto chart object

Former Member
0 Kudos

Hello,

Can anyone please provide some thoughts on my current requirement:

its pretty basic:

I select a site(Historian datasource) search for a historian tag and then based on the selection I Trend(lets say Line chart).

Now I should select another site(historian datasource) search for a historian tag and add the tag onto the line chart along with the previous one.

so basically give user an option to select any historian data source and trend.

While i do this, i should still be able to use the in built chart properties mainly the time control - to go back and forht in time..

while I am doing this, I am also keeping a running list of selected tags in another table with the tag's other properties -like current value, Eng Units, calculation, Description, datasource.and give an option with a check box to this running list - where in user can check /uncheck the item and that removes the pen from the chart - and maintaining the chart pen color consistent with the running list's item's color(check box color - for ease of matching) - I am able to accomplish this part successfully.

I grealty appreciate if any one cane give me some ideas.on how to adynamically add tags onto the chart from multiple datasources and maintian the inbuilt properties of the line chart.

As you can see, I am almost building a product here - similar to Aspen's web21 or osi's process explorer - using MII.

any input is greatly appreciated.

Regards,

pramod

Accepted Solutions (0)

Answers (1)

Answers (1)

jcgood25
Active Contributor
0 Kudos

The built-in features of the iChart allow the basic premise of what you are trying to do, however it limits you to one Data Server at a time in the iChart, because a single query template only has one data server source, but with an XacuteConnector as your data source you can do whatever you need.

You'll need to keep track of their choices either in an array or string list so you can appropriately bind it to the Param.x in your underlying Xacute Query template. The BLS logic for running the queries, and overloading the Server and Tags will be up to you.

The start and end date mapping for your Xacute query template will make the chart work like a typical Historian line trend with time controls. You'll just need to create the date inputs (DateTime datatype in your Transaction property) and link to the QueryStartDate/QueryEndDate of each tag query action.

You don't need to merge the data into one rowset. The chart will be happy with 1 Rowset per tag like you see from either Current, History, or HistoryEvent from a real Historian (not like Simulator's merged normalized dataset). You may just want to consider creating the Transaction OutputXML, and use the AssignXML for the first data source query, followed by AppendXML for just the Rowset(s) from each subsequent data source query. This way you keep building into the OutputXML in your loop.

Former Member
0 Kudos

...and all of the UI components available in the built-in chart dialog components for selecting servers/tags are available for use as standalone component in a custom web page to build a custom charting tool, likely using BLS as the "aggregation" layer as Jeremy has suggested.

Former Member
0 Kudos

Hello,

Thanks a lot for your inputs.

I am now able to get it to work for multiple sites...

BUT, I have a very wierd issue.

the iChart is working fine for TAG based queries for many selected tags(upto 32).

BUT, if I run an Xacute Query in an iChart - it works for upto ONLY 3 tags, if I add 1 more - ie for 4 tags - the ichart doesnot display the 4th tag data at all...

I have checked all the parmeters.

I ran a simple dynamic webpage generator with a tag query of upto 4 tags and an xacute query for the same 4 tags, with the same LINEChart - and tagquery based chart displayed all the data on the chart but the XacuteQuery based chart chokes ...

but I can rightclick and see the complete data without a problem - its just that chart is not displaying the 4th tag data.

Any input is appreciated.

Regards,

Pramod

Former Member
0 Kudos

actually it started working as soon i change the xacute rowcount to 100,000 instead or 999,999.

I have interpolate lines CHECKED

and use screen resolution UNCHECKED

Former Member
0 Kudos

I'm not sure if it still works this way, but if you set the RowCount to 0, it should process unlimited rows.