PoC: Make it possible to disallow WHERE-less UPDATE and DELETE - Mailing list pgsql-hackers

From David Fetter
Subject PoC: Make it possible to disallow WHERE-less UPDATE and DELETE
Date
Msg-id 20160721045746.GA25043@fetter.org
Whole thread Raw
Responses Re: PoC: Make it possible to disallow WHERE-less UPDATE and DELETE  (Amit Kapila <amit.kapila16@gmail.com>)
Re: PoC: Make it possible to disallow WHERE-less UPDATE and DELETE  (Jim Mlodgenski <jimmy76@gmail.com>)
Re: PoC: Make it possible to disallow WHERE-less UPDATE and DELETE  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: PoC: Make it possible to disallow WHERE-less UPDATE and DELETE  (Teodor Sigaev <teodor@sigaev.ru>)
Re: PoC: Make it possible to disallow WHERE-less UPDATE and DELETE  (Vik Fearing <vik@2ndquadrant.fr>)
Re: [HACKERS] PoC: Make it possible to disallow WHERE-less UPDATE and DELETE  (Pavel Stehule <pavel.stehule@gmail.com>)
List pgsql-hackers
Folks,

Please find attached a patch which makes it possible to disallow
UPDATEs and DELETEs which lack a WHERE clause.  As this changes query
behavior, I've made the new GUCs PGC_SUSET.

What say?

Thanks to Gurjeet Singh for the idea and Andrew Gierth for the tips
implementing.

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

Attachment

pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: DROP OWNED BY ... CACADE & "could not open relation with OID" error
Next
From: Satoshi Nagayasu
Date:
Subject: Re: DROP OWNED BY ... CACADE & "could not open relation with OID" error