Re: Support for DatabaseMetadata: getCatalogName, getTableName,
От | Ken Johanson |
---|---|
Тема | Re: Support for DatabaseMetadata: getCatalogName, getTableName, |
Дата | |
Msg-id | 459D6CEC.9040505@kensystem.com обсуждение исходный текст |
Ответ на | Re: Support for DatabaseMetadata: getCatalogName, getTableName, (Kris Jurka <books@ejurka.com>) |
Ответы |
Re: Support for DatabaseMetadata: getCatalogName, getTableName,
|
Список | pgsql-jdbc |
Kris Jurka wrote: > > > On Thu, 4 Jan 2007, Ken Johanson wrote: > >> These will be in the java.sql.ResultSetMetaData interface's >> implementation? Or would I need to obtain a PGResultSetMetaData (which >> doesn't seem to extend RSMD; does a facade RSMD impl class wrap >> PGResultSetMetaData?)? >> > > ResultSet rs = Statement.executeQuery("SELECT a, b FROM tab"); > ResultSetMetaData rsmd = rs.getMetaData(); > org.postgresql.PGResultSetMetaData pgrsmd = > (org.postgresql.PGResultSetMetaData)rsmd; > for (int i=1; i<=rsmd.getColumnCount(); i++) { > System.out.println(pgrsmd.getBaseTableName(i)); > } > > Kris Jurka > > Kris, I'm sorry, I meant, will I be able to get the table name via ResultSetMetaData.getTableName(int). The app I'm using internally depends on standard interfaces at its core and unfortunately I don't have the ability (nor desire really) to add in impl-specific code. I guess I am not fully understanding why getTableName isn't just being populated with PGResultSetMetaData.getBaseTableName() in the first place; if so please feel welcome to hit me over the head with the cold hard truth ;-) Thank you again, Ken
В списке pgsql-jdbc по дате отправления: