pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: dmp <danap@ttc-cmc.net>
To: goran.popov@prokomsoft.rs
To: pgsql-jdbc@postgresql.org
Subject: Re: TableName
Date: Tue, 30 Oct 2012 09:07:34 -0600
Message-ID: <508FED36.6000106@ttc-cmc.net> (raw)
In-Reply-To: <508F9F46.1020800@prokomsoft.rs>
References: <508EA11A.7080104@prokomsoft.rs>
	<508EAD22.3030602@ttc-cmc.net>
	<508F9F46.1020800@prokomsoft.rs>

 >> Goran Popov wrote:
 >>> AbstractJdbc2ResultSetMetaData.java
 >>>
 >>>
 >>> Whay this is default
 >>> public String getTableName(int column) throws SQLException
 >>> {
 >>> return "";
 >>> }
 >>>
 >>> and not this
 >>> public String getTableName(int column) throws SQLException
 >>> {
 >>> return getBaseTableName(column);
 >>> }
> On 10/29/2012 05:21 PM, dmp wrote:
>> Looks like perhasp because it is not applicable for a resultSet.
>> As per the the Java™ Platform, Standard Edition 6 API Specification.
>>
>> Interface ResultSetMetaData
>>
>> String getTableName(int column)
>> throws SQLException
>>
>> Gets the designated column's table name.
>>
>> Parameters:
>> column - the first column is 1, the second is 2, ...
>> Returns:
>> table name or "" if not applicable
>> Throws:
>> SQLException - if a database access error occurs
>>
>> Consider SELECT(1*2) resultSet.
>> Does that have a table name?
>>
>> danap.
>>
Goran Popov wrote:
>>
>>
> No and that shoud be empty "". But when there is table name than should
> be table name.

I agree and later upon reflection knew that the reason for not
returning the table name as such was more complicated as Kris
has provided hindsight to. When I first came to this forum I
read for insight and occasionally responded when I thought I
could contribute. Sometimes I also asked questions like yours
in order to point out perceived inconsistencies in the drivers
behavior. Later I found out that just as Rome was not build in
a day, but over years with many contributing no matter how modest.

danap.




view thread (4+ messages)

Message-ID: <508FED36.6000106@ttc-cmc.net>
Permalink:  ../508FED36.6000106@ttc-cmc.net/
Also on:    postgresql.org/message-id/508FED36.6000106@ttc-cmc.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: danap@ttc-cmc.net, goran.popov@prokomsoft.rs
  Subject: Re: TableName
  In-Reply-To: <508FED36.6000106@ttc-cmc.net>
  References: <508EA11A.7080104@prokomsoft.rs> <508EAD22.3030602@ttc-cmc.net> <508F9F46.1020800@prokomsoft.rs> <508FED36.6000106@ttc-cmc.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox