Change syntax of new CHECK NO INHERIT constraints
Alvaro Herrera <alvherre@alvh.no-ip.org>
Change syntax of new CHECK NO INHERIT constraints The initially implemented syntax, "CHECK NO INHERIT (expr)" was not deemed very good, so switch to "CHECK (expr) NO INHERIT" instead. This way it looks similar to SQL-standards compliant constraint attribute. Backport to 9.2 where the new syntax and feature was introduced. Per discussion.
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/ref/alter_table.sgml | modified | +2 −2 |
| doc/src/sgml/ref/create_table.sgml | modified | +3 −3 |
| doc/src/sgml/release-9.2.sgml | modified | +1 −1 |
| src/backend/commands/typecmds.c | modified | +7 −1 |
| src/backend/parser/gram.y | modified | +36 −22 |
| src/backend/utils/adt/ruleutils.c | modified | +3 −4 |
| src/test/regress/expected/alter_table.out | modified | +5 −5 |
| src/test/regress/expected/inherit.out | modified | +2 −2 |
| src/test/regress/input/constraints.source | modified | +2 −2 |
| src/test/regress/output/constraints.source | modified | +2 −2 |
| src/test/regress/sql/alter_table.sql | modified | +3 −3 |
| src/test/regress/sql/inherit.sql | modified | +1 −1 |