I would argue that my point is more relevant than yours, since yours is
based neither on SQL nor on the ILE (Service Program / Module) model. But
that's opinion - completely immaterial, and that brings us back to Matt's
original plea (and my echo) for SQL reference that will put the discussion
to rest.

(Yes, sadly, that is one unwieldy sentence. You could fix it. :))

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"If you tell the truth you don't have to remember anything."
-- Mark Twain


But, there is no SQL syntax, as far as I am aware, to declare which
parameters should be "pass by value" and which ones should be "pass by
reference". -- you can only state "PARAMETER STYLE GENERAL" and that
applies to the whole stored procedure. So, I don't think your point
about service programs vs. programs matters? :-o

Mark

> On 7/30/2010 8:38 PM, Dennis Lovelady wrote:
I'm not Matt, but...

I would agree if it weren't for the fact that UDF interfaces use
service
programs and modules. The fact that *PGM objects are called only by
reference, is immaterial.

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"The most remarkable thing about my mother is that for thirty years
she
served the family nothing but leftovers. The original meal has never
been
found."
-- Calvin Trillin



I am pretty sure that "PARAMETER STYLE GENERAL" means that each
parameter is passed "by reference", which is the usual convention
when
CALLing an external *PGM in OS/400. That is to say, since this is an
"external" UDF, you can pass parameters by reference, but not by
value.

Does that help?

Mark S. Waterbury

> On 7/30/2010 4:30 PM, MattLavinder@xxxxxxxxxxxxxxxxxxx wrote:

Not sure why you feel this would require you to "always change the
prototype." Seems to me (what works for me is) that for UDF and

stored

procedures, my prototypes say CONST instead of VALUE. What
problem

does

this create for you?


Basically I was asking, "Am I doing this wrong or is this the only

way to

fix it?" It's not difficult, but if I was defining the UDF

incorrectly,

correcting that definition would be a simpler solution.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.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 on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.