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

BAPI_MATERIAL_GETLIST returns nothing

Former Member
0 Likes
1,126

Hello friends,

i am trying SE37 command and trying to execute BAPI_MATERIAL_GETLIST , it asks for maxrows which i give as say 5-6 , and hit execute button,

I expect it to reuturn a list of all materials with their material number , however it returns nothing in MATNRLIST ,

it only returns one entry in each of following

MATNRSELECTION :

Sign : E

Option : CP

MATNR_LOW : *

MATNR_HIGH :

MATERIALSHORTDESCSEL

Sign : E

Option : CP

MATNR_LOW : *

MATNR_HIGH :

what i want is , it should give me a list of all material numbers , as i have to iterate over these material numbers and call BAPI_MATERIAL_GET_DETAIL to get details of all the materials

thanks

5 REPLIES 5
Read only

Former Member
0 Likes
861

Hello Rohit,

Try get the where used list and check how the BAPI is used in other reports. LIkewise u pass values to the FM.

Reward points if it is helpful.

Regards,

Vasanth

Read only

Former Member
0 Likes
861

If you see the code for the FM, it expects a value in the range MATNRSELECTION too.

You will need to populate this range. I tried with the following:

Sign - I

Option - BT

Low - 1000

High - 1000000

On execution, the BAPI returned all matnr values within the above range.

Hope this helps.

Sudha

Message was edited by: Sudha Mohan

Read only

Former Member
0 Likes
861

MATNRSELECTION acts like a select option for MATNR in this function. You need to provide input values in this table similar to providing material values to a select option for Material.

-Kiran

Read only

0 Likes
861

cooool, thanks guys it helped ,thanks once again to all of you

Read only

TMNielsen
Contributor
0 Likes
861

Hi friend

I think you must always at least a MATNRSELECTION or a MATERIALSHORTDESCSEL.

If you just want all material you must fill the MATNRSELECTION with these values:

Sign : I

Option : CP

MATNR_LOW : *

MATNR_HIGH :

Best regards

Thomas Madsen Nielsen