Re: DatabaseMetaData - Mailing list pgsql-jdbc

From Kris Jurka
Subject Re: DatabaseMetaData
Date
Msg-id Pine.BSO.4.63.0605221814510.9728@leary2.csoft.net
Whole thread Raw
In response to DatabaseMetaData  (Glenn Holmer <gholmer@weycogroup.com>)
Responses Re: DatabaseMetaData  (Glenn Holmer <gholmer@weycogroup.com>)
List pgsql-jdbc

On Mon, 22 May 2006, Glenn Holmer wrote:

> Can someone give me the right incantation to get the names of the
> columns in a table using DatabaseMetaData?  I'm trying
>
> dmd = conn.getMetaData();
> rs = dmd.getColumns("pg_attribute", "public", "tsoldto", null);
>
> (where "tsoldto" is the name of my table) and not getting anything in
> the result set.  What is that last argument supposed to be if I want to
> retrieve all the column names, and are the first two correct?
>

The first argument should be your database name, but this is not actually
causing a problem because that parameter is ignored because pg does not
support cross database calls.  Other than that it looks good.  Are you
sure it's in the public schema?  Are you sure it wasn't created with a
case sensitive table name "tSoldTo" or something?

Kris Jurka

pgsql-jdbc by date:

Previous
From: Glenn Holmer
Date:
Subject: DatabaseMetaData
Next
From: Jagadish Prasath Ramu
Date:
Subject: Re: [BUGS] BUG #2444: XA Connections given by posgres driver has