About wxODBC

From: Quan Zongliang <quanzongliang(at)gmail(dot)com>
To: pgadmin-hackers(at)postgresql(dot)org(dot)
Subject: About wxODBC
Date: 2009-02-17 10:22:55
Message-ID: 20090217181024.7EEF.4125B4E5@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hi, all

The class wxDb has a method: GetCatalog(const wxChar *userID)
We can use it to retrieve tables' info.

But, this method return a pointer to wxDbInf.
The class wxDbInf has some fields:
wxChar catalog[128+1];
wxChar schema[128+1]; // typically means owner of table(s)
int numTables; // How many tables does this datasource have
wxDbTableInf *pTableInf; // Equals a new wxDbTableInf[numTables];

The problem is that the schema field looks wrong.
When there are multiple schemas in corresponding database,
it is the first one's name(alphabetic).
And the class wxDbTableInf don't include schema-name.

Do you know how to get full table list and their schema?
I had tried some wxWidgets methods, did not found.

If it can't, we have to let user input a SQL statement manually.

And under MS-Windows, we can use ODBC API: SQLTables method to do this.

Thanks.

-----------------------------------------------
Quan Zongliang
quanzongliang(at)gmail(dot)com
CIT Japan: http://www.cit.co.jp
CIT China: http://www.citbj.com.cn

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Ashesh Vashi 2009-02-18 07:45:46 PATCH: Update autovacuum to use reloptions, instead of a system catalog
Previous Message Guillaume Lelarge 2009-02-17 08:47:57 Re: Feature freeze for 1.10