cancel
Showing results for 
Search instead for 
Did you mean: 

JRA Function Calls to 'RFC_READ_TABLE'

Former Member
0 Kudos

Hi,

We have a problem trying to use a JRA function call with the SAP 'RFC_READ_TABLE' function module.

The metadata for the Data Response does not seem to be there.

While using the JRA function call with other BAPI's is fine and using the 'RFC_READ_TABLE' function with a standard JCO function call is also ok.

Has anyone come across this combination of trying to use JRA's with the 'RFC_READ_TABLE' function module ?

Thanks,

Gary

Accepted Solutions (1)

Accepted Solutions (1)

agentry_src
Active Contributor
0 Kudos

Hi Gary,

Which table or tables have you tried it with?

Thanks,

Mike

Former Member
0 Kudos

Hi,

With any table. I have tried T001 for example.

Maybe i am missing something but there seems to be no placeholder in the response section for the returned data.

Thanks,

Gary

agentry_src
Active Contributor
0 Kudos

Hi Gary,

I just wanted a specific table so we could eliminate that variable. I am going to see if I can duplicate your error on my system.

Thanks,

Mike

agentry_src
Active Contributor
0 Kudos

Hi Gary,

I used the JRA set up (Start Session, etc.) and JRA Function Call using the RFC_READ_TABLE. I used table name "T001" and assigned a single field "BUKRS" to be retrieved. I set ROWCOUNT = 50 and removed /RFC_READ_TABLE/INPUT/DELIMITER and /RFC_READ_TABLE/INPUT/NO_DATA (They sometimes have default values which can cause problems with the RFC execution). I then executed the transaction and using two tracers displayed the Request and Response segments returned after executing the RFC. The Response segment retrieved 50 instances of the Company Code (BUKRS).

I was unable to duplicate your error. Can you provide more information into your test? Which fields did you assign to be retrieved? If you do not assign fields to be returned, you will get nothing in the Response segment. Perhaps this is the problem.

Thanks,

Mike

Edited by: Michael Appleby on Oct 21, 2008 7:57 PM

Edited by: Michael Appleby on Oct 21, 2008 7:58 PM

agentry_src
Active Contributor
0 Kudos

Hi Gary,

I now understand your issue. There is no static Response segment, because you define it dynamically by selecting the fields for the output. You can still map the output of the RFC call, but it will not show up under the Response segment of the JRA Function call. You can build the link manually (typing it in from an sample output from your testing). You could copy a test copy into a local property and save it for using to link to the input of the repeater. You could create a reference document and use that. I would recommend the first. Or you could use the following:

RFC_READ_TABLE.Response{/RFC_READ_TABLE/TABLES/DATA/item} as you input.

Your output from the Repeater will be:

Repeater_0.Output{/item/WA}

WA is a single concatenated field holding all data of the table fields you defined in the FIELDS section of the BAPI separated by whatever delimiter you chose or by none at all if you simply removed the delimiter field as I usually do.

Hope this helps. You may also want to search this forum for RFC_READ_TABLE for more information.

Mike

Former Member
0 Kudos

Michael,

I used the expressions that you suggested and this has worked a treat.

It's strange that a JCO function call has a static response segment when using RFC_READ_TABLE while the JRA function call does not.

Thank you for your assistance.

Gary

agentry_src
Active Contributor
0 Kudos

Hi Gary,

I have to agree with you. If you have it with one, you should have it with the other. Although I would have thought that neither would have it rather than both. This BAPI and those in the SQ01 query group (RSAQ) are a bit out of the mainstream of RFC functions and take a little extra work to implement. After a while, you (or at least I) start to not worry about BAPI idiosyncrasies and just keep on working. There is a lot of variability in the behavior and styles in the RFC pool. Probably from different programmers.

Good luck,

Mike

agentry_src
Active Contributor
0 Kudos

Hi Gary,

A little followup. I went back to create a JCO equivalent to my JRA test program. While doing so, I realized that the option to create Request and Response documents never showed up in the JRA. Please submit a ticket as I am pretty sure that functionality was supposed to be built in.

The more I test the more interesting the results. It looks like there may be a problem with the RFC after all. It may have a syntax problem in the ABAP code. I will look into it further, but please make sure you get a ticket started.

Thanks,

Mike

Edited by: Michael Appleby on Oct 22, 2008 3:37 PM

Answers (0)