|
Joe,
Is this what you meant by an Bill of Material Explosion?
P BillOfMat B
D BillOfMat PI
D Parent 15a CONST
D* Local fields
D Child S like(Parent)
C/exec sql
C+ Declare C1 cursor for
C+ Select bchld from mbm
C+ where bprod=:parent
C/end-exec
C/exec sql
C+ Open C1
C/end-exec
C/exec sql
C+ fetch c1 into :Child
C/end-exec
C dow sqlcod=*zeros
C write printrec
C callp BillOfMat(child)
C/exec sql
C+ fetch c1 into :Child
C/end-exec
C EndDo
C/exec sql
C+ Close C1
C/end-exec
P BillOfMat E
While RPG supports recursion in subprocedures, I am trying to beat the
precompiler people into submission to stop limiting RPG.
Rob Berendt
--
"They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety."
Benjamin Franklin
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.