On Fri, Dec 21, 2012 at 10:39 AM, Tom Lane <t...@sss.pgh.pa.us> wrote: > > Marko Tiikkaja <pgm...@joh.to> writes: > > Courtesy of me, Christmas comes a bit early this year. I wrote a patch > > which allows you to add STRICT into PERFORM and INSERT/UPDATE/DELETE > > without specifying an INTO clause. > > What is the use-case for this? Won't this result in the word STRICT > becoming effectively reserved in contexts where it currently is not? > (IOW, even if the feature is useful, I've got considerable doubts about > this syntax for it. The INTO clause is an ugly, badly designed kluge > already --- let's not make another one just like it.)
Yep, the use case for this seems mighty narrow to me. I could use GET DIAGNOSTICS to determine if nothing got altered, and it seems likely to me that expressly doing this via IF/ELSE/END IF would be easier to read in function code than a somewhat magic STRICT side-effect. I certainly appreciate that brevity can make things more readable, it's just that I'm not sure that is much of a help here. This is adding specific syntax for what seems like an unusual case to me, which seems like an unworthwhile complication. -- When confronted by a difficult problem, solve it by reducing it to the question, "How would the Lone Ranger handle this?"