MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » July 2014

Re: Service Program or Stand Alone



fixed

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
wParm1=parm1;
wParm2=parm2;
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

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

Rob Berendt





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

This mailing list archive is Copyright 1997-2014 by MIDRANGE dot COM and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available here. If you have questions about this, please contact