Re: Functions used in index definitions shouldn't be changed - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: Functions used in index definitions shouldn't be changed
Date
Msg-id 546FBE05.7070602@BlueTreble.com
Whole thread Raw
In response to Re: Functions used in index definitions shouldn't be changed  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 11/21/14, 9:06 AM, Tom Lane wrote:
> Albe Laurenz <laurenz.albe@wien.gv.at> writes:
>> There is also the possibility to add syntax like this:
>> CREATE OR REPLACE [FORCE] FUNCTION ...
>> What do you think about that?  It would protect the casual user but allow
>> the expert to do it anyway.
>
> I don't see any great attraction to that.

Given what this would do to someone's data, and our general stance on not hurting data, I'm a bit surprised that we
don'twant to do something here. Especially since we did go down this route with disallowing indexes on timestamptz
castedto date, which seriously impacts a lot of reporting scenarios.
 

I fully agree that it's impractical to completely restrict this case, but something akin to FORCE seems reasonable. If
nothingelse, I'd think we should at least issue a warning if someone does something that might affect index viability.
 
-- 
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com



pgsql-hackers by date:

Previous
From: Jim Nasby
Date:
Subject: Re: pg_multixact not getting truncated
Next
From: Kouhei Kaigai
Date:
Subject: Re: [v9.5] Custom Plan API