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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Syndicate_Admin
Administrator
Administrator

filter Table of holidays

Hello, I have a measurement to calculate the delivery days, taking into account working days and holidays:

"DiasCierre = NETWORKDAYS ( PLZENT [F.PED] , PLZENT [F.Cie.PED] , 1 , VALUES ( FestPto [FechaFest] )"
Orders are from different PTOVTA outlets.
And the festive table contains the PTOVTA and FechaFest columns.
How do I get PTOVTA Fest to filter dates?
It currently takes into account the public holidays of all PTOVTA
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Joseluislg 

 

You can try something like below. It is a column formula here.

Delivery Days = 
VAR pto = PLZENT[PtoGestion]
RETURN
NETWORKDAYS(PLZENT[Start date], PLZENT[End date], 1, CALCULATETABLE(VALUES(FestPto[FechaFest]),FestPto[PtoGestion]=pto))

 

Additionally, if there is a relationship between two tables on PtoGestion column and the cross-filter direction is Single (PLZENT filters FestPto), you can also try this for a column

Delivery Days 2 = 
NETWORKDAYS(PLZENT[Start date], PLZENT[End date], 1, SELECTCOLUMNS(RELATEDTABLE(FestPto),"holidays",'FestPto'[FechaFest]))

 

Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Joseluislg 

 

You can try something like below. It is a column formula here.

Delivery Days = 
VAR pto = PLZENT[PtoGestion]
RETURN
NETWORKDAYS(PLZENT[Start date], PLZENT[End date], 1, CALCULATETABLE(VALUES(FestPto[FechaFest]),FestPto[PtoGestion]=pto))

 

Additionally, if there is a relationship between two tables on PtoGestion column and the cross-filter direction is Single (PLZENT filters FestPto), you can also try this for a column

Delivery Days 2 = 
NETWORKDAYS(PLZENT[Start date], PLZENT[End date], 1, SELECTCOLUMNS(RELATEDTABLE(FestPto),"holidays",'FestPto'[FechaFest]))

 

Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

Syndicate_Admin
Administrator
Administrator

I tried this but it gives an error:

CALCULATE(NETWORKDAYS(PLZENT[F.PED],PLZENT[F.Cie.PED],1,values(Holidays[FechaFest])),Holidays[PtoGestion]=PLZENT[PtoGestion] )

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.