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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
Stuk
Helper I
Helper I

Help 3 questions/problems

Hello everyone ! 
- my calendar don't work anymore "calendrier = CALENDAR(01/01/2015;
TODAY())"
- when he will works how can i use it to filter a graphics to the 14 last days
- Do you have any good docs for dax language because i want to create column with the datas of others column of my database 

1 ACCEPTED SOLUTION
Datatouille
Solution Sage
Solution Sage

Hi @Stuk

 

1) Calendrier = CALENDAR( "01/01/2015" , TODAY() ) works. You need the ""

Calendrier = CALENDAR( DATE(2015;1;1) , TODAY() ) also works !

 

2) Supposing you retrieve the last 14 days in a separate table called Last14days: 

Last14days = CALCULATETABLE( Calendrier ,  DATESINPERIOD( Calendrier[Date] ,TODAY() ,-14 , DAY) ) works fine.

 

You can then use :

- this brand new table Last14days as a filter in a measure with a calculate : SalesofLast14Days = Calculate ( [Total Sales] , Last14Days )

- or the date column of Last14days table as an X axis in your chart(s).

 

You can adjust the parameters of DatesInPeriod() whether you want to start from today() or today()-1 !

 

3) Please refer to my reply to this post for DAX resources.

 

Hope It helps you 🙂 Feel free to ask if you have any questions!

 

Tristan

Data & BI consultant at AZEO

 

View solution in original post

1 REPLY 1
Datatouille
Solution Sage
Solution Sage

Hi @Stuk

 

1) Calendrier = CALENDAR( "01/01/2015" , TODAY() ) works. You need the ""

Calendrier = CALENDAR( DATE(2015;1;1) , TODAY() ) also works !

 

2) Supposing you retrieve the last 14 days in a separate table called Last14days: 

Last14days = CALCULATETABLE( Calendrier ,  DATESINPERIOD( Calendrier[Date] ,TODAY() ,-14 , DAY) ) works fine.

 

You can then use :

- this brand new table Last14days as a filter in a measure with a calculate : SalesofLast14Days = Calculate ( [Total Sales] , Last14Days )

- or the date column of Last14days table as an X axis in your chart(s).

 

You can adjust the parameters of DatesInPeriod() whether you want to start from today() or today()-1 !

 

3) Please refer to my reply to this post for DAX resources.

 

Hope It helps you 🙂 Feel free to ask if you have any questions!

 

Tristan

Data & BI consultant at AZEO

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 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.