如何从子数据集中向报表添加变量? [碧玉] [英] How to add variable from subdataset to report? [Jasper]
本文介绍了如何从子数据集中向报表添加变量? [碧玉]的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个子数据集,其中包含要在报表中显示的计算变量.但是,当将此变量拖放到报告中时,会出现以下消息:
I have sub Dataset that include a calculated variable that I want to show in the report. But when dragging and dropping this variable into the report the following message appears:
您将对象从子数据集拖放到报表中,这不是 可能.
You drop an object from a subdataset to the report, this is not possible.
如何克服?
推荐答案
已经有一个解决方案发布在- 解决方案1
There is a solution which is already posted at - Solution-1
但是,我要发布一组屏幕截图以从UI演示相同的内容-
However, I am posting a set of screenshots to demonstrate the same from UI -
- 在主数据集中定义
var
- 注意-计算应设置为System
- 在子数据集中定义另一个
variable
- - 选择子数据集元素(在示例中为表格)并创建
Return Values
映射- - 在报告中,拖放主数据集中定义的
variable
并确保将评估设置为Report
-
- Define
var
in the main data set - Note - Calculation should be set toSystem
- Define another
variable
in the sub data set - - Select the sub data set element ( it is a table in the example) and create
Return Values
mapping - - In the report, drag and drop
variable
defined in the main data set and ensure the evaluation is set toReport
-
那应该做到的!
这篇关于如何从子数据集中向报表添加变量? [碧玉]的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文