Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/324.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 关于嵌入式pentaho报告引擎日志查询_Java_Pentaho - Fatal编程技术网

Java 关于嵌入式pentaho报告引擎日志查询

Java 关于嵌入式pentaho报告引擎日志查询,java,pentaho,Java,Pentaho,我在Java应用程序中集成了报告引擎。我最近将petaho reporting升级为3.8.2。我面临着升级的问题,所以我打开pentaho日志来查看发生了什么。我得到了以下相关日志。有人能解释一下它的意思吗?从这些日志中,我假设Data factory无法找到查询参数的值,而是设置为null。如果是这样的话,我不明白为什么会这样,因为在代码中,我正在主报告中设置这些参数值,如下所示。类似地,我正在设置其他参数值 vReport.getParameterValues().put("propert

我在Java应用程序中集成了报告引擎。我最近将petaho reporting升级为3.8.2。我面临着升级的问题,所以我打开pentaho日志来查看发生了什么。我得到了以下相关日志。有人能解释一下它的意思吗?从这些日志中,我假设Data factory无法找到查询参数的值,而是设置为null。如果是这样的话,我不明白为什么会这样,因为在代码中,我正在主报告中设置这些参数值,如下所示。类似地,我正在设置其他参数值

vReport.getParameterValues().put("propertyId", pPropertyId);
我说的日志在这里

Sep 20 16:00:44,540 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Detected parameter:[dateFormat, dateFormat, dateFormat, dateTimeFormat, dateTimeFormat, bookedFrom, bookedTo, propertyId]
Sep 20 16:00:44,561 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 1 set to <null>
Sep 20 16:00:44,561 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 2 set to <null>
Sep 20 16:00:44,562 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 3 set to <null>
Sep 20 16:00:44,562 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 4 set to <null>
Sep 20 16:00:44,563 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 5 set to <null>
Sep 20 16:00:44,563 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 6 set to <null>
Sep 20 16:00:44,564 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 7 set to <null>
Sep 20 16:00:44,564 DEBUG SimpleSQLReportDataFactory - [ IP=0:0:0:0:0:0:0:1, Property=72, Req=6 ] - Parametrize: 8 set to <null>
Sep 20 16:00:44540调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:1,属性=72,请求=6]-检测到的参数:[dateFormat,dateFormat,dateFormat,dateTimeFormat,dateTimeFormat,bookedFrom,bookedTo,propertyId]
九月20日16:00:44561调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:1,属性=72,请求=6]-参数化:1设置为
九月20日16:00:44561调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:1,属性=72,请求=6]-参数化:2设置为
九月20日16:00:44562调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:0:1,属性=72,请求=6]-参数化:3设置为
九月20日16:00:44562调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:0:1,属性=72,请求=6]-参数化:4设置为
九月20日16:00:44563调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:0:1,属性=72,请求=6]-参数化:5设置为
九月20日16:00:44563调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:0:1,属性=72,请求=6]-参数化:6设置为
九月20日16:00:44564调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:0:1,属性=72,请求=6]-参数化:7设置为
九月20日16:00:44564调试SimpleSQLReportDataFactory-[IP=0:0:0:0:0:0:1,属性=72,请求=6]-参数化:8设置为

提前感谢。

Pentaho Reporting将仅在您在报告中声明正确参数的情况下使用您的参数值。仅仅添加随机名称-值对是行不通的

所以,至少声明所有要使用的参数。在最通用的版本中,假设您自己对用户输入进行了正确的验证,并且您可以保证传入的值是安全有效的,请将此代码与所有参数一起使用:

final ModifiableReportParameterDefinition parameterDefinition =
    (ModifiableReportParameterDefinition) report.getParameterDefinition();
parameterDefinition.addParameterDefinition(new PlainParameter("dataFormat", Object.class));