Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi
I have table A and I want to create table B , which is only keeping latest value from max=index using dax
Is it possible ?
many thanks
Hi @Anonymous ,
I created a sample pbix file(see attachment) for you, please check whether that is what you want. You can achieve it in Power Query Editior by the following codes:
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("pcmxDQAgCATAXagt4BFlF+L+a6iN9NhdchGkLNQIDLCJHaoarVaLnjE/Y2b4ZyBjXCqXw19A6rE2", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Index = _t, DATE = _t, VALUE = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Index", Int64.Type}, {"DATE", Int64.Type}, {"VALUE", Int64.Type}}),
#"Grouped Rows" = Table.Group(#"Changed Type", {"VALUE"}, {{"MaxIndex", each List.Max([Index]), type nullable number}, {"Details", each _, type table [Index=nullable number, DATE=nullable number, VALUE=nullable number]}}),
#"Expanded Details" = Table.ExpandTableColumn(#"Grouped Rows", "Details", {"Index", "DATE"}, {"Index", "DATE"}),
#"Added Custom" = Table.AddColumn(#"Expanded Details", "Display", each if [MaxIndex]=[Index] then 1 else 0),
#"Filtered Rows" = Table.SelectRows(#"Added Custom", each ([Display] = 1)),
#"Removed Columns" = Table.RemoveColumns(#"Filtered Rows",{"MaxIndex", "Display"})
in
#"Removed Columns"
If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.
How to upload PBI in Community
Best Regards
Hi @Anonymous ,
You could create a measure as below and use it as visual level filter:-
Measure =
if(MAX('Table'[Index]) = CALCULATE(MAX('Table'[Index]),ALL('Table')),1,0)
Thanks,
Samarth
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
@Anonymous , Please create it as measure instead of column.
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Still same, it's only have one value = 1, no 0 in measure
@Anonymous ,Since all the details of three records are same thats why it will display only 1 record on visual. If you have any other column which can act as distinct then you have to add that column as well on visual.
Best Regards,
Samarth
If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.