Skip site navigation (1) Skip section navigation (2)

pgsql: Add a "USING" clause to DELETE, which is equivalent to the FROM

From: neilc(at)svr1(dot)postgresql(dot)org (Neil Conway)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Add a "USING" clause to DELETE, which is equivalent to the FROM
Date: 2005-04-07 01:51:42
Message-ID: 20050407015142.1D7D9535A7@svr1.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-committers
Log Message:
-----------
Add a "USING" clause to DELETE, which is equivalent to the FROM clause
in UPDATE. We also now issue a NOTICE if a query has _any_ implicit
range table entries -- in the past, we would only warn about implicit
RTEs in SELECTs with at least one explicit RTE.

As a result of the warning change, 25 of the regression tests had to
be updated. I also took the opportunity to remove some bogus whitespace
differences between some of the float4 and float8 variants. I believe
I have correctly updated all the platform-specific variants, but let
me know if that's not the case.

Original patch for DELETE ... USING from Euler Taveira de Oliveira,
reworked by Neil Conway.

Modified Files:
--------------
    pgsql/doc/src/sgml/ref:
        delete.sgml (r1.22 -> r1.23)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/doc/src/sgml/ref/delete.sgml.diff?r1=1.22&r2=1.23)
    pgsql/src/backend/nodes:
        copyfuncs.c (r1.300 -> r1.301)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/nodes/copyfuncs.c.diff?r1=1.300&r2=1.301)
        equalfuncs.c (r1.239 -> r1.240)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/nodes/equalfuncs.c.diff?r1=1.239&r2=1.240)
    pgsql/src/backend/parser:
        analyze.c (r1.317 -> r1.318)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/parser/analyze.c.diff?r1=1.317&r2=1.318)
        gram.y (r2.486 -> r2.487)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/parser/gram.y.diff?r1=2.486&r2=2.487)
        parse_relation.c (r1.104 -> r1.105)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/parser/parse_relation.c.diff?r1=1.104&r2=1.105)
    pgsql/src/backend/utils/adt:
        ruleutils.c (r1.190 -> r1.191)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/ruleutils.c.diff?r1=1.190&r2=1.191)
    pgsql/src/bin/psql:
        tab-complete.c (r1.123 -> r1.124)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/tab-complete.c.diff?r1=1.123&r2=1.124)
    pgsql/src/include/nodes:
        parsenodes.h (r1.276 -> r1.277)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/nodes/parsenodes.h.diff?r1=1.276&r2=1.277)
    pgsql/src/test/regress/expected:
        abstime.out (r1.15 -> r1.16)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/abstime.out.diff?r1=1.15&r2=1.16)
        boolean.out (r1.11 -> r1.12)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/boolean.out.diff?r1=1.11&r2=1.12)
        box.out (r1.9 -> r1.10)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/box.out.diff?r1=1.9&r2=1.10)
        char.out (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/char.out.diff?r1=1.6&r2=1.7)
        char_1.out (r1.1 -> r1.2)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/char_1.out.diff?r1=1.1&r2=1.2)
        create_misc.out (r1.19 -> r1.20)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/create_misc.out.diff?r1=1.19&r2=1.20)
        create_view.out (r1.9 -> r1.10)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/create_view.out.diff?r1=1.9&r2=1.10)
        float4-exp-three-digits.out (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float4-exp-three-digits.out.diff?r1=1.6&r2=1.7)
        float4.out (r1.12 -> r1.13)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float4.out.diff?r1=1.12&r2=1.13)
        float8-exp-three-digits-win32.out (r1.5 -> r1.6)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float8-exp-three-digits-win32.out.diff?r1=1.5&r2=1.6)
        float8-exp-three-digits.out (r1.10 -> r1.11)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float8-exp-three-digits.out.diff?r1=1.10&r2=1.11)
        float8-small-is-zero.out (r1.8 -> r1.9)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float8-small-is-zero.out.diff?r1=1.8&r2=1.9)
        float8-small-is-zero_1.out (r1.2 -> r1.3)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float8-small-is-zero_1.out.diff?r1=1.2&r2=1.3)
        float8.out (r1.22 -> r1.23)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/float8.out.diff?r1=1.22&r2=1.23)
        hash_index.out (r1.5 -> r1.6)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/hash_index.out.diff?r1=1.5&r2=1.6)
        horology.out (r1.52 -> r1.53)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/horology.out.diff?r1=1.52&r2=1.53)
        int2.out (r1.12 -> r1.13)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/int2.out.diff?r1=1.12&r2=1.13)
        int4.out (r1.14 -> r1.15)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/int4.out.diff?r1=1.14&r2=1.15)
        interval.out (r1.9 -> r1.10)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/interval.out.diff?r1=1.9&r2=1.10)
        join.out (r1.23 -> r1.24)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/join.out.diff?r1=1.23&r2=1.24)
        join_1.out (r1.3 -> r1.4)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/join_1.out.diff?r1=1.3&r2=1.4)
        name.out (r1.8 -> r1.9)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/name.out.diff?r1=1.8&r2=1.9)
        oid.out (r1.11 -> r1.12)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/oid.out.diff?r1=1.11&r2=1.12)
        point.out (r1.13 -> r1.14)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/point.out.diff?r1=1.13&r2=1.14)
        polygon.out (r1.10 -> r1.11)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/polygon.out.diff?r1=1.10&r2=1.11)
        privileges.out (r1.28 -> r1.29)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/privileges.out.diff?r1=1.28&r2=1.29)
        reltime.out (r1.8 -> r1.9)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/reltime.out.diff?r1=1.8&r2=1.9)
        rules.out (r1.97 -> r1.98)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/rules.out.diff?r1=1.97&r2=1.98)
        select.out (r1.12 -> r1.13)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/select.out.diff?r1=1.12&r2=1.13)
        tinterval.out (r1.11 -> r1.12)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/tinterval.out.diff?r1=1.11&r2=1.12)
        transactions.out (r1.11 -> r1.12)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/transactions.out.diff?r1=1.11&r2=1.12)
        varchar.out (r1.3 -> r1.4)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/varchar.out.diff?r1=1.3&r2=1.4)
        varchar_1.out (r1.1 -> r1.2)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/expected/varchar_1.out.diff?r1=1.1&r2=1.2)
    pgsql/src/test/regress/input:
        misc.source (r1.20 -> r1.21)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/input/misc.source.diff?r1=1.20&r2=1.21)
    pgsql/src/test/regress/sql:
        abstime.sql (r1.8 -> r1.9)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/abstime.sql.diff?r1=1.8&r2=1.9)
        boolean.sql (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/boolean.sql.diff?r1=1.6&r2=1.7)
        box.sql (r1.5 -> r1.6)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/box.sql.diff?r1=1.5&r2=1.6)
        char.sql (r1.5 -> r1.6)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/char.sql.diff?r1=1.5&r2=1.6)
        create_misc.sql (r1.13 -> r1.14)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/create_misc.sql.diff?r1=1.13&r2=1.14)
        create_view.sql (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/create_view.sql.diff?r1=1.6&r2=1.7)
        float4.sql (r1.7 -> r1.8)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/float4.sql.diff?r1=1.7&r2=1.8)
        float8.sql (r1.13 -> r1.14)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/float8.sql.diff?r1=1.13&r2=1.14)
        hash_index.sql (r1.5 -> r1.6)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/hash_index.sql.diff?r1=1.5&r2=1.6)
        horology.sql (r1.29 -> r1.30)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/horology.sql.diff?r1=1.29&r2=1.30)
        int2.sql (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/int2.sql.diff?r1=1.6&r2=1.7)
        int4.sql (r1.8 -> r1.9)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/int4.sql.diff?r1=1.8&r2=1.9)
        interval.sql (r1.5 -> r1.6)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/interval.sql.diff?r1=1.5&r2=1.6)
        join.sql (r1.15 -> r1.16)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/join.sql.diff?r1=1.15&r2=1.16)
        name.sql (r1.7 -> r1.8)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/name.sql.diff?r1=1.7&r2=1.8)
        oid.sql (r1.7 -> r1.8)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/oid.sql.diff?r1=1.7&r2=1.8)
        point.sql (r1.9 -> r1.10)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/point.sql.diff?r1=1.9&r2=1.10)
        polygon.sql (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/polygon.sql.diff?r1=1.6&r2=1.7)
        privileges.sql (r1.13 -> r1.14)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/privileges.sql.diff?r1=1.13&r2=1.14)
        reltime.sql (r1.4 -> r1.5)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/reltime.sql.diff?r1=1.4&r2=1.5)
        rules.sql (r1.31 -> r1.32)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/rules.sql.diff?r1=1.31&r2=1.32)
        select.sql (r1.8 -> r1.9)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/select.sql.diff?r1=1.8&r2=1.9)
        tinterval.sql (r1.6 -> r1.7)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/tinterval.sql.diff?r1=1.6&r2=1.7)
        transactions.sql (r1.11 -> r1.12)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/transactions.sql.diff?r1=1.11&r2=1.12)
        varchar.sql (r1.3 -> r1.4)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql/src/test/regress/sql/varchar.sql.diff?r1=1.3&r2=1.4)

Responses

pgsql-committers by date

Next:From: Neil ConwayDate: 2005-04-07 03:29:02
Subject: pgsql: Fix minor breakage to regression tests induced in previous commit
Previous:From: Neil ConwayDate: 2005-04-06 23:56:07
Subject: pgsql: Apply the "nodeAgg" optimization to more of the builtin

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group