Re: ANSI Compliant Inserts - Mailing list pgsql-patches

From Michael Loftis
Subject Re: ANSI Compliant Inserts
Date
Msg-id 3CBA82C4.6020504@wgops.com
Whole thread Raw
In response to Re: ANSI Compliant Inserts  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: ANSI Compliant Inserts
List pgsql-patches

Tom Lane wrote:

>
>So far I think everyone agrees that if an explicit column name list is
>given, then it should fail if the column values don't match up.  But
>what do you think about the case with no column name list?
>
I'm on the fence in that situation.  Though I'd lean towards a patch
thats a sort of compromise.  IIF the 'remaining' columns (IE columns
unspecified) have some sort of default or auto-generated value (forgive
me I'm just getting back into workign with postgresql) like a SERIAL or
TIMESTAMP allow it, IFF any of them do not have a default value then
fail.  This will make it 'do the right thing' -- it's not exactly what
the spec does, but it's close to the current behavior that several
others (including myself) see as beneficial in the case of interactive use.

As far as implementation of this sort of compromise, I'm not sure, but
it hsould be possible, assuming the planner knows/flags triggers on
column inserts and can make decisions and reject the query based on that
information (I don't think that information would be in the parser)

>
>
>            regards, tom lane
>



pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: Commands/ directory reorganisation
Next
From: Tatsuo Ishii
Date:
Subject: Re: unknownin/out patch (was [HACKERS] PQescapeBytea is