Skip to content

Commit acf923e

Browse files
authored
Add CAST to timestamp_default_dtype to postgres__string_to_timestamp
1 parent f86a46a commit acf923e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

macros/supporting/string_to_timestamp.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
{%- endmacro -%}
2121

2222
{%- macro postgres__string_to_timestamp(format, timestamp) -%}
23-
TO_TIMESTAMP('{{ timestamp }}', '{{ format }}')
23+
CAST(TO_TIMESTAMP('{{ timestamp }}', '{{ format }}') AS {{ datavault4dbt.timestamp_default_dtype() }})
2424
{%- endmacro -%}
2525

2626
{%- macro redshift__string_to_timestamp(format, timestamp) -%}

0 commit comments

Comments
 (0)