Retrieve the metadata of View dependents of sql server

G

Guest

Hi
i am using the GetOledbSchemaTable method of connection to retrieve the
schema
of view and it dependent tables.
I used OledbSchemeGuid.view_table_usage as one of the paramters of the method
GetOledbSchemaTable.I get the below error saying when used the above
"The schema view_table_usage is not supported for SQLOLEDB.1 provider"
Is there any work around for this instead of using SQL server queries for
this.

Regards
K.Prathap
 
V

Val Mazur \(MVP\)

Hi,

You could try to use SqlClient instead of OLEDB provider. Since it is
native, it could provide more information. You could try GetSchemaTable
method of SqlDataReader to get this info

--
Val Mazur
Microsoft MVP

http://xport.mvps.org



"Error - OledbschemaGuid.view_table_usage" <Error -
(e-mail address removed)> wrote in message
news:[email protected]...
 
M

Mark Ashton

SqlDataReader.GetSchemaTable only provides metadata information on the query
that was executed.

In V1.1 the only alternative to OleDbConnection.GetOleDbSchemaTable is to
execute a query for the information you want.
 

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