pgsql: Fix an old problem in decompilation of CASE constructs: the

From: tgl(at)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix an old problem in decompilation of CASE constructs: the
Date: 2009-02-25 18:00:22
Message-ID: 20090225180022.2305C7559ED@cvs.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Log Message:
-----------
Fix an old problem in decompilation of CASE constructs: the ruleutils.c code
looks for a CaseTestExpr to figure out what the parser did, but it failed to
consider the possibility that an implicit coercion might be inserted above
the CaseTestExpr. This could result in an Assert failure in some cases
(but correct results if Asserts weren't enabled), or an "unexpected CASE WHEN
clause" error in other cases. Per report from Alan Li.

Back-patch to 8.1; problem doesn't exist before that because CASE was
implemented differently.

Tags:
----
REL8_1_STABLE

Modified Files:
--------------
pgsql/src/backend/utils/adt:
ruleutils.c (r1.207.2.9 -> r1.207.2.10)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/ruleutils.c?r1=1.207.2.9&r2=1.207.2.10)

Browse pgsql-committers by date

  From Date Subject
Next Message Fujii Masao 2009-02-25 22:52:48 Re: [COMMITTERS] pgsql: Start background writer during archive recovery.
Previous Message Tom Lane 2009-02-25 18:00:14 pgsql: Fix an old problem in decompilation of CASE constructs: the