Output Parameters

  • Thread starter Thread starter Roshawn
  • Start date Start date
R

Roshawn

Hi,

I was wondering what would be the best place to use output parameters.
Should I use them when retrieving one row or multiple rows?

Also, is there a performance penalty if I neglected to use them?

Thanks,
Roshawn
 
Hi,

It depends. Sometimes you could return scalar value, calculated or prepared
inside of the SP. Sometimes you could return some sort of status how your SP
finished or error code without throwing error message. There is not specific
way how you required to use it. This is just the way to communicate with the
SP
 
Someone already pointed to the article, but consider than OUTPUT parameters
(and you can return dozens) are far faster to process than a single row
passed back as a rowset. No, they can't be used where you need a rowset, but
they can pass back aggregates or other information that's computed
server-side.


--
____________________________________
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.
__________________________________
 
Back
Top