Application Development and Automation 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: 
Read only

Data error (invalid data type 17) in a Remote Function Call

Former Member
0 Likes
3,322

Hi,

I am passing 2 select-option tables to RFC.

Tables have structures -

Table1 SIGN(C1)

OPTION(C2)

HIGH(C6)

LOW(C6)

Table2 SIGN(C1)

OPTION(C2)

HIGH(C20)

LOW(C20)

At the destination side, I have created two table types which have same structure.

But when I call the RFC , program terminates with error - "Data error (invalid data type 17) in a Remote Function Call"

Not able to understand the reason for this error. Please help.

Thanks,

Sujeet

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,375

Hi,

check out this example

[LINK|http://abap.googlar.eu/viewtopic.php?f=5&t=28]

You have several ranges that you can use like RANGE_AUF.

Function example:


FUNCTION zexemple.
*"----------------------------------------------------------------------
*"*"Interface local:
*"  IMPORTING
*"     REFERENCE(R_HORA) TYPE  FLAG
*"     REFERENCE(R_DIA_1) TYPE  FLAG
*"     REFERENCE(P_IDOC) TYPE  FLAG
*"  EXPORTING
*"     REFERENCE(MSG) TYPE  CHAR255
*"  TABLES
*"      T_OIFSPBL STRUCTURE  OIFSPBL
*"      SL_PBLNR STRUCTURE  RANGE_PBLNR
*"      SL_MATNR STRUCTURE  RANGE_MATNR
*"      SL_HORA STRUCTURE  RANGE_UZEIT
*"      T_ERROS STRUCTURE  ZARSTRING

ENDFUNCTION.

Report:


SELECT-OPTIONS: sl_pblnr FOR oirbpblb-pblnr,
                              sl_matnr FOR a361-matnr.
....

~

Final question:

You are passing the values using TABLES and not IMPORTING right?

2 REPLIES 2
Read only

Former Member
0 Likes
1,376

Hi,

check out this example

[LINK|http://abap.googlar.eu/viewtopic.php?f=5&t=28]

You have several ranges that you can use like RANGE_AUF.

Function example:


FUNCTION zexemple.
*"----------------------------------------------------------------------
*"*"Interface local:
*"  IMPORTING
*"     REFERENCE(R_HORA) TYPE  FLAG
*"     REFERENCE(R_DIA_1) TYPE  FLAG
*"     REFERENCE(P_IDOC) TYPE  FLAG
*"  EXPORTING
*"     REFERENCE(MSG) TYPE  CHAR255
*"  TABLES
*"      T_OIFSPBL STRUCTURE  OIFSPBL
*"      SL_PBLNR STRUCTURE  RANGE_PBLNR
*"      SL_MATNR STRUCTURE  RANGE_MATNR
*"      SL_HORA STRUCTURE  RANGE_UZEIT
*"      T_ERROS STRUCTURE  ZARSTRING

ENDFUNCTION.

Report:


SELECT-OPTIONS: sl_pblnr FOR oirbpblb-pblnr,
                              sl_matnr FOR a361-matnr.
....

~

Final question:

You are passing the values using TABLES and not IMPORTING right?

Read only

0 Likes
1,375

Thanks for the inputs.

It helped. Actually it was silly mistake; I had passed structure instead of table. missed [] after the name.