如何显示表中记录的前3个最高金额信息? [英] How to display top 3 highest amount info for a record from a table?

查看:48
本文介绍了如何显示表中记录的前3个最高金额信息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于导入到PowerBI中的表之一,我具有公司名称,借方金额,贷方金额和净额列(计算列:借方金额-贷方金额).

现在可以从表中拉出最高的三个公司名称,以表示具有较高的借方,贷方或净额,并将其显示在磁贴上吗?可以通过使用DAX或OOTB创建度量来进行?看起来应该像这样:

 排名第一的收入排行第二12000(净额)10000(净额)5000(净额)公司名称公司名称公司名称 

我正在根据磁贴来设想以上内容,并且一旦数据源表中的任何内容更新,它们就会动态更改.不知道是否可以使用DAX进行操作,我欢迎您提出建议.任何帮助将不胜感激.谢谢.

解决方案

DAX具有

For one of the tables imported into the PowerBI, I have columns as Company Name, Debit Amount, Credit Amount and Net Amount (Calculated column: Debit Amount- Credit Amount).

Now is it possible to pull the three highest Company Names from the table in terms of having either higher Debit, Credit or Net Amount and display it on a tile? May be by creating a measure using DAX or OOTB? It should look like:

Top Grossing             Second Grossing       Third Grossing 
12000(Net Amount)        10000(Net Amount)     5000 (Net Amount)
Company Name             Company Name          Company Name

I am envisioning the above in terms of tiles and they would change dynamically once anything updates in the data source table. Not sure if this is possible to do using DAX, I am open to suggestions. Any help will be greatly appreciated. Thanks.

解决方案

DAX has a TOPN() function that you can use for this sort of thing.

The other possibility is to use the built-in advanced filtering. Under the visual level filters, choose filter type Top N, pick how many you want to show and what value you are sorting by.

这篇关于如何显示表中记录的前3个最高金额信息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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