ClickHouse/tests/queries/0_stateless/02381_parseDateTime64BestEffortUS.sql

24 lines
564 B
SQL

SET output_format_pretty_display_footer_column_names=0;
SELECT 'parseDateTime64BestEffortUS';
SELECT
s,
parseDateTime64BestEffortUS(s,3,'UTC') AS a
FROM
(
SELECT arrayJoin([
'01-02-1930 12:00:00',
'12.02.1930 12:00:00',
'13/02/1930 12:00:00',
'02/25/1930 12:00:00'
]) AS s)
FORMAT PrettySpaceNoEscapes;
SELECT '';
SELECT 'parseDateTime64BestEffortUSOrNull';
SELECT parseDateTime64BestEffortUSOrNull('01/45/1925 16:00:00',3,'UTC');
SELECT 'parseDateTime64BestEffortUSOrZero';
SELECT parseDateTime64BestEffortUSOrZero('01/45/1925 16:00:00',3,'UTC');