# Need help on explanation

Hello everyone,
Can someone help me to understand what is the logic behind my measures.
I’ve uploaded my PBIX as attached.

So basically I have this measure (which I have on this forum as well ):
Aging =
CALCULATE(
DATEDIFF(
SELECTEDVALUE( FactInternetSales[DueDate] ),
[SelectedDate],
DAY
),
ALLSELECTED(
DimDate[FullDateAlternateKey]
)
)

This is to calculate My transaction table’s date (DueDate) to the date in the slicer. For this measure, I just want to confirm, that the phrase " SELECTEDVALUE( FactInternetSales[DueDate] )," is meaning for the current row when I put my transaction to a table, am I correct ?

My main confusion is how to create a measure that “synchronize” with the current row display on my table. So what I want is to create a measure that only specify that the value of the 1st measure is either “small” or “big”

Since I create the measure, like this :
AgingCategory =
VAR SO = SELECTEDVALUE(FactInternetSales[SalesOrderNumber])
RETURN CALCULATE(
IF([Aging with Total]<=1,“small”,“big”),
FactInternetSales[SalesOrderNumber] = SO
)
When I put that in my table, it looks like it display all of my data in transactions instead the correct previous rows.

So basically, in that PBIX, my transaction table is FactInternetSales. and already correct measure of “Age”, and I’m added another (which not work) called AgingCategory.into the Table Visual Studio.Testing_AgingAdventureWorksDW_Import - solution2.pbix (737.8 KB)

I’m sorry, but I a beginner in DAX, and still in learning phase.

Thanks

I’m working on a response to your questions raised in the thread below that should also answer all your questions here. Should have something back to you later this evening.

• Brian

Hi Brian,
Appreciate it.
Sorry, doesn’t mean I’m too “pushy” though, just curious. If that is the case, by all means, no rush.