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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Rewind
Helper I
Helper I

Fortnight Flag (every 14 days) with DAX?

I have a dim_date table and I'd like to be able to flag every second Wednesday beginning at a specific date.

 

Is this possible with DAX? I found a few examples flagging all the dates within a period but I only really need the specific day.

 

Thanks

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Rewind , First find the first Wednesday or choose a hard coded date

Try like

a new column =

var _first = minx(filter(Date,  weekday([Date],2)=3) , [Date])

var _diff = Mod(Quotient(datediff(_first , [Date], day),7),2)

return

if(_diff =0, true(), false())

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Rewind , First find the first Wednesday or choose a hard coded date

Try like

a new column =

var _first = minx(filter(Date,  weekday([Date],2)=3) , [Date])

var _diff = Mod(Quotient(datediff(_first , [Date], day),7),2)

return

if(_diff =0, true(), false())

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thank you - works perfectly.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

March2025 Carousel

Fabric Community Update - March 2025

Find out what's new and trending in the Fabric community.

Top Kudoed Authors