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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
MarkusEng1998
Resolver II
Resolver II

Create a record rank filter on three columns

I have a report, where the number of rows vary per the Discipline (e.g. Door Hardware (DFH), Plumbing, Electrical, etc.)
since I don't have PowerBI Premium, I am manually managing pagination.
 
I found a way to count the rows using a rank to filter on. So each page would be a based o a range of rank numbers.
However my table ItemsScheduleLegend has all Disciplines. I want to only create the sequential rank (e.g. 1-100) based on a filter of the Discipline, ItemRefSortRevised and DoorType (not included in the script)
Don't enumerate records not in the criteria.
 
Please advise
 
_RankDFH =
VAR __tableDFH = FILTER(ALL('ItemScheduleLegend'),[Discipline] > EARLIER('ItemScheduleLegend'[Discipline]) && 'ItemScheduleLegend'[Resp]="DFH")
VAR __tableSameDFH = FILTER(ALL('ItemScheduleLegend'),[Discipline] = EARLIER('ItemScheduleLegend'[Discipline]) && [ItemRefSortRevised]< EARLIER(ItemScheduleLegend[ItemRefSortRevised]))
Return
countrows(__tableDFH)+1 + Countrows(__tableSameDFH)
1 ACCEPTED SOLUTION
MarkusEng1998
Resolver II
Resolver II

I solved my pagination issue with a simpler approach. I created separate queries for each of the disciplines. After applying the desired filters, I added an index column. I can now filter which records display on each page. e.g. page 1 filter [index]<=40, page 2 40 > [Index} <= 80, etc.

 

Just have to figure out if there is a way to delete a report tab if the query has zero records.

View solution in original post

2 REPLIES 2
MarkusEng1998
Resolver II
Resolver II

I solved my pagination issue with a simpler approach. I created separate queries for each of the disciplines. After applying the desired filters, I added an index column. I can now filter which records display on each page. e.g. page 1 filter [index]<=40, page 2 40 > [Index} <= 80, etc.

 

Just have to figure out if there is a way to delete a report tab if the query has zero records.

Thanks for your sharing.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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