Error in using specific Date in a calculation in Tableau

In Tableau, sometimes we may have to perform calculations based on a specific date.

For example, your user may be interested in knowing the Sales that occured on a specific day, or you may have to use this information in some other calculation, so how you will perform such a calculation.

Conditional calculation such as:

if [Order Date] = ‘1/3/2019’ then ([Sales]) END

will throw an error “Can’t compare date and String values”.

If you write the above calculation without quotes around the date, you will still get an error “Can’t compare dates and float values’

For step-by-step instructions on how to resolve this error, visit:

Perform Calculations based on a specific date in Tableau

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.