Re: Wrong column names in ResultSetMetaData

Поиск
Список
Период
Сортировка
От Kris Jurka
Тема Re: Wrong column names in ResultSetMetaData
Дата
Msg-id Pine.BSO.4.56.0408041433030.7043@leary.csoft.net
обсуждение исходный текст
Ответ на Re: Wrong column names in ResultSetMetaData  ("Mike Martin" <mmartin@vieo.com>)
Список pgsql-jdbc

On Tue, 3 Aug 2004, Mike Martin wrote:

> SELECT * FROM person inner join person parent on person.parent_id =
> parent.id
>
> rs.getTableName() distinguishes person.name from parent.name.
>
> In my experience, drivers correctly implement getTableName()
> *far* less frequently.  I've never been able to rely on it.
>
> Of the drivers I have handy, only DB2J and MySQL get it right.
> Cloudscape, Firebird, hsqldb, mssqlserver, and pg75 all return
> the underlying base table name.  JTDS, Oracle, and pg74 all
> return empty strings!
>

You seem surprised that it would return an empty string, while that was
what I was planning on making it do.  Why should it return the base table
name when it can't determine if it has been aliased?  Isn't this returning
incorrect information?

Kris Jurka

В списке pgsql-jdbc по дате отправления:

Предыдущее
От: smota
Дата:
Сообщение: Re: JDBC Latin1 problem
Следующее
От: "J. Michael Crawford"
Дата:
Сообщение: Re: JDBC Latin1 problem