LoginSignup
0
0

More than 3 years have passed since last update.

Heoku postgresqlの時間設定を日本時間に直す

Posted at

概要

heroku初心者です。herokuのPostgresqlの時間設定を日本時間へ変更したいので調べてみました。

herokuのDBへ接続

heroku pg:psql

現在の時間を表示

select NOW();

 now              
------------------------------
 2021-01-26 22:14:24.35026+00
(1 row)

日本時間へ変更する

Set timezone TO 'Asia/Tokyo';

select NOW();
              now              
-------------------------------
 2021-01-27 07:15:16.055218+09
(1 row)

終了

CTRL+D

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0