Application Development 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: 

Fetching table data from another SAP system or client.

0 Kudos

Hi,

I am working on client 100 and want to fetch a complete table from client 200 at once using a report program. I tried using RFC_READ_TABLE but that is not working for me as it only fetches one single column also my where clause is a long statement which is getting truncated due to the limit of C(72).

Thanks

1 ACCEPTED SOLUTION

GK817
Active Contributor

Hi,

You should create a RFC-enabled FM and call it with destination to remote system. This way you can include all you complex where logic and tables in FM code.

Gaurav

5 REPLIES 5

GK817
Active Contributor

Hi,

You should create a RFC-enabled FM and call it with destination to remote system. This way you can include all you complex where logic and tables in FM code.

Gaurav

0 Kudos

Thanks for the help.

Sandra_Rossi
Active Contributor

1. Use SELECT ... USING CLIENT '200' ... (or CLIENT SPECIFIED ... WHERE <clientcolumn> = '200')

2. Or create a custom RFC-enabled function module to do the job, instead of using RFC_READ_TABLE (not a good idea to use it, as already discussed in the forum).

0 Kudos

Very helpful.
Thanks.

Sandra_Rossi
Active Contributor
0 Kudos

For information, concerning RFC_READ_TABLE:

  • I don't understand why you couldn't select more than one column (parameter FIELDS is an internal table, each line is used to indicate one column).
  • There's no limit of the WHERE because it's an internal table (lines of 72 characters each, which are concatenated to form one logical expression).

Anyway, don't use RFC_READ_TABLE, as already discussed in the forum.