Skip to Content
0
Former Member
Feb 20, 2009 at 09:21 AM

end routine with no update

157 Views

Hi,

I have problems with a end routine in a transformation. I try to load 0CUST_SALES information. in this transforùmation i created a process in the End routine to recover cust sales hierarchy in attributes.

I do it in the End routine because i have fields only in my target

My problem is there is no update of the fields i changed in my master data. i have in the monitor the feedback

Updating attributes for InfoObject 0CUST_SALES : 1 -> 1 Data Records

No database operations necessary, data unchanged

But when i enter in debug mode i see that the code works.

This is my abap program of the end routine

SELECT * FROM /BI0/HCUST_SALES INTO TABLE i_hier_cust

WHERE HIEID = 'D536X863BMP4D3C8JXCFEBBEZ'.

LOOP AT RESULT_PACKAGE INTO wa_RESULT_PACKAGE.

clear v_idcust.

clear wa.

CONCATENATE wa_RESULT_PACKAGE-division

wa_RESULT_PACKAGE-DISTR_CHAN

wa_RESULT_PACKAGE-salesorg

wa_RESULT_PACKAGE-cust_sales INTO v_idcust.

READ TABLE i_hier_cust INTO wa

WITH KEY nodename = v_idcust.

IF sy-subrc EQ 0.

clear : v_res.

clear : wa1.

clear : wa2.

clear : wa3.

CASE wa-tlevel.

WHEN '5'.

READ TABLE i_hier_cust INTO wa1

WITH KEY nodeid = wa-parentid.

MOVE wa1-nodename to v_res.

move v_res+8(10) to wa_RESULT_PACKAGE-/BIC/ZCLIHIER3.

READ TABLE i_hier_cust INTO wa2

WITH KEY nodeid = wa1-parentid.

MOVE wa2-nodename to v_res.

move v_res+8(10) to wa_RESULT_PACKAGE-/BIC/ZCLIHIER2.

READ TABLE i_hier_cust INTO wa3

WITH KEY nodeid = wa2-parentid.

MOVE wa3-nodename to v_res.

move v_res+8(10) to wa_RESULT_PACKAGE-/BIC/ZCLIHIER1.

ENDCASE.

ENDIF.

MODIFY RESULT_PACKAGE FROM wa_RESULT_PACKAGE.

ENDLOOP.

Thanks for help.

Cyril