Pie chart Java.Lang.NullPointerException Error

I have four pie charts with data property bond to the same named query, all of which are using the same parameters(enddate,startdate,department) with the only changing parameter being department(string) which are all hard coding in. When I switch to and from the window on the designer as well as on the client I get this error.

Exception in thread “AWT-EventQueue-2” java.lang.NullPointerException
at com.inductiveautomation.ignition.common.BasicDataset.getValueAt(BasicDataset.java:111)
at com.inductiveautomation.factorypmi.application.binding.util.NonSerializingDataset.getValueAt(NonSerializingDataset.java:66)
at com.inductiveautomation.factorypmi.application.components.chart.runtime.FPMIPieDataset.getValue(FPMIPieDataset.java:92)
at org.jfree.data.general.DatasetUtilities.isEmptyOrNull(DatasetUtilities.java:542)
at org.jfree.chart.plot.PiePlot.draw(PiePlot.java:2368)
at org.jfree.chart.JFreeChart.draw(JFreeChart.java:1227)
at org.jfree.chart.ChartPanel.paintComponent(ChartPanel.java:1361)
at com.inductiveautomation.factorypmi.application.components.PMIPieChart.paintComponent(PMIPieChart.java:162)