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 related function module

Former Member
0 Likes
1,691

Hi ,

i have a problem any one can give me suggestion plz

1)  i have three fields 1)cust num 2) status 3) name ,  in status  the value is 'YES'  and name field value is krishna

but in status field it is showing   YES K 

and in name field it is showing    rishna

i declare the fields :  status field length is 6 and name field length is 12

how to correct it

2) in function module in tables , i declare 2 internal tables but in out put it is showing 4

it is showing like below

first internal table name         0

                     result            12

second internal table name    0

                      result             3

why it is showing like this , can any one give me suggestion plz

9 REPLIES 9
Read only

Former Member
0 Likes
1,656

Hi,

Your question is not so clear. But in my understanding i will prefer this,

1. For the status what are will be the values(YES/NO) so declare the status field length as 3.

    And i think you are executing the normal report by write statement right?

So check with the spacing allocation that you have did for this report output.

For EX : write : 1(10) itab-cust_name.

Thanks,

Pradeep

Read only

0 Likes
1,656

Hi, Thank u ,

can you give me the suggestion for second one , in FM out put it is showing 4 tables but in tables tab i declare only 2 .... it is bapi related FM

Read only

0 Likes
1,656

Hi ,

Can you please explain more clear.

What FM you are using and for what ?

The tables you mentioned is what ?

Read only

0 Likes
1,656

i create new FM (start with ZBAPI , in attribute tab gave it as Remote enabled) in import tab i am declaring two inputs and in tables tab i gave it_getdata and it_return (two internal tabels)... when i execute this FM here  i am giving two input values  for that i am getting the correct output  only but it is showing extra two internal  tables also  .....

Read only

0 Likes
1,656

output is coming like this

it_getdata         0

       result       12

it_return            0

       result         0

Read only

0 Likes
1,656

output is coming like this

it_getdata         0

       result       12

it_return            0

       result         0

i hope it is wrong because i declare only two internal tables here it is showing 4 like above

Read only

0 Likes
1,656

Read only

0 Likes
1,656

Hi ,

I got your question now.

The answer is ,

when you are running the bapi you gave the 2 inputs right ?

The two table has been populated correctly.

For every function module tables you will have the 2 table results for each table.

first will be your inputs .

second will be your result of the table.

So you no need worry about those 2 internal tables and no declartions is needed.

All you have done is correct .

when you are calling this FM read the (Yellow)  internal table.

Hope it helps.

Thanks,

Pradeep.

Read only

0 Likes
1,656

Hi Pradeep,

Thank you very much