diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2007-10-29 19:40:40 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2007-10-29 19:40:40 +0000 |
commit | b17b7fae8c1418f924915348afaa2250d1360bc4 (patch) | |
tree | de530f59c165dc2a578adbafc5af4dedca94e78f /src/tutorial/advanced.source | |
parent | bf5ccf382c606b09e17dbcefc101d62417c4db33 (diff) |
Remove the hack in the grammar that "optimized away" DEFAULT NULL clauses.
Instead put in a test to drop a NULL default at the last moment before
storing the catalog entry. This changes the behavior in a couple of ways:
* Specifying DEFAULT NULL when creating an inheritance child table will
successfully suppress inheritance of any default expression from the
parent's column, where formerly it failed to do so.
* Specifying DEFAULT NULL for a column of a domain type will correctly
override any default belonging to the domain; likewise for a sub-domain.
The latter change happens because by the time the clause is checked,
it won't be a simple null Const but a CoerceToDomain expression.
Personally I think this should be back-patched, but there doesn't seem to
be consensus for that on pgsql-hackers, so refraining.
Diffstat (limited to 'src/tutorial/advanced.source')
0 files changed, 0 insertions, 0 deletions