# \[XY Chart\] Maximum call stack size exceeded

**URL:** <https://forum.inductiveautomation.com/t/xy-chart-maximum-call-stack-size-exceeded/75696>\
**Category:** Ignition\
**Created:** [June 29, 2023, 10:58am UTC](https://forum.inductiveautomation.com/t/xy-chart-maximum-call-stack-size-exceeded/75696 "2023-06-29T10:58:02Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Marc.Akoto](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/marc.akoto/32/19291_2.png) [@Marc.Akoto](https://forum.inductiveautomation.com/u/Marc.Akoto)\
**Post date:** [June 29, 2023, 11:35pm UTC](https://forum.inductiveautomation.com/t/xy-chart-maximum-call-stack-size-exceeded/75696/2 "2023-06-29T23:35:13Z")

</div>

Eventually I noticed that the source dataset was too big for the XYChart.

This source dataset is the result of Named Query which returned many thousands rows : one event every minute during 3 days. However only 200 of those rows where displayed in the datasource binding on the XYChart.

To reduce the dataset length, in the Named Query, I used 2 solutions which both work :

- only return the events every 5 min, considering that each entry will represent the average data for the last 5 minutes

```auto
(HOUR( date_impr) * 60) + (FLOOR(MINUTE(date_impr) / 5) * 5) as t_stamp

```

- or only keep in "decadrages" table the events which correspond to a minute when something happens on an other table called "headtemp"

```auto
SELECT
<"items to select">
FROM decadrages 
JOIN headtemp ON DATE_FORMAT(decadrages.date_impr, '%Y-%m-%d %H:%i:00')=DATE_FORMAT(headtemp.date_heure, '%Y-%m-%d %H:%i:00')

```

---

_[View the full topic](https://forum.inductiveautomation.com/t/xy-chart-maximum-call-stack-size-exceeded/75696)._
