i am trying to solve this question in 2 ways, in first one “date” column is of type ‘varchar’
,and in the 2nd ,“cleaned_date” column is of ‘timestamp’ type.What am i doing wrong please specify,
Both are giving errors,for first one error is:
ERROR: date/time field value out of range: “01/31/2014”
HINT: Perhaps you need a different “datestyle” setting.
SQL state: 22008
and for 2nd the error is:
ERROR: function left(timestamp without time zone, integer) does not exist
LINE 1: SELECT LEFT(“cleaned_date”,10)::varchar AS new_date
HINT: No function matches the given name and argument types. You might need to add explicit type casts.
SQL state: 42883