I have a question.
The question is that the user gives me an access string to the database(oledb
or odbc connection string) and i should be able to check the database connection
and then try to see if a particular table exists . The database can be anything
sqlserver, oracle, sybase etc.Is there a common way to check if the tables
exist for all these databses.
Thanks in advance for ur response.
Aravind
05-02-2001, 04:29 PM
Daryl Shockey
Re: General DB Question
There is a standard query that you can run on any fully SQL-92 compliant DBMS.
This generally includes all high end DBMS's like SQL Server, Oracle, and
Sybase. Let's assume you had a database called "MyDB" and you wanted to
see what tables it has. The query would read: "select TABLE_NAME from MyDB.INFORMATION_SCHEMA.TABLES".
You can also modify the query to order the results and look for specific
tables. Hope this helps...
--> Daryl Shockey
>I have a question.
>The question is that the user gives me an access string to the database
oledb
>or odbc connection string) and i should be able to check the database connection
>and then try to see if a particular table exists . The database can be anything
>sqlserver, oracle, sybase etc.Is there a common way to check if the tables
>exist for all these databses.
>Thanks in advance for ur response.
>
>Aravind