Re: PL/PgSQL STRICT

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Christopher Browne <cbbrowne(at)gmail(dot)com>
Cc: Marko Tiikkaja <pgmail(at)joh(dot)to>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PL/PgSQL STRICT
Date: 2012-12-21 16:53:30
Message-ID: 18066.1356108810@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Christopher Browne <cbbrowne(at)gmail(dot)com> writes:
> This is adding specific syntax for what seems like an unusual case to me,
> which seems like an unworthwhile complication.

That was my first reaction too, but Marko's followon examples seem to
make a reasonable case for it. There are many situations where you
expect an UPDATE or DELETE to hit exactly one row. Often, programmers
won't bother to add code to check that it did ... but if a one-word
addition to the command can provide such a check, it seems more likely
that they would add the check.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Joe Conway 2012-12-21 16:54:30 Re: Writing Trigger Functions in C
Previous Message Kevin Grittner 2012-12-21 16:51:09 Re: Review of Row Level Security