Thank you for the response. I was able to create a BOM explosion for EPDM that seems to be working out well. It required retrieving data from PSTDTL, PSTHDR and ITMRVA.
Here it is. Hopefully it will help someone else out.
WITH temp_pstruc (RELVL, ITEM, QTY, PARENT, UOM, BATQTY, HD)AS
SELECT 1, CINBR, 0, b.PINBR, UNMSR, SBQTY, PSHD
from amflibe/pstdtl as b LEFT OUTER JOIN amflibe/itmrva asc
on b.cinbr = c.itnbr
LEFT OUTER JOIN AMFLIBE/PSTHDR as d on b.pinbr =d.pinbr
where b.pinbr = '8M0122241'
UNION ALL SELECT a.relvl + 1, b.cinbr, b.qtypr / d.sbqty,b.pinbr,
c.unmsr, d.sbqty, d.pshd
FROM temp_pstruc AS a join amflibe/pstdtl AS b
on ITEM = b.pinbr
LEFT OUTER JOIN AMFLIBE/ITMRVA AS c on b.cinbr =c.itnbr
LEFT OUTER JOIN AMFLIBE/PSTHDR AS d on b.pinbr =d.pinbr
SELECT DISTINCT *
Laura Ubelhor, Consultech Services, Inc.
Office: (248) 628-6800
ubelhor@xxxxxxxxxxxxx | www.consultechservicesinc.com
On Thursday, July 25, 2019, 7:24:15 PM EDT, Vojtech.Mrazek@xxxxxxx <Vojtech.Mrazek@xxxxxxx> wrote:
the SQL statement is like the yeti (bigfoot) - everyone heard about him,
but nobody saw him ...
For EPDM, there is a XA program AMDPSR0R to create indented bill of
material for one item. You can call the program in your RPG program for
more items. If you want more details or sample source code, contact me.
Other ways, in Power-LInk you can customize the view for Indented BOM, so
users can export BOM explosion from Power-Link to Excel - but only for one
finished item. If you need the BOM explosion for more finished items, you
need the RPG program.
vojtech.mrazek@xxxxxxxÂ Â Â
-----"MAPICS-L" <mapics-l-bounces@xxxxxxxxxxxxxxxxxx> napsal(a): -----
Komu: "MAPICS ERP System Discussion" <mapics-l@xxxxxxxxxxxxxxxxxx>
Od: "Laura Ubelhor" <ubelhor@xxxxxxxxxxxxx>
Odesilatel: "MAPICS-L" <mapics-l-bounces@xxxxxxxxxxxxxxxxxx>
Datum: 22.7.2019 20:11
Pďż˝edmďż˝t: [MAPICS-L] BOM explosion BOM
Does anyone readily have an SQL statement for BOM explosion?
I know that I've coded it before but am not readily finding the SQL
statement.Â I know this is something many have done and conquered in
Mapics XA so thought I'd ask if anyone has a statement readily available
and is willing to share.
This is for EPDM.
Laura Ubelhor,Â Consultech Services, Inc.
Office: (248) 628-6800Â
ubelhor@xxxxxxxxxxxxxÂ |Â www.consultechservicesinc.com
This is the MAPICS ERP System Discussion (MAPICS-L) mailing list
To post a message email: MAPICS-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
or email: MAPICS-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
As an Amazon Associate we earn from qualifying purchases.