Some bit twiddlers may argue about performance. I'll stay out of that.

One point is the localization of variables.
mynewvar=myfunctionsresult(parm1 : parm2)
with the prototyping setup to protect parm1 and parm2, sure beats
call myfunction
and passing all the parms.

Subprocedures support recursion.

subprocedures, moved to a service program, can be converted into a UDF, or
User Defined Function, of SQL. Which is really cool.
select itemnumber, quantity, customer, specialpricing(itemnumber,
quantity, customer) from orderlinetable

Let's say OLDPGM calls OLDBOX using all the old fashioned parms and
whatnot. Change OLDBOX to execute the subprocedure from the service

Rob Berendt

This thread ...


Return to Archive home page | Return to MIDRANGE.COM home page