【问题标题】:How to apply multiparameter to ssrs report filter如何将多参数应用于 ssrs 报告过滤器
【发布时间】:2015-11-05 16:39:15
【问题描述】:

我有一个可以使用 4 个不同参数进行过滤的母版。我使用 iif 语句加入所有参数以过滤报告。

我现在所拥有的问题是选择多个参数时,它倾向于返回第一个参数的值,而不是全部 我的参数表达式如下:

表达式

 iif(IsNothing(Parameters!Div.Value)=0,Parameters!Div.Value
,iif(isnothing(Parameters!St.Value)=0,Parameters!St.Value
,iif(isnothing(Parameters!Sp.Value)=0,Parameters!Sp.Value
,Parameters!Hc.Value)))

价值观

=iif(IsNothing(Parameters!Div.Value)=0,Parameters!Div.Value
,iif(isnothing(Parameters!St.Value)=0,Parameters!St.Value
,iif(isnothing(Parameters!Sp.Value)=0,Parameters!Sp.Value
,Parameters!Hc.Value)))

任何帮助都会有所帮助

【问题讨论】:

    标签: reporting-services


    【解决方案1】:

    我认为您正在尝试做的事情是这样的:

    =IIF(NOT ISNOTHING(Parameters!Div.Value), Parameters!Div.Value,
     IIF(NOT ISNOTHING(Parameters!St.Value), Parameters!St.Value,
     IIF(NOT ISNOTHING(Parameters!Sp.Value), Parameters!Sp.Value,
     Parameters!Hc.Value)))
    

    您只想检查一个值吗?

    我通常单独检查每个参数,以便一次使用所有参数。虽然在某些情况下,你的理论就是你想要的。

    如果要评估所有参数,只需将它们添加到数据集、表或组的 FILTER 中即可。在Expression中选择您的字段,在Value中选择Parameter

    【讨论】:

    • 我希望根据所选参数过滤报告。目前,即使选择了多个参数,它也只返回第一个参数的值。
    • 我添加了添加过滤器的部分。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多