This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
am using below dax to pass a date selection from query 1 date table into the dax custom column, but it seems like the selection is not working, how can I manage to do this:
Hi @Anmolgan
try a measure
Measure =
var reference_date= SELECTEDVALUE(Query1[FullDateAlternateKey])
return
STARTOFMONTH(reference_date)
or column
Column1 =
var reference_date= CALCULATE(MAX(Query1[FullDateAlternateKey]))
return
STARTOFMONTH(reference_date)
@az38
can I not use this in a custom column? I have a datediff formula date works on the basis of this dax and that goes like this:
@az38 so I am trying to calculate aging bucket on the basis of selection of a date field:
I have a custom column where I convert any selected that to 1st of each month, need to figure out how can I use custom column here:
see my post above.
your Month Measure will look like
Month =
var _effDate = MAX(pcc_view_ar_aging[effective_date])
RETURN
DATEDIFF(_effDate , [Measure], MONTH)
Your New aging bucket measure will be similar with
New aging bucket =
var _Month = [Month]
var _effDate = MAX(pcc_view_ar_aging[effective_date])
RETURN
SWITCH(TRUE(),
MONTH(_effDate) = MONTH([Measure11]) && YEAR(_effDate) = YEAR([Measure11]) && _effDate <= TODAY(), "Current",
_Month > 0 && _Month <= 12, CONCATENATE(30 * _Month, " Days"),
"greater than current month aging"
)
@az38 I did not understand this line can you explain a bit, so that I can built the bucket and validate with the actual one in my column.
if you need your visual reacts to slicer you need to create a Measure and not a Column.
I do not completely understand your business logic, as I do not see any examples of data and desired result both. So, I Can not be sure in the correct statements for you
@az38 I have attached an output screenshot of what I am getting when I am creating my bucket and passing a hardcoded date to refersh date, please view the screenshot:
you are trying to implement what-if logic which described here https://docs.microsoft.com/en-us/power-bi/desktop-what-if
it will work with measure
try to re-write your formula as a Measure
Month =
var _effDate = MAX(pcc_view_ar_aging[effective_date])
RETURN
DATEDIFF(_effDate , [Measure], MONTH)
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 28 | |
| 23 | |
| 22 | |
| 16 | |
| 16 |
| User | Count |
|---|---|
| 60 | |
| 35 | |
| 28 | |
| 22 | |
| 21 |