> Am currently writing (or trying to at least) a postgresql driver for
> koffice app kexi.
> The driver requires that i subclass some kexi classes, one being a
> represents a field.
> I know the SQL statement used to generate the result and for each
> result i create an object. However, one property of the object is the
> name for the field. Other properties require that i know the table
> given the table and field names i can query the system catalogs to get
> like contraints.
> In the my_sql c library, the result (tuble) structure contains a filed
> structure that contains the table name that the particular field
> in, but libpq doesnt seem to have any similar kind of functionality
> have looked a lot i think)
> Has anyone any suggestions on how i can achieve getting the table name
> filed in a result without having to parse the sql statement (which i
> think wold be easy).
I very much doubt there is such thing, because the result may come from
a complex join or a function. What does MySQL do when it cames to this?
I have no idea, but am pretty sure that's why there is no similar field
in libpq. And even parsing the query would win you nothing, because of
the reason above.
pgsql-cygwin by date
|Next:||From: Jason Tishler||Date: 2003-07-14 12:04:50|
|Subject: Re: [GENERAL] pg_restore very slow|
|Previous:||From: Roger Ackroyd||Date: 2003-07-14 11:41:19|
|Subject: Problem starting postmaster on Win XP Home|
pgsql-interfaces by date
|Next:||From: Darko Prenosil||Date: 2003-07-14 12:30:20|
|Subject: Re: libpq:Find Table Name|
|Previous:||From: Darko Prenosil||Date: 2003-07-13 19:06:06|
|Subject: Re: libpq:Find Table Name |