This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
One of my stored procedures has an optional parameter defined as follows:
If I set the command like this:
I get an error indicating that optionalParam is required but was not supplied. How do I deal with this? TIA. Klaus |
|
|
The standard ADO.NET approach for calling stored procedures is to set cmd.CommandText to the proc name and then cmd.CommandType to CommandType.StoredProcedure, you can then specify the parameters in the parameters collection. e.g.
Also given the optionalParam is defaulting to null in your proc you wont need to include it in the parameter list.
|
|