From: | Josh Berkus <josh(at)agliodbs(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [GENERAL] Why extract( ... from timestamp ) is not immutable? |
Date: | 2012-01-30 18:35:21 |
Message-ID: | 4F26E2E9.50802@agliodbs.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general pgsql-hackers |
> preferably I would see extract( epoch from timestamp ) to be really
> immutable, i.e. (in my opinion) it should treat incoming data as UTC
> - for epoch calculation.
> Alternatively - perhaps epoch extraction should be moved to specialized
> function, which would have swapped mutability:
We can't have functions which are immutable or not depending on their
inputs. That way lies madness.
> get_epoch(timestamptz) would be immutable
> while
> get_epoch(timestamp) would be stable
Well, to_epoch, in order to be consistent with other conversion functions.
--
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com
From | Date | Subject | |
---|---|---|---|
Next Message | hubert depesz lubaczewski | 2012-01-30 18:53:51 | Re: [GENERAL] Why extract( ... from timestamp ) is not immutable? |
Previous Message | Josh Berkus | 2012-01-30 18:06:09 | Re: Hot standby off of hot standby? |
From | Date | Subject | |
---|---|---|---|
Next Message | hubert depesz lubaczewski | 2012-01-30 18:53:51 | Re: [GENERAL] Why extract( ... from timestamp ) is not immutable? |
Previous Message | Gilles Darold | 2012-01-30 18:33:53 | Patch pg_is_in_backup() |