agora inbox for pgsql-sql@postgresql.org
help / color / mirror / Atom feedFrom: Adrian Klaver <adrian.klaver@aklaver.com>
To: op12om@yahoo.co.in <op12om@yahoo.co.in>
To: Postgres General <pgsql-general@postgresql.org>
To: Postgres List <pgsql-sql@postgresql.org>
Subject: Re: Getting wrong time using now()
Date: Tue, 12 Feb 2019 15:40:50 -0800
Message-ID: <187833af-6e2d-e84a-da49-62d6da8b2ccc@aklaver.com> (raw)
In-Reply-To: <747290055.2254380.1550014566188@mail.yahoo.com>
References: <747290055.2254380.1550014566188.ref@mail.yahoo.com>
<747290055.2254380.1550014566188@mail.yahoo.com>
On 2/12/19 3:36 PM, Om Prakash Jaiswal wrote:
> Create table service_record(Id into, time timestamp without time zone
> default now()).
> Postgresql version 9.6.6, RHEL7.6 , when I am executing the query. I am
> getting time 5:30hours behind current time. Please solve it
Move clock back 5:30 hours:).
On serious note:
1) I would change the time field to timestamp with timezone.
2) Verify what timezone the server is running on:
show timezone;
TimeZone
------------
US/Pacific
>
>
> Regards
> Om Prakash
> Bangalore, India
>
> Sent from Yahoo Mail on Android
> <https://go.onelink.me/107872968?pid=InProduct&c=Global_Internal_YGrowth_AndroidEmailSig__Android...;
--
Adrian Klaver
adrian.klaver@aklaver.com
view thread (3+ messages) latest in thread
Message-ID: <187833af-6e2d-e84a-da49-62d6da8b2ccc@aklaver.com>
Permalink: ../187833af-6e2d-e84a-da49-62d6da8b2ccc@aklaver.com/
Also on: postgresql.org/message-id/187833af-6e2d-e84a-da49-62d6da8b2ccc@aklaver.com
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: adrian.klaver@aklaver.com, op12om@yahoo.co.in, pgsql-general@postgresql.org
Subject: Re: Getting wrong time using now()
In-Reply-To: <187833af-6e2d-e84a-da49-62d6da8b2ccc@aklaver.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox