传递给查询的 PowerBI 切片器值

编程入门 行业动态 更新时间:2024-10-23 13:33:03
本文介绍了传递给查询的 PowerBI 切片器值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我有一个从 SQL 查询生成的报告,其中包含一个截止日期列.我的要求是创建一个切片器,无论用户在切片器中选择什么日期,报告都应显示截止日期小于所选切片器日期的所有数据.

I have a report generated from a SQL query, having a due date column. My requirement is to create a slicer and  whatever the date a user selects in the slicer the report should show all the data where due date is less than the selected slicer date.

我无法将切片器日期传递给我的 SQL 查询.

I am not able to pass the slicer date to my SQL query. 

你能指导我找到最好的方法吗?

Can you guide me guys in finding the best possible way?

推荐答案

这在一般情况下是不可能的.在报表页面上设置的切片器和过滤器不能修改模型(例如计算表或计算列),也不能修改查询.

This is not possible in general. Slicers and filters set on a report page cannot modify the model (e.g. calculated tables or calculated columns) and cannot modify the queries.

执行此类操作的唯一可能方法是使用 DirectQuery,它会在后台自动执行此操作,因为它仅动态查询所需数据.否则,您需要预先加载您打算在报告中使用的所有数据.

The only possible way to do this sort of thing is with a DirectQuery, which does it automatically in the background since it dynamically queries only the needed data. Otherwise, you need to pre-load all of the data that you intend to use in the report.

使用 DirectQuery 有很大的局限性,可能或者可能不适用于您的用例.有关详细信息,请查看链接文档中的限制和注意事项.

Using DirectQuery has significant limitations and may or may not work for your use case. Please check the limitations and considerations in the linked documentation for details.

更多推荐

传递给查询的 PowerBI 切片器值

本文发布于:2023-10-30 19:19:40,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1543756.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:切片   PowerBI

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!