Skip to Content
0
Former Member
Dec 20, 2006 at 12:46 PM

Transitive Attribute not working

48 Views

Hi All,

I need the characteristic 0EQUITYPE as Navigational Attribute in the IC 0PM_C01. Actually, all I need is to filter using 0EQUITYPE in a query built over the IC 0PM_C01 but 0EQUITYPE is a navigational attribute of 0EQUIPMENT that is navigational attribute of 0PM_ORDER that is a characteristic in 0PM_C01.

I'm using the Transitive Attribute approach; so far I have:

1) Created a ZPM_ORDER characteristic that has 0EQUITYPE as navigational attribute.

2) Created the InfoSource (flexible) Z_IS_ZPMORDER that has the very same structure used to feed the characteristic 0PM_ORDER.

3) Created an update rule linking Z_IS_ZPMORDER to ZPM_ORDER with the following routine:

*************************************************************************************

PROGRAM UPDATE_ROUTINE.

$$ begin of global - insert your declaration only below this line -

<b>TABLES: /BIC/CSZ_IS_ZPMORDER.</b>

  • DATA: ...

$$ end of global - insert your declaration only before this line -

FORM compute_data_field

TABLES MONITOR STRUCTURE RSMONITOR "user defined monitoring

USING COMM_STRUCTURE LIKE /BIC/CSZ_IS_ZPMORDER

RECORD_NO LIKE SY-TABIX

RECORD_ALL LIKE SY-TABIX

SOURCE_SYSTEM LIKE RSUPDSIMULH-LOGSYS

CHANGING RESULT LIKE /BIC/MZPM_ORDER-EQUITYPE

RETURNCODE LIKE SY-SUBRC

ABORT LIKE SY-SUBRC. "set ABORT <> 0 to cancel update

*

$$ begin of routine - insert your code only below this line -

  • fill the internal table "MONITOR", to make monitor entries

  • result value of the routine

<b> SELECT SINGLE EQUITYPE FROM /BI0/MEQUIPMENT INTO

RESULT WHERE EQUIPMENT EQ /BIC/CSZ_IS_ZPMORDER-EQUIPMENT.</b>

  • if the returncode is not equal zero, the result will not be updated

RETURNCODE = 0.

  • if abort is not equal zero, the update process will be canceled

ABORT = 0.

$$ end of routine - insert your code only before this line -

*

ENDFORM.

*******************************************************************************************

Unfortunately, the expected data is not coming through and the characteristic ZPM_ORDER is not being updated.

What am I doing wrong?

Thank you very much,

Claudiomar