“报告是空的” - 是bug? [英] "The Report is empty" - is bug?

查看:66
本文介绍了“报告是空的” - 是bug?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在iReport中创建了包含3个参数的报告,并且它已成功运行。该报告使用3个参数执行MS SQL stor proc:

I've created report with 3 parameters in iReport and it's running successfully. The report is execute MS SQL stor proc with 3 parameters:


  1. startdate;

  2. enddate;

  3. dept_nm(部门名称);

iReport给出了良好的结果。一旦我将jrxml文件导出到JasperReports Server 4.1,我就会收到消息报告为空。

iReport gives good result. As soon as I exported jrxml file to JasperReports Server 4.1 I have message "The report is empty".

在JasperReports Server下的存储库中,我创建了日期参数控件和dept_nm参数的单个列表值。

In the Repository under JasperReports Server I've created controls for dates parameters and single list values for dept_nm parameter.

您知道如何调试和跟踪来自???

Do you know how to debug and trace this message coming from???

推荐答案

您的查询没有返回任何数据。报告结果为空时显示消息。

Your query is returning no data. The message appears when the report result is null.

在JasperReports Server中调试此方法的最快方法是在没有返回数据时修改报告的行为。默认行为是无页面。将其更改为所有部分,无详细信息。这样您至少可以获得报告标题和摘要带。

The quickest way to debug this in JasperReports Server is to modify the report's behavior when no data is returned. The default behavior is "No Pages". Change it to "All Sections, No Details". That way you'll get at least the report title and summary band.

在标题区显示您的参数以查看它们的值。通常它们不是你所期望的。例如,您的输入控件是StartDate,但您的参数是startdate。所以参数没有得到你想象的值。

Display your parameters in the title band to see what their values are. Often they aren't what you expect. For example, your input control is "StartDate", but your parameters is "startdate". So the parameter doesn't get the value you thought it would.

这篇关于“报告是空的” - 是bug?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆