Skip to content

Commit

Permalink
Safer display date parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
alecgorge committed Jan 5, 2020
1 parent 81fe0a4 commit fae06bf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion RelistenApi/Services/Importers/ImporterBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@ INSERT INTO
source.artist_id,
COALESCE(setlist_show.date, CASE
WHEN MIN(source.display_date) LIKE '%X%' THEN to_date(MIN(source.display_date), 'YYYY')
ELSE to_date(MIN(source.display_date), 'YYYY-MM-DD')
ELSE to_date(LEFT(MIN(source.display_date), 10), 'YYYY-MM-DD')
END) as date,
MIN(source.display_date) as display_date,
MAX(source.updated_at) as updated_at,
Expand Down

0 comments on commit fae06bf

Please sign in to comment.