cancel
Showing results for 
Search instead for 
Did you mean: 

Syntax question rfc_read_table via XML

Former Member
0 Kudos

Hi,

I am trying to do an rfc call to rfc_read table via XML and I want to select only some fields as otherwise the structure is too large and I get the error "data_buffer_exceeded".

My problem is that I have no idea ho to pass the fieldnames via XML as it is not an input parameter but a table. From SE37 it works fine.

Here is my code for the whole table:

<Request type="executeFunction" function="RFC_READ_TABLE"

system="SAP_TEST" systemType="SAP_ERP" manageConnection="N" encode="Y"

commit="N" convert="N" dsmid="anything">

<Input name="INPUT" shape="OBJ" appName="INPUT">

<Meta>

<field name="QUERY_TABLE" appName="QUERY_TABLE" type="string" />

</Meta>

<Row QUERY_TABLE="BKPF" />

</Input>

<Output name="OPTIONS" appName="OPTIONS" shape="SET" capacity="10" />

<Output name="FIELDS" appName="FIELDS" shape="SET" capacity="10" />

<Output name="DATA" appName="DATA" shape="SET" capacity="10000" />

</Request>

What I need is the syntax to also fill the parameter FIELDS in the TABLE

Thanks a lot for any help,

Chris

Accepted Solutions (1)

Accepted Solutions (1)

former_member751941
Active Contributor
0 Kudos

Hi Christian,

Check it.

<field name="depid">

<column name="DEPID" table="EMPLOYEE"/>

</field>

<field name="name">

<column name="NAME" table="EMPLOYEE"/>

</field>

<field name="sal">

<column name="SALARY" table="EMPLOYEE"/>

</field>

http://help.sap.com/saphelp_nw70/helpdata/en/e0/3506f949a342fd967ca6de747bb2c2/frameset.htm

Regards,

Mithu

Former Member
0 Kudos

Hi Mithu,

thanks for the reply but it didn't solve my problem.

The interface of the RFC has some input fields and some tables.

The syntax to enter a value for a single input field works fine:

<Input name="INPUT" shape="OBJ" appName="INPUT">

<Meta>

<field name="QUERY_TABLE" appName="QUERY_TABLE" type="string" />

</Meta>

<Row QUERY_TABLE="BKPF" />

</Input>

I just have the problem to find out the syntax to handle the tables. The table FIELDS seems to be used for input and output. If I call the function (rfc_read_table) via SE37 I can enter values of FIELDNAMEs in the table FIELDS and the function works fine as only these fields are returned in the resulting DATA table. I now want to call the RFC function via XML.

I tried the following:

<Input name="FIELDS" appName="FIELDS" shape="SET">

<Meta>

<field name="FIELDNAME" appName="FIELDS" type="string" />

</Meta>

<Row FIELDNAME="bukrs" />

<Row FIELDNAME="belnr" />

</Input>

but it does not work :-((

Any other hints ??

Thanks,

Chris

Answers (0)