Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

OdbcCommandBuilder.DeriveParameters() / SqlCommandBuilder.DeriveParameters()

$
0
0

Hi all,

I have this:

                cn = new OdbcConnection("Driver={SQL Server};Server=My-PC01;Database=Northwind;Trusted_Connection=Yes");

                OdbcCommand cmd = new OdbcCommand("{? = call dbo.usp_TestParameters (?, ?)}", cn);
                cmd.CommandType = CommandType.StoredProcedure;
                cn.Open();
                OdbcCommandBuilder.DeriveParameters(cmd);

But the count from cmd.Parameters is alway 0.

However, If I use SqlClient, the count from cmd.Parameters is alway 3.

Can someone tell me why 

OdbcCommandBuilder.DeriveParameters() does not work?

Thanks in advance.


Viewing all articles
Browse latest Browse all 8156

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>