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: 

Problem with length of 45 in RSPARAMS for RS_VARIANT_CONTENTS FM

Former Member
0 Kudos

Hi experts,

While using the function module RS_VARIANT_CONTENTS to fetch the contents of variant, it is returning the values upto 45 characters as the internal table is of type RSPARAMS and the low and high values are of 45 characters in length.

This will create a problem especially if you use a file path on the selection screen with length more than 45 characters and while using the FM, it returns the value of the file only up to 45 characters.

I also tried another solution provided in the forum like below using import statement and database cluster but it is still returning 45 characters.

Can some body help on this issue please?

I have searched the entire forum for this problem..I could see some answers but they don't resolve the problem yet.


REPORT ztest MESSAGE-ID 00.
DATA: BEGIN OF st_key,
        report LIKE rsvar-report,
        variant LIKE rsvar-variant,
      END OF st_key.

DATA: file_name(128).

st_key-report  = 'ZREPORT_NAME'.
st_key-variant = '&0000000000018'.

IMPORT p_dpath TO file_name FROM DATABASE vari(va) ID st_key.
IF sy-subrc IS INITIAL.
  WRITE 'successful'.
ENDIF.

2 REPLIES 2

guillaume-hrc
Active Contributor
0 Kudos

Hi,

In my system (Ecc 6.0), your code snippet returns the whole path.

Best regards,

Guillaume

Former Member
0 Kudos

this is resolved..My code works however, it the length is 200 characters it is still stopping at 45 characters