PC Review Forums Newsgroups Microsoft DotNet Microsoft ADO .NET Retrieving Schema info for connection

Reply

Retrieving Schema info for connection

 
Thread Tools Rate Thread
Old 27-12-2006, 05:21 AM   #1
Terry Olsen
Guest
 
Posts: n/a
Default Retrieving Schema info for connection


I'm building a program to navigate through a database. The user chooses
either ODBC or OleDb and provides a connection string. With OleDb I can get
the database names from the connection. Is there a way I can do this with an
ODBC connection? Programs like DTM Data Editor can do it. But there doesn't
seem to be a way in .NET 2.0.

Or can I get enough information from the ODBC connection to create an OleDb
connection?

Is there a way to get database names from an ODBC connection?


  Reply With Quote
Old 27-12-2006, 02:40 PM   #2
krishnen
Guest
 
Posts: n/a
Default Re: Retrieving Schema info for connection

Terry,

You can know the database name from the OdbcConnection object itself
from the property Database

Krishnen

Terry Olsen wrote:
> I'm building a program to navigate through a database. The user chooses
> either ODBC or OleDb and provides a connection string. With OleDb I can get
> the database names from the connection. Is there a way I can do this with an
> ODBC connection? Programs like DTM Data Editor can do it. But there doesn't
> seem to be a way in .NET 2.0.
>
> Or can I get enough information from the ODBC connection to create an OleDb
> connection?
>
> Is there a way to get database names from an ODBC connection?


  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off