cancel
Showing results for 
Search instead for 
Did you mean: 

i5SPC chart web scripting issue SAP MII 15.0

aravinth_anandhan
Active Participant
0 Kudos
317

Hello,

When I hard code values in query template and execute the i5SPC display template directly, I am able to see the chart with data. But, when I try to run the same template from irpt, the chart displays no data and getting null pointer exception in log viewer. Is there any issue with the draw method in this MII version ?

scripting:

try{
	jQuery.sap.require("sap.viz.library");
	var i5SPC = new com.sap.xmii.chart.hchart.i5SPCChart("Display Template","Query Template");			
	i5SPC.registerCreationEventHandler(ceController.addObject("c0c0",i5SPC));
	i5SPC.setChartWidth("640px");
	i5SPC.setChartHeight("400px");
	i5SPC.getQueryObject().setParameter("Param.1", "{\"Rowsets\":{\"Rowset\":{\"Columns\":[{\"Name\":\"ID_MIC_SEQ\"},{\"Name\":\"VL_LCL\"},{\"Name\":\"VL_UCL\"},{\"Name\":\"VL_LSL\"},{\"Name\":\"VL_USL\"},{\"Name\":\"QT_QUAL_SAMPL\"},{\"Name\":\"VL_QUAN_RESLT\"},{\"Name\":\"ID_SELCT_SETS\"}],\"Row\":[{\"ID_MIC_SEQ\":\"10\",\"VL_LCL\":\"19.279902\",\"VL_UCL\":\"19.695098\",\"VL_LSL\":\"19.35\",\"VL_USL\":\"19.6\",\"QT_QUAL_SAMPL\":\"1\",\"VL_QUAN_RESLT\":\"19.4\",\"ID_SELCT_SETS\":0}]}}}");
	i5SPC.getQueryObject().setParameter("Param.2",1);
	i5SPC.getQueryObject().setParameter("Param.3","{\"Rowsets\":{\"Rowset\":[{\"Row\":[{\"ID_DEPAR\":\"MOLD\",\"ID_WC\":\"M1802\",\"ID_ORDER_STATS_SEQ_NO\":\"1\",\"ID_PRODU_ORDER\":\"000844420155\",\"ID_INSP_LOT\":\"000046711352\",\"ID_INSP_OPERA\":\"0010\",\"ID_SEQ_NO\":10,\"ID_DEPT_INSP_TYPE\":\"CONT\",\"ID_CNTNR_NUM\":\"12\",\"DS_INSP_OPERA\":\"Initial Setup\",\"DS_MAIN_COMME\":\"\",\"DS_DEFEC_FILE_PATH\":\"\",\"FL_OPERA_RESLT\":\"1\",\"CD_POSTED_BY\":\"Test\",\"CD_INSP_BY\":\"Test\"}]}]}}");
	i5SPC.getQueryObject().setParameter("Param.4","{\"Rowsets\":{\"Rowset\":{\"Columns\":[{\"Name\":\"ID_MIC_SEQ\"},{\"Name\":\"VL_LCL\"},{\"Name\":\"VL_UCL\"},{\"Name\":\"VL_LSL\"},{\"Name\":\"VL_USL\"},{\"Name\":\"QT_QUAL_SAMPL\"},{\"Name\":\"VL_QUAN_RESLT\"},{\"Name\":\"ID_SELCT_SETS\"}],\"Row\":[{\"ID_MIC_SEQ\":\"10\",\"VL_LCL\":\"19.279902\",\"VL_UCL\":\"19.695098\",\"VL_LSL\":\"19.35\",\"VL_USL\":\"19.6\",\"QT_QUAL_SAMPL\":\"1\",\"VL_QUAN_RESLT\":\"19.4\",\"ID_SELCT_SETS\":0}]}}}");


	i5SPC.draw("div1");
}catch(err){
	sap.ui.core.BusyIndicator.hide();
	console.log("An error has occured: " + err.name + "-" + err.message);
}

Output:

Log Viewer error:

javax.xml.transform.TransformerException: java.lang.NullPointerException: while trying to invoke the method com.sap.spc.common.Specification.getLSL() of a null object loaded from field com.sap.spc.variable.VarChartCalc.mSpec of an object loaded from local variable 'this'

We are running on MII 15.0 SP4 Patch 11. Can anyone help in resolving this issue ?


Thanks,

Aravinth

Accepted Solutions (0)

Answers (0)