X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/00c2e9b28c1228b2ba327223d5576d44e4fdae4d..0eb72b526bf8bbb011551ecf019f604e17a534f1:/services/api/lib/db_current_time.rb?ds=sidebyside diff --git a/services/api/lib/db_current_time.rb b/services/api/lib/db_current_time.rb index ef68b0d09a..fdb6641521 100644 --- a/services/api/lib/db_current_time.rb +++ b/services/api/lib/db_current_time.rb @@ -1,5 +1,9 @@ +# Copyright (C) The Arvados Authors. All rights reserved. +# +# SPDX-License-Identifier: AGPL-3.0 + module DbCurrentTime - CURRENT_TIME_SQL = "SELECT CURRENT_TIMESTAMP" + CURRENT_TIME_SQL = "SELECT clock_timestamp()" def db_current_time Time.parse(ActiveRecord::Base.connection.select_value(CURRENT_TIME_SQL)).to_time