KNOWLEDGE BASE

Importing Data as Date from Separated Year and Month Columns


Published: 21 Mar 2014
Last Modified Date: 02 Sep 2016

Question

How to have a field of type date when the year and the month are stored in the data source as two separated columns, and, when importing data, Tableau recognize these two columns as string dimensions, not as date.

Environment

Tableau Desktop

Answer

Create a calculated field that parses the concatenation of the two string fields:
DATEPARSE("MMMM.yyyy",[Month] + "." + STR([Year]))

 
Did this article resolve the issue?