Re: [HACKERS] Request for qualified column names

2003-01-30 Thread Bruce Momjian
Peter Eisentraut wrote: > Dave Cramer writes: > > > The method in question is > > ResultSetMetaDate.getTableName(int column) > > and while were at it > > ResultSetMetaData.getSchemaName(int column) > > and FWIW, the return value if not applicable is "" > > Not applicable sounds fine to me. It's

Re: [HACKERS] Request for qualified column names

2003-01-29 Thread Peter Eisentraut
Dave Cramer writes: > The method in question is > ResultSetMetaDate.getTableName(int column) > and while were at it > ResultSetMetaData.getSchemaName(int column) > and FWIW, the return value if not applicable is "" Not applicable sounds fine to me. It's like taking a file descriptor and asking w

Re: [HACKERS] Request for qualified column names

2003-01-29 Thread Reggie Burnett
someone requests it. Reggie > -Original Message- > From: Neil Conway [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 28, 2003 11:47 PM > To: Reggie Burnett > Cc: 'Tom Lane'; 'Dave Cramer'; 'PostgreSQL Hackers Mailing List' > Subject: Re: [

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Neil Conway
On Mon, 2003-01-27 at 10:44, Reggie Burnett wrote: > Well, certainly the driver could parse the sql and extract what it > thinks is the table name. It just seems quite foreign to me to have a > database engine go through the motions of determining column location > and have ready access to all the

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Dave Cramer
The method in question is ResultSetMetaDate.getTableName(int column) and while were at it ResultSetMetaData.getSchemaName(int column) and FWIW, the return value if not applicable is "" Dave On Tue, 2003-01-28 at 17:21, Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > Dave Cramer

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Dave Cramer says it is needed for the jdbc spec, somehow. Does the JDBC spec really require the database to provide functionality that's not in the SQL spec? I kinda doubt that. regards, tom lane ---(end

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Reggie Burnett
Original Message- > From: Bruce Momjian [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 28, 2003 4:01 PM > To: Peter Eisentraut > Cc: Tom Lane; Reggie Burnett; 'Dave Cramer'; 'PostgreSQL Hackers Mailing > List' > Subject: Re: [HACKERS] Request for qualifi

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Reggie Burnett
aut [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, January 28, 2003 3:59 PM > To: Bruce Momjian > Cc: Tom Lane; Reggie Burnett; 'Dave Cramer'; 'PostgreSQL Hackers Mailing > List' > Subject: Re: [HACKERS] Request for qualified column names > > Bruce Momjian writes

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Peter Eisentraut
Bruce Momjian writes: > My idea on this after chat with Dave was to add a GUC option that puts > the schema.table.column name as the default column label, rather than > just the column name. Can someone explain why this is needed at all? There is a reason why the SQL standard does not provide fo

Re: [HACKERS] Request for qualified column names

2003-01-28 Thread Bruce Momjian
Dave Cramer says it is needed for the jdbc spec, somehow. It seems kind of odd so I don't want to make too complex an implementation. --- Peter Eisentraut wrote: > Bruce Momjian writes: > > > My idea on this after chat with

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Rod Taylor
On Mon, 2003-01-27 at 15:50, Larry Rosenman wrote: > --On Monday, January 27, 2003 15:49:06 -0500 Bruce Momjian > <[EMAIL PROTECTED]> wrote: > > > > > My idea on this after chat with Dave was to add a GUC option that puts > > the schema.table.column name as the default column label, rather than >

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > My idea on this after chat with Dave was to add a GUC option that puts > > the schema.table.column name as the default column label, rather than > > just the column name. > > And will you quotify things so that names containing dots,

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Bruce Momjian
Larry Rosenman wrote: > > > --On Monday, January 27, 2003 15:49:06 -0500 Bruce Momjian > <[EMAIL PROTECTED]> wrote: > > > > > My idea on this after chat with Dave was to add a GUC option that puts > > the schema.table.column name as the default column label, rather than > > just the column name

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > My idea on this after chat with Dave was to add a GUC option that puts > the schema.table.column name as the default column label, rather than > just the column name. And will you quotify things so that names containing dots, spaces, etc are unambiguous?

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Larry Rosenman
--On Monday, January 27, 2003 15:49:06 -0500 Bruce Momjian <[EMAIL PROTECTED]> wrote: My idea on this after chat with Dave was to add a GUC option that puts the schema.table.column name as the default column label, rather than just the column name. (That's so easy, I think even I could do it.

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Bruce Momjian
My idea on this after chat with Dave was to add a GUC option that puts the schema.table.column name as the default column label, rather than just the column name. (That's so easy, I think even I could do it.) If they over-ride it with AS, or if it is an aggregate or FROM subquery, we just return

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Reggie Burnett
1 AM > To: Reggie Burnett > Cc: 'Dave Cramer'; 'PostgreSQL Hackers Mailing List' > Subject: Re: [HACKERS] Request for qualified column names > > "Reggie Burnett" <[EMAIL PROTECTED]> writes: > > When talking about expressions,views, or any other

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Tom Lane
"Reggie Burnett" <[EMAIL PROTECTED]> writes: > When talking about expressions,views, or any other construct that could > combine values from multiple tables I think it is reasonable to provide > null as the table name. Any one or any process requesting the table > name has to understand that not a

Re: [HACKERS] Request for qualified column names

2003-01-27 Thread Reggie Burnett
gt; Cc: PostgreSQL Hackers Mailing List > Subject: Re: [HACKERS] Request for qualified column names > > Dave Cramer <[EMAIL PROTECTED]> writes: > > So for a "select a, b, a+b as sum from c" returns c.a, c.b, ?table?.sum > > This might be something to consider as par

Re: [HACKERS] Request for qualified column names

2003-01-26 Thread Tom Lane
Dave Cramer <[EMAIL PROTECTED]> writes: > So for a "select a, b, a+b as sum from c" returns c.a, c.b, ?table?.sum This might be something to consider as part of the planned protocol overhaul. We cannot simply change the returned column names --- at least not without breaking a lot of application