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

Execute a Function Module from Java

I have a Function Module ZLIST_MATERIAL_DETAILS which accepts Two parameters MaterialID and MaterialName as VALUE in Import Parameter and returns all the Material Details as Export Parameter.

FM is RFC enabled and I am trying to execute this FM using Java application . I am able to establish connection to SAP from Java Application .

I wanted to know the Syntax or an example of executing a SAP FM from Java by passing import parameters as value and display the export parameter information would be a great help .

Thanks in Advance .

Best Regards,


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Jan 08, 2014 at 02:29 PM


    if you use JRA for connection to the backend system, here is example how to call remote function module from Java:

    Client Programming Model (SAP Library - Components of SAP Communication Technology)

    In step 4.


    MyBank is the name of your import parameter in FM and BankOfWalldorf is the value of import parameter.

    In step 6.

    After execution you get output, which is also MappedRecord.

    So getting specific return value:


    NameOfOutputParameter is the name of output parameter from FM.

    Conversion between Java and ABAP types is automated, so you shouldn't care of it.

    I hope it helps.

    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.