Explore Courses Blog Tutorials Interview Questions
0 votes
in BI by (11.1k points)
recategorized by

I am working on a project which shows several weeks of sales, Suppose we say today was Wednesday and weeks would be displayed as Monday, Tuesday, and Wednesday and I have changed week start in data source by using the formula:

 IF Datepart('weekday', [Date])<=DATEPART('weekday', TODAY()) THEN [Revenue] END

How can I change this formula for a week to start on Monday the above formula week starts on Sunday

1 Answer

0 votes
by (22.5k points)
edited by

Modify the calculation part like this:

IF DATEPART('weekday', TODAY()) = 1 THEN [Revenue] ELSEIF Datepart('weekday', [Date])>1 AND Datepart('weekday', [Date])<=DATEPART('weekday', TODAY()) THEN [Revenue] EN

If you want to learn more about it Tableau, then go through this Tableau Training for more insights.  

Related questions

Welcome to Intellipaat Community. Get your technical queries answered by top developers!

30.5k questions

32.6k answers


108k users

Browse Categories