Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 159
  • Last Modified:

Finding the list of available databases and tables in a database

Does anyone have some code on how to get a list of available databases and then a list of the available tables in each database?
0
phillip1
Asked:
phillip1
1 Solution
 
NetoManCommented:
what kind of databases are you using (Oracle / MSAcces / SQLServer ) ?


0
 
DrDelphiCommented:
You mean other than Database Explorer?
0
 
EpsylonCommented:
Use a TSession component:

  Session1.SessionName := 'somename';
  Session1.GetAliasNames(ListBox1.Items);
  Session1.GetTableNames('DBDEMOS', '*.db',False, False, ListBox2.Items);


Cheers,

Epsylon.
0
 
phillip1Author Commented:
Works perfectly.  You're a genius.  Thanks,
Phil
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now