Re: ambiguous column names in subqueries

From: Greg Stark <gsstark(at)mit(dot)edu>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: ambiguous column names in subqueries
Date: 2004-11-17 22:09:22
Message-ID: 87u0ro3z71.fsf@stark.xeocode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Oliver Jowett <oliver(at)opencloud(dot)com> writes:

> Please don't. JDBC (for example) has no problem with ambiguous columns, you
> just access them by index, and you have resultset metadata available if you
> want to implement your own rules for finding those indexes. It sounds like your
> problem really lies in the API you are using to access the results.

The API with the problem is the SQL language. It's there that the columns
become inaccessible. It seems silly for the language to let you create
variables that you can't reference.

Yes it's true that you could access them from the result set but that's even
worse. You have variables that you can't access from within the language but
that can escape to the outside world to cause real effects.

--
greg

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message John Hansen 2004-11-17 22:12:48 Re: [HACKERS] split_part bug
Previous Message Tom Lane 2004-11-17 21:58:27 Re: [HACKERS] split_part bug