5

I'm getting this error message:

Datetime column not provided as part table configuration and is required by this type of chart

I'd like to create a chart showing change in total volume over time. I have a date field created as a column that I'd like to use as a datetime but cannot figure out how.

Data is an uploaded .csv file.

How do you change a column to datetime in table configuration?

TylerH
  • 20,799
  • 66
  • 75
  • 101
David Shinabarger
  • 143
  • 1
  • 3
  • 12

4 Answers4

2

How do you change a column to datetime in table configuration?

You should be fine casting that column to a timestamp instead.

Superset complains about a missing datetime column because it's written in Python; but assuming you're querying a postgres DB, the equivalent type would be timestamp.

If your datasource is based off a query; you should be able to cast the date type to timestamp (use ::timestamp or to_timestamp()) and use that as your "datetime" column.

David Tobiano
  • 1,188
  • 8
  • 10
0

In process of uploading the CSV file, we should set up names of columns with dates: For example

0

Check if you have date or time series in your data. Once you make sure of that, if the format of the date just year, then the DATETIME format is this '%Y'.

If the format is yyyy/mm/dd then the DATATIME format is "%Y/%m/%d" and for the rest of the formats check here.

All these formats had to be edited in the edit dataset window in supersetclick here for image.

Go with the documentation it helps a lot.

DevThiman
  • 920
  • 1
  • 9
  • 24
-1

Define in CSV to Database configuration before uploading:

Stephen Ostermiller
  • 23,933
  • 14
  • 88
  • 109
Lyman
  • 1
  • 1