Skip to Content
0
Former Member
Sep 18, 2007 at 09:22 AM

variable value from another variable

14 Views

Hi all,

I created a query where one variable fill nother variable with following abap code:

when 'ZODACE'.

tables: /BIC/AZSD_O0100,

/BIC/AZSD_O0200.

ranges: r_createdon for /BIC/AZSD_O0100-CREATEDON.

break-point.

if i_step = 2.

loop at i_t_var_range into loc_var_range

where vnam = 'ZDATADOC'.

clear r_createdon.

r_createdon-low = loc_var_range-low.

r_createdon-high = loc_var_range-high.

r_createdon-sign = 'I'.

r_createdon-option = 'BT'.

append r_createdon.

exit.

endloop.

select DOC_NUMBER into

/BIC/AZSD_O0100-DOC_NUMBER

from /BIC/AZSD_O0100

where /BIC/ZAUDAT in r_createdon.

select single * from /BIC/AZSD_O0200

  • select * from /BIC/AZSD_O0200

where refer_doc = /BIC/AZSD_O0100-DOC_NUMBER.

clear l_s_range.

l_s_range-low = /BIC/AZSD_O0200-refer_doc.

l_s_range-sign = 'I'.

l_s_range-opt = 'EQ'.

append l_s_range to e_t_range.

  • endselect.

endselect.

endif.

-


The variable are:

ZODACE based on IO 0REFER_DOC with customer exit

ZDATADOC based on IO ZDATU with manual entry

After wich end-user digit a data in ZDATADOC popup I take ODOC_NUMBER in order item ODS ZSD_O01 where ZDATADOC=CREATEDON.

With 0DOC_NUMBER I go to delivery item ODS ZSD_O02 and I take the corresponding 0REFER_DOC and then I fill variable ZODACE.

0REFER_DOC is in row of the query.

When I start the query I receive the following error message:

Error for variable in the customer exit ZODACE

and in debug i find this message:

System error in the program CL_RSR_REQUEST and Form GET_SETXX_WA

How can I do please?

Thanks in advance

Gianmarco