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
Dear all,
I'm currenty working on issue to get only first value on Marix within Month, I used Firstnonblankvalue but I get the result without month, as you can see below I want to get only the yellow values:
Best regrads
Solved! Go to Solution.
Thanks for the reply from @tamerj1 , please allow me to provide another insight:
Hi @Dizzy ,
I created some data:
Here are the steps you can follow:
1. Create measure.
Measure =
var _date=
MINX(
FILTER(ALL('Table'),
'Table'[Account Number Name CRM]=MAX('Table'[Account Number Name CRM])&&
'Table'[Month_Year]=MAX('Table'[Month_Year])&&
'Table'[Value]<>BLANK()),[Date])
return
SUMX(
FILTER(ALL('Table'),
'Table'[Account Number Name CRM]=MAX('Table'[Account Number Name CRM])&&
'Table'[Month_Year]=MAX('Table'[Month_Year])&&
'Table'[Date]=_date),[Value])
2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @Dizzy
Following the sample file created by @v-yangliu-msft, please try the following
Measure =
SUMX (
SUMMARIZE ( 'Table', 'Table'[Account Number Name CRM], 'Table'[Month_Year] ),
VAR CurrentMonth =
'Table'[Month_Year]
VAR CurrentAccountTable =
FILTER (
CALCULATETABLE (
'Table',
ALLEXCEPT ( 'Table', 'Table'[Account Number Name CRM] )
),
'Table'[Value] <> BLANK ( )
)
VAR FirstRecord =
TOPN ( 1, CurrentAccountTable, 'Table'[Date], ASC )
VAR FirstMonth =
MAXX ( FirstRecord, 'Table'[Month_Year] )
VAR FirstValue =
MAXX ( FirstRecord, 'Table'[Value] )
RETURN
IF ( CurrentMonth = FirstMonth, FirstValue )
)
Thanks for the reply from @tamerj1 , please allow me to provide another insight:
Hi @Dizzy ,
I created some data:
Here are the steps you can follow:
1. Create measure.
Measure =
var _date=
MINX(
FILTER(ALL('Table'),
'Table'[Account Number Name CRM]=MAX('Table'[Account Number Name CRM])&&
'Table'[Month_Year]=MAX('Table'[Month_Year])&&
'Table'[Value]<>BLANK()),[Date])
return
SUMX(
FILTER(ALL('Table'),
'Table'[Account Number Name CRM]=MAX('Table'[Account Number Name CRM])&&
'Table'[Month_Year]=MAX('Table'[Month_Year])&&
'Table'[Date]=_date),[Value])
2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Thank you.
This is not why I'm locking for.
In your example, it schould be only Feb 2024 for A and C Only Jan.
Ony first value sorted by Month.
Hi @Dizzy
Please elaborate on your expected result perhaps on top of the example that you've provided.
Hi @tamerj1
the value what I expected are in yellow in sorted by Fiscal Month.
The Last Row in my example is returned two values one in august and other one in january, I want to have at the end only august.
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 |
---|---|
25 | |
18 | |
15 | |
9 | |
8 |
User | Count |
---|---|
37 | |
32 | |
18 | |
16 | |
13 |