From: David Fetter <david@fetter.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Nico Williams <nico@cryptonector.com>
Cc: Adam Brusselback <adambrusselback@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: generated columns
Date: Mon, 2 Oct 2017 20:36:41 +0200
Message-ID: <20171002183641.GE1246@fetter.org> (raw)
In-Reply-To: <10550.1506969038@sss.pgh.pa.us>
References: <b151f851-4019-bdb1-699e-ebab07d2f40a@2ndquadrant.com>
<20171002152338.GH1251@localhost>
<CAMjNa7fhskTTMSLMUL=e1r-EOg2Q3-cSayEDB1MADmX_zzn1gw@mail.gmail.com>
<20171002181042.GI1251@localhost>
<10550.1506969038@sss.pgh.pa.us>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
On Mon, Oct 02, 2017 at 02:30:38PM -0400, Tom Lane wrote:
> Nico Williams <nico@cryptonector.com> writes:
> > On Mon, Oct 02, 2017 at 12:50:14PM -0400, Adam Brusselback wrote:
> >> So for me, i'd rather default to compute on read, as long storing the
> >> pre-computed value is an option when necessary.
>
> > Sure, I agree. I was just wondering whether there might be any other
> > difference besides performance characteristics. The answer to that is,
> > I think, "no".
>
> What about non-immutable functions in the generation expression?
Assuming they're permitted, which...well, I could make a case, they
should be mutually exclusive with the cached option.
I guess documenting the behavior in the manual would suffice, tempting
as it would be to include a NOTICE when the table goes from having 0
or more generated columns all of which are immutable to having at
least one that's not.
Best,
David.
--
David Fetter <david(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)com
Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
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-hackers@postgresql.org
Cc: david@fetter.org, tgl@sss.pgh.pa.us, nico@cryptonector.com, adambrusselback@gmail.com
Subject: Re: generated columns
In-Reply-To: <20171002183641.GE1246@fetter.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox