Birt报告同一字段的多个参数 [英] Birt Report Multiple Parameters for the same field
问题描述
只需在查询中添加两个不同名称的两个参数,并使用相同的来源(Report-Paramter)参数。没有限制,您无法多次添加相同的参数到您的查询。
添加多个?
在您的SQL查询中,您需要参数:
的SQL查询
在参数标签中,您可以根据需要将它们链接到报表输入参数,并添加两次输入参数。您的查询中的?
将以您的参数顺序替换参数的值(第一个?
= first参数,第二个?
=第二个参数等):
I am using Birt to generate reports. I want to use the same parameter twice in my where clause e.g. where date_column >= ? and date_column < ?. The '?' at this line is one parameter which points to a date (Report parameter). Adding to this in my next where clause I want to use a second parameter to find the date period again but in a different year (current year -1). I know that birt sees parameters and ? sequentially. How can I configure this?
Simply add two parameters with 2 diffenrent names to your query and use the same source(Report-Paramter) for both of your parameters. There is no restriction, that you cannot add the same paramter multiple times to your query.
Add as many ?
in your SQL query as you need parameters:
In the Parameters Tag you can link them to your Report-Input-Parameters as you like and also add a Input-Parameter twice. The ?
in your query will be replaces by the values of your parameters in the order of appereance (first ?
= first parameter, second ?
= second parameter etc.):
这篇关于Birt报告同一字段的多个参数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!