Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Function module to replace CSAP_MAT_BOM_READ

Former Member
0 Likes
2,452

Hi

I have a requirement in which I use the function module CSAP_MAT_BOM_READ to read the material BOM. The problem is that there is a huge chunk of data and for each record it calls the function module which is causing a performance issue.

I tried to replace the funtion module with a join on STKO, STPO . But the problem is that in the funtion module there is some logic in which it checks the validity date which comes from Change Number.

Is there any function module which I can replace the existing one or any logic which can be implemented in the join condition?

Regards,

Ajith

2 REPLIES 2
Read only

Former Member
0 Likes
1,232

Hi Ajith,

I'm not sure if this helps but here's a suggestion:-

Table <b>MAST</b> (Material to BOM Link) contains the BOM number for each material.

Tables <b>STPO</b> and <b>STKO</b> gives the information regarding BOM components.

Consequently:

Table <b>STKO</b> (BOM Header) can be linked to

Table <b>STAS</b> (BOMs - Item Selection) via:

<i>STLNR</i> (Bill of material) and

<i>STLAL</i> (Alternative BOM).

From this join you can then connect to the relevant entry in Table <b>STPO</b> (BOM item) via:

<i>STLNR</i> (Bill of material) and

<i>STLKN</i> (BOM item node number).

Within table <b>STKO</b> there is a field <i>DATUV</i> (Valid-from date) that can be used if you want to restrict the values based on validity date.

I hope this helps.

Hafeez

Read only

0 Likes
1,232

Hi Ajith,

Just to add to my previous mail:-

I've suddenly come across the following function module that you may find useful:

<b>CS_BOM_EXPL_MAT_V2</b> (BOM explosion for material).

Again, I hope this helps.

Hafeez