Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Rana_Rumeel
Helper II
Helper II

Dynamic Row count in a column

Hi Guys,

I am looking for some help, Basically I have 4 columns in my data table in Excel.
Requirement is to use matrix visualization with Index column.
For this I created Index column and used in matrix's column. Here comes the issue statement.
When all filters selected then this Index is working fine. But if I am choosing some filter vaalue then this Index is not working as Expected. As in 2nd screenshot you can see that index starting from 1 but then 5 and then 11 but I need 1,2,3

I know this Index is pre calculated values. But I need a Column which display the rows serial number in tables.

Best RegardsOverAllIndex.JPGSelectedFilterIndex.JPGSelectedFilterIndex2.JPG

3 REPLIES 3
SpartaBI
Community Champion
Community Champion

@Rana_Rumeel it's the normal beaviour as there aren't any values to show for these rows when your filters apply.
You can choose in the visual settings to show rows wit no data like this:

SpartaBI_0-1655820738161.png

 


2022-05-19 17_30_22-Re_ Need help on DAX function with measure vs colu... - Microsoft Power BI Commu.png


Full-Logo11.png

SpartaBI_3-1652115470761.png   SpartaBI_1-1652115142093.png   SpartaBI_2-1652115154505.png

Showcase Report – Contoso By SpartaBI

@SpartaBI yes you are right that, this is working correctly. but I am looking for something Dynamic.
Could you please have a look into this screen shot.

image.png
Like when ever this Matrix display data, the Index must start with 1,2,3,4,..., Even if data is filtered out but index needs to work like a Serial #.

Please confirm if there is way to achive this...

@Rana_Rumeel The index column you now have definitely can not changed like this. It's a column. In order for something to change it's values based on filters it needs to be a measure and in the way you now have the matrix you want you need to do much more, like creating parameter tables / calculation groups and add a lot of logic to your model. Don't think it's worth your effort and it will take a lot of time to also create the solution for that to show here.
If you didn't have the 'Control' on the columns and you only had model columns on the rows of the matrix and then measures as the columns you could create a ranking measure based on the index column that will give you that result but the original index column will anyway need to stay on the visual.
Anyway, I suggest stay with your solution now 🙂

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.