Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
streep1
Regular Visitor

Current Week/Year Values - With two different data sets in the same table.

Hello

I previously had a solved query regarding how to find the current week and the current year values by using -

 

CurrentWeekCurrentYear =
VAR CurrYear =
MAXX(allselected('Data'),'Data'[Current Year] )
VAR CurrWeek =
MAXX(Filter(allselected('Data'), 'Data'[Current Year] =CurrYear ),'Data'[Fin_Week_No_2_Char] )
RETURN
CALCULATE(
SUM('Data'[DERAnswer]),
FILTER(ALLSELECTED('Data'),[Fin_Week_No_2_Char]=CurrWeek && 'Data'[Current Year]=CurrYear),
VALUES('Data'[LDN_Region]),
VALUES('Data'[OrgName])
)
 
However now my data table has a new '[data_set]' flow - 'Data A' and 'Data B', as a result I am double counting values.
How can I filter by [data_set]?
I've been trying to include this within the VAR, but keep getting a Booleen error and the SEARCH isn't helping?
 
Any tips would be great! Many thanks
 
3 REPLIES 3
v-kelly-msft
Community Support
Community Support

Hi @streep1 ,

 

Can you attach the screenshot of your data model with the relationship?

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

Hello

 

Apologies - The data just comes as a flat file, with the [data_set] field distinguishing between A and B 

 

Many thanks

 

P

Hi @streep1 ,

 

Pls forgive my misunderstanding,do you wanna filter out the data by Date A and Date B?

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.