March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
I am trying to Add a Column ("Max_Quote_Date") that returns the Max Date of another Column ("Quote_Date") with 2 conditions ("Investment_Key","Month_Date"), using the following expression;
#"Added Max Quote Date" = Table.AddColumn(#"Filtered Rows1", "Max_Quote_Date", each
List.Max(#"Filtered Rows1"[Quote_Date],
[Investment_Key] = #"Filtered Rows1"[Investment_Key] and [Month_Date] < #"Filtered Rows1"[Month_Date]
)
)
It doesnt seem to be applying both conditions. And the performance is very slow.. I am sure there is a more efficient method.
Below is a visual illustration of what i am trying to achieve;
I liken this to an "inline subquery" in terms of SQL.
Any ideas?
Thanks much for your support.
firstly, the conditions are unclear, try to explain in words what you want and what conditions must be met
secondly, share data that will help you
Where
[Investment_Key] = #"Filtered Rows1"[Investment_Key] and [Month_Date] < #"Filtered Rows1"[Month_Date]
[Investment_Key] this is Value
#"Filtered Rows1"[Investment_Key] this is List
why do you want to compare the value with the List🙄
so I ask what do you need?
If we reference the visual, I am indicating that I want to return (in a new column) the yellow-shaded value where it is currently null.
Which means I want to find the Max(Quote_Date) Where the Investment_Key = the Prior Step Investment Key and the Month_Date < the Prior Step Month_Date.
9/30/23 = Max(Quote_Date) Where Investment_Key = Aeva Tech And Month_Date < 10/31/23.
Hi,
If you are amenable to the idea of solving it with a calculated column DAX formula, then share some data to work with (in a format that can be pasted in an MS Excel file).
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
123 | |
85 | |
85 | |
70 | |
51 |
User | Count |
---|---|
205 | |
153 | |
97 | |
79 | |
69 |