Optional Parameters

B

Biser

Hello!
I have a question about treathment of optional parameters of Stored
Procedures in ADO.Net
If I have the following SP (on SQL Server 7.0 DB):


CREATE PROCEDURE dbo.test_sp
@first_param int = NULL,
@second_param int OUTPUT,
@third_param int
AS
BEGIN
RETURN 1
END


How can I found using SqlCommandBuilder.DeriveParameters method that the
first parameter is OPTIONAL, second is OUTPUT and the third is not optional
INPUT parameter.

When the command.Direction property will have value "Output" only not
"InputOutput"?
Thanks.
 
W

William \(Bill\) Vaughn

See my article that discusses parameter management.
http://www.betav.com/msdn_magazine.htm


--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
MVP, hRD
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
 

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