Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions integration_tests/docker-compose-vertica.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ services:
VERTICA_SCHEMA: ${SCHEMA_NAME}
APP_DB_USER: dbadmin
APP_DB_PASSWORD: vertica
# Deliberately not UTC: keeps the suite honest about macros that must
# use UTC rather than the server's local time.
TZ: "America/Los_Angeles"
VERTICA_DB_NAME: elementary_tests
VMART_ETL_SCRIPT: ""
Expand Down
6 changes: 6 additions & 0 deletions macros/utils/cross_db_utils/current_timestamp.sql
Original file line number Diff line number Diff line change
Expand Up @@ -114,3 +114,9 @@
-- Dremio CURRENT_TIMESTAMP() is always in UTC
current_timestamp()
{%- endmacro -%}

{% macro vertica__edr_current_timestamp_in_utc() -%}
{#- dbt's default falls back to the session-local current_timestamp, which
is off by the server's UTC offset whenever Vertica is not set to UTC. -#}
cast(current_timestamp at time zone 'UTC' as timestamp)
{%- endmacro -%}
Loading