Re: Odpověď: BOM explosion BOM
Laura Ubelhor <[email protected]> Wed, 31 Jul 2019 01:48:57 +0000 (UTC)
| Newsgroups | gmane.comp.systems.as400.mapics |
|---|---|
| Message-ID | <[email protected]> |
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 * FROM temp_pstruc Regards,Laura Laura Ubelhor, Consultech Services, Inc. Office: (248) 628-6800 [email protected] | www.consultechservicesinc.com On Thursday, July 25, 2019, 7:24:15 PM EDT, [email protected] <[email protected]> wrote: Hello Laura, 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 [1][email protected]   MAPICS Consultant Czech Republic -----"MAPICS-L" <[2][email protected]> napsal(a): ----- Komu: "MAPICS ERP System Discussion" <[3][email protected]> Od: "Laura Ubelhor" <[email protected]> Odesilatel: "MAPICS-L" <[email protected]> Datum: 22.7.2019 20:11 P�edm�t: [MAPICS-L] BOM explosion BOM HellO: 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. ThanksRegards,Laura Laura Ubelhor, Consultech Services, Inc. Office: (248) 628-6800 [4][email protected] | [5]www.consultechservicesinc.com -- This is the MAPICS ERP System Discussion (MAPICS-L) mailing list To post a message email: [6][email protected] To subscribe, unsubscribe, or change list options, visit: [7]https://lists.midrange.com/mailman/listinfo/mapics-l or email: [8][email protected] Before posting, please take a moment to review the archives at [9]https://archive.midrange.com/mapics-l. </[email protected]></[email protected]> References Visible links 1. mailto:[email protected] 2. mailto:[email protected] 3. mailto:[email protected] 4. mailto:[email protected] 5. http://www.consultechservicesinc.com/ 6. mailto:[email protected] 7. https://lists.midrange.com/mailman/listinfo/mapics-l 8. mailto:[email protected] 9. https://archive.midrange.com/mapics-l -- This is the MAPICS ERP System Discussion (MAPICS-L) mailing list To post a message email: [email protected] To subscribe, unsubscribe, or change list options, visit: https://lists.midrange.com/mailman/listinfo/mapics-l or email: [email protected] Before posting, please take a moment to review the archives at https://archive.midrange.com/mapics-l. -- This is the MAPICS ERP System Discussion (MAPICS-L) mailing list To post a message email: [email protected] To subscribe, unsubscribe, or change list options, visit: https://lists.midrange.com/mailman/listinfo/mapics-l or email: [email protected] Before posting, please take a moment to review the archives at https://archive.midrange.com/mapics-l.