# XY Chart Series Data All Showing Same Data

**URL:** <https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [April 23, 2025, 8:48pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483 "2025-04-23T20:48:27Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Christian\_Reynolds](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@Christian\_Reynolds](https://forum.inductiveautomation.com/u/Christian_Reynolds)\
**Post date:** [April 23, 2025, 8:48pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/1 "2025-04-23T20:48:27Z")

</div>

I've had this issue for a while, but it would magically fix itself by copying and pasting the XY Chart. However, that is not working anymore. I have multiple XY Charts are setup similarly showing different date and all are doing the same thing. These charts to show production for each day for the past 7 days.

The data sources are as follows:

- Shift1
- Shift2
- Shift3
- Total (total for all three shifts for the day)
- Spacing (which is just an empty dataset to provide spacing between each day)  
The data sources are bound to separate SQL Query tag.

This is what one of the charts currently looks like:

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/4/743939f00964769cf50571eaa14275ca722bcdb6.png)

For the current day, the data looks weird. Not sure what its doing there. For the remaining days all are showing the same values. The data source Shift1 and Shift3 are empty, so those should have no columns. Shift2 and Total have data in them, those are the only two that should have columns.

I tried removing my spacing data source to see if that was causing issues, but it did not change the chart.

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [April 23, 2025, 8:51pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/2 "2025-04-23T20:51:31Z")

</div>

Please tag your question (using the dropdown below the title) as Vision or Perspective. It looks like Perspective so you can copy the chart from the Project Browser and past it in here formatting as code. Please see [Wiki - how to post code on this forum](https://forum.inductiveautomation.com/t/wiki-how-to-post-code-on-this-forum/77831).

Do the same with the chart data as the binding won't work for us in testing.

---

<div class="post-metadata">

**Author:** ![Christian\_Reynolds](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@Christian\_Reynolds](https://forum.inductiveautomation.com/u/Christian_Reynolds)\
**Post date:** [April 23, 2025, 9:35pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/3 "2025-04-23T21:35:19Z")

</div>

I am hitting a character limit. Will it work if I paste it in a text file and upload it?

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [April 23, 2025, 9:37pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/4 "2025-04-23T21:37:51Z")

</div>

That should work.

---

<div class="post-metadata">

**Author:** ![Christian\_Reynolds](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@Christian\_Reynolds](https://forum.inductiveautomation.com/u/Christian_Reynolds)\
**Post date:** [April 24, 2025, 1:27pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/5 "2025-04-24T13:27:37Z")

</div>

Here is the file. The data sources are at the bottom and I labeled them.

[XYChart.txt](https://forum.inductiveautomation.com/uploads/short-url/s92j4xpyicmVn755YRKlW8ihC5I.txt) (46.9 KB)

---

<div class="post-metadata">

**Author:** ![Ujwal\_Wankhede](https://avatars.discourse-cdn.com/v4/letter/u/4af34b/32.png) [@Ujwal\_Wankhede](https://forum.inductiveautomation.com/u/Ujwal_Wankhede)\
**Post date:** [April 26, 2025, 4:50am UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/6 "2025-04-26T04:50:53Z")

</div>

I looked into your issue and noticed that you're using a dataset to render the series. While I’m not exactly sure what’s causing the problem, I’d recommend transforming your data into an array of dictionaries instead.

There are multiple ways to structure the dictionary, but I prefer using static keys in the series configuration and changing the values at the `dataSources` level. For example, assign either the "Count" or "Weight" values to the keys in your `dataSources`, rather than modifying the `series[].data.y` property dynamically.

 ![XYChartSamples](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/8/68291623e33da81f28b198bf2634b322d33a214e.png)

Also, the data axis can handle missing or empty dates automatically, so you don’t need to manually fill in gaps for the timeline—it will still render correctly.

I've attached a view you can use as a starting point.  
[XYChartSample.zip](https://forum.inductiveautomation.com/uploads/short-url/X5YOto44aYtPjykfi3Pdwi7bvt.zip) (17.8 KB)

Please modify the transform script I included—it's just meant to demonstrate the concept. I’m not sure how you're building your dataset, so you might even be able to construct the array of dictionaries directly at the source.

---

<div class="post-metadata">

**Author:** ![Christian\_Reynolds](https://avatars.discourse-cdn.com/v4/letter/c/e8c25b/32.png) [@Christian\_Reynolds](https://forum.inductiveautomation.com/u/Christian_Reynolds)\
**Post date:** [May 1, 2025, 1:23pm UTC](https://forum.inductiveautomation.com/t/xy-chart-series-data-all-showing-same-data/105483/7 "2025-05-01T13:23:03Z")

</div>

I'm not sure what is causing the issue either. It would render the date fine at some points, but then at other points it would be off. Like I mentioned in the post, I could copy the same XY Chart and the date would be fine.

I have implemented your solution and will see if that fixes the problem. So far it looks good. I have the source data bound to a query tag from SQL. I've had issues with having a direct query bind taxing the SQL server if multiple users had the same page open. Also, this keeps the data consistent across multiple users.
