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

ecpg preprocessor regression in 9.0

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Michael Meskes <meskes(at)postgresql(dot)org>, Zoltan Boszormenyi <zb(at)cybertec(dot)at>
Cc: PostgreSQL Bugs <pgsql-bugs(at)postgresql(dot)org>
Subject: ecpg preprocessor regression in 9.0
Date: 2010-11-01 13:31:49
Message-ID: 4CCEC145.3020409@enterprisedb.com (view raw or flat)
Thread:
Lists: pgsql-bugs
This used to work in the PostgreSQL 8.4 ecpg preprocessor:

EXEC SQL EXECUTE mystmt USING 1.23;

but in 9.0 it throws an error:

floattest.pgc:39: ERROR: variable "1" is not declared

Attached is the full test case, drop it in 
src/interfaces/ecpg/test/preproc and compile.

I bisected the cause to this commit:

commit b2bddc2ff22f0c3d54671e43c67a2563deed7908
Author: Michael Meskes <meskes(at)postgresql(dot)org>
Date:   Thu Apr 1 08:41:01 2010 +0000

     Applied Zoltan's patch to make ecpg spit out warnings if a local 
variable hides a global one with the same name.

I don't immediately see why that's causing it, but it doesn't seem 
intentional.

-- 
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com

Attachment: floattest.pgc
Description: text/plain (946 bytes)

Responses

pgsql-bugs by date

Next:From: Heikki LinnakangasDate: 2010-11-01 13:47:04
Subject: Re: ecpg preprocessor regression in 9.0
Previous:From: spcheDate: 2010-11-01 10:18:02
Subject: BUG #5738: btree index search bug

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