Converting timestamp to timestamptz without rewriting tables

2017-12-18 Thread Tom Dunstan
Hi all We have generally been using timestamps without timezones in our system. As both our app servers and db server were set to UTC it so far hasn't been an issue. However, that may not always be the case, so we want to tighten things up a bit. We are also needing to do things like get the parti

Re: Converting timestamp to timestamptz without rewriting tables

2017-12-18 Thread Corey Taylor
On Mon, Dec 18, 2017 at 2:18 AM, Tom Dunstan wrote: > >> >> A timestamptz stores everything as UTC and the value is converted to the session time zone upon retrieval. > > > Which is exactly what we want. If a random person can interject here, I believe what Tom Dunstan is asking about here is the

Re: Converting timestamp to timestamptz without rewriting tables

2017-12-18 Thread Tom Dunstan
On 18 December 2017 at 18:43, Thomas Kellerer wrote: > > All of the timestamps in our system represent an instant in time, not > > a clock date/time, so timestamp with time zone is more appropriate. > > All of the data that is currently on disk in timestamp columns was > > inserted in a db sessio

Re: Converting timestamp to timestamptz without rewriting tables

2017-12-18 Thread Thomas Kellerer
Tom Dunstan schrieb am 18.12.2017 um 09:08: > We have generally been using timestamps without timezones in our > system. As both our app servers and db server were set to UTC it so > far hasn't been an issue. However, that may not always be the case, > so we want to tighten things up a bit. We are

Converting timestamp to timestamptz without rewriting tables

2017-12-18 Thread Tom Dunstan
Hi all We have generally been using timestamps without timezones in our system. As both our app servers and db server were set to UTC it so far hasn't been an issue. However, that may not always be the case, so we want to tighten things up a bit. We are also needing to do things like get the parti