-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: Mouli
Message 1 in Discussion

Hi, I have the knowledge of the DB Connection string and a Stored Proc residing on the 
Data base, and the dbtype of the parameters. For executing the stored proc by building 
a command object, is it required to know the names for the Parameters?   Is ther any 
way  a) i can execute a command , (command type Stored Proc) just by specifying the 
parameter values and not the praramter names?  If i use the overload of the 
constructor of the  sql parameter class as below:  
SqlCommand command = new SqlCommand("XXX"); 
command.CommandType = CommandType.StoredProcedure; 
SqlParameter sqlParameterTemp = new SqlParameter(); 
sqlParameterTemp.Value = "Test"; 
command.Parameters.Add(sqlParameterTemp); 
i get an error "Parameter1 is not a valid parameter for the Stored Procedure XXX" OR 
b) is there any way by which given a connection, i can dynamically discover the 
parameter details to a Stored Proc.   Any relavant help would be highly appritiated. 
Thank you.   Regards, Mouli

-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/BDOTNET/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to