Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi,
Looking for some help! I need to add a line number to a table in PBI, however, everything i try is too slow to populate even when i have it filtered with just a handful of options. I created an index in power query and then used the below measure. I need this to be dynamic when they filter in the report and i only have the order number to rank off of. Any tips would be appreciated!
Hi @Bryanna ,
Thank you for reaching out to the Microsoft Community Forum.
You are trying to create a dynamic row number in Power BI when filter in the report based on "Order Number".
Please follow below steps.
1. I have created table "Table" based on your sample data. refer snap.
2. Created measure "Row Number" with below DAX , it will create dynamic row number.
If this information is helpful, please “Accept it as a solution” and give a "kudos" to assist other community members in resolving similar issues more efficiently. Please do let us know if you have any further queries.
Regards,
Dinesh
Plase clarify if you are looking for a calculated column (a static thing) or a measure (dinamic thing). Assume you are looking for a measure but just to be sure.
More importantly, please provise a sample of the table and a clear explanation of what you want to rank: you want to rank the order nr in an asceding way? And you want the ranking to be based only on the visible values in the matrix?
And what is the issue you have with your formula in use?
Best
FB
I keep receiving this error but there are no duplicate order numbers in the table.
A single value for column 'Order Number' in table 'Order Rank' cannot be determined. This can happen when a measure or function formula refers to a column that contains many values without specifying an aggregation such as min, max, count, or sum to get a single result.
@Bryanna , Hi, you may try
Row Number =
RANKX(
ALLSELECTED('Order Rank'),
'Order Rank'[Order Number],
,
ASC,
DENSE
)
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
10 | |
9 | |
8 | |
8 | |
7 |
User | Count |
---|---|
13 | |
12 | |
11 | |
11 | |
8 |