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

Assertion failure due to ColumnRefStar

From: NikhilS <nikkhils(at)gmail(dot)com>
To: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Assertion failure due to ColumnRefStar
Date: 2007-09-27 14:12:06
Message-ID: d3c4af540709270712m150d7e61i119d7a28c2932bc2@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackers
Hi,

One of our qmg folks reported an assertion failure:

create table x(y char(1));
insert into x  values ("*");

The above causes the following assertion to be hit:

        /*
         * Target item is a bare '*', expand all tables
         *
         * (e.g., SELECT * FROM emp, dept)
         *
         * Since the grammar only accepts bare '*' at top level of SELECT,
we
         * need not handle the targetlist==false case here.
         */
        Assert(targetlist);

in ExpandColumnRefStar() function.

I was wondering if we should fix this by checking for
list_length(cref->fields) being greater than 1 before calling this in
transformExpressionList?

Regards,
Nikhils
-- 
EnterpriseDB               http://www.enterprisedb.com

Responses

pgsql-hackers by date

Next:From: Kevin GrittnerDate: 2007-09-27 14:13:02
Subject: Re: [FEATURE REQUEST] Streaming Onlinebackup(MaybeOFFTOPIC)
Previous:From: Tom LaneDate: 2007-09-27 14:08:32
Subject: Re: [COMMITTERS] pgsql: Temporarily modify tsearch regression tests to suppress notice

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