Re: How to discern a reference column from within java??

From: "David A(dot) Bartmess" <dingodave(at)edingo(dot)net>
To: "Dave Cramer" <Dave(at)micro-automation(dot)net>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: How to discern a reference column from within java??
Date: 2002-06-10 04:06:55
Message-ID: 1023682015.2452.0.camel@Dingo.home
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Thanks, I'll check it out!

On Sun, 2002-06-09 at 21:18, Dave Cramer wrote:
> David,
>
> Have a look at the getImported, getExported in the databasemetadata
> class
>
> Dave
> On Sun, 2002-06-09 at 13:51, David A. Bartmess wrote:
> >
> > I am trying to figure out how to discern a reference column (as shown
> > below) inside a java object containing the various columns in a specific
> > row of a table.
> >
> > The table looks like:
> >
> > CREATE TABLE TempTbl AS
> > (
> > id serial,
> > type int references TypesTbl
> > );
> >
> > But I cannot find a way inside the jdbc API to figure out if a
> > particular column is a reference to another table's row. Such as:
> >
> > // These are examples of possible code
> > TempTbl tmptbl = new TempTbl();
> > tmptbl.connect();
> > tmptbl.readRow();
> >
> > ...
> > if (tmptbl.getColumn("type").isReference())
> > {
> > TypesTbl typestbl = new TypesTbl();
> > tmptbl.setColumn("type",
> > typestbl.getRowRef(tmptbl.getColumn("type"));
> > }
> >
> > Am I missing something in the API?
> >
> > Thanks for any help!
> > --
> > David A. Bartmess
> > Software Configuration Manager / Sr. Software Developer
> > eDingo Enterprises
> > http://edingo.net
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 3: if posting/reading through Usenet, please send an appropriate
> > subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> > message can get through to the mailing list cleanly
> >
> >
>
>
>
>
--
David A. Bartmess
Software Configuration Manager / Sr. Software Developer
eDingo Enterprises
http://edingo.net

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Daniel Stern 2002-06-10 09:08:28 JDBC compliance
Previous Message Dave Cramer 2002-06-10 03:18:07 Re: How to discern a reference column from within java??