ADODB and diffence between adParamOutput and adParamReturnValue

Hi

Just trying to set up a command object for the first time.

I cant seem to find any info on the difference between the direction type

adParamOutput
and
adParamReturnValue

I would be grateful for any info or links that would clarify this for me.
colindowAsked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
adParamOutput  refers to a parameter of the procedure that gives back a value
adParamReturnValue  refers to the return value of the procedure itself, not the parameter


create procedure testparam @param1 INT OUTPUT
as
  set @param1 = 99
  return 2


to retrieve the param1 value of 99, you have to define a OUTPUT parameter
to retrieve the return value of 2, you have to define a RETURNVALUE parameter
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.