Skip to Content
author's profile photo Former Member
Former Member

Calling RFC in dynpro: Issue

Hi,

With reference to the material creation blog on sdn, I'm trying to access BAPI_MATERIAL_SAVEDATA.

I have taken following fields for material creation

1. Material No.

2. Description

3. Industry sector

4. Material type

After deployment I created the required JCo connections. But on running this application, I no output is displayed. I'm also displaying the return msg.

On checking the SAP MARA table no new record is found.

In this case is it necessary to COMMIT the SAP database? Which bapi to call for database commit work?

Is it always mandatory to commit the database from dynpro by calling a bapi ?

Can anyone help me in this regard ?

Thanks, in advance,

Prasanna

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 08:22 AM

    hi,

    <b>BAPI_TRANSACTION_COMMIT</b> is the transaction for commit. check whether the BAPI_MATERIAL_SAVEDATA requires commit and use it. before that check whether you are sending all the mandatory fields to the BAPI.

    Regards,

    Gopi

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 10:03 AM

    Hey,

    if you are not sure whether you fill the mandatory fields right (think about leading zeros!), check and test the Bapi in your R/3 with the SE37. But Attention, the SE37 does not always behaviour the same way the BAPI does if it was called by RFC, that might sound strange, but it is like that.

    You could also write a Z_BAPI on your own that encapsulates the mentioned BAPI. Program an endless loop in the first lines of ABAP. Than call the Z_BAPI per RFC. In SM50 you will find your process. Catch it with /nSM50, set the cursor at the process you want to debug, go Program/Session -> Program -> Debugging.

    Now the Debugger will open with the Bapi in the endless loop. Edit the Bapi variables to stop the loop and check the interface values.

    Hope that helped a little.

    Christof

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.