Browsing database structure

R

R_O_O_K

Hi!

I need to view the structure of a DBMS (ie what databases does it
contain and what is their structure). ADOX takes care of that in OleDb,
but what tool should I use with MSSQL, Postgres or any other?

Regards!
Michal Ziemski
 
B

Bob Beauchemin

If you are using the OleDb data provider for .NET, you can use
OleDbConnection.GetOleDbSchemaTable.

If you are using database-specific data providers, the closest you can come
is to use ordinary SELECT statements against the SQL92/99 standard
INFORMATION SCHEMA views. If you are using database-specific data providers
and your database doesn't support the INFORMATION SCHEMA views, you'll need
to use the database-specific metadata tables.

Interestingly ODBC exposes the equivalent of the OLE DB schema tables
(SQLTable) but the Odbc data provider doesn't support it.

Hope this helps,
Bob Beauchemin
http://staff.develop.com/bobb
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top