cancel
Showing results for 
Search instead for 
Did you mean: 

SWEC - Key for change doc. object and business object type are incompatible

Former Member
0 Kudos

Hi,

I am trying to use change document in workflow to trigger custom event of busines object upon change/creation of certain fields for vendor master. The design approach is that create change object, define the table/specific fields , link this to busines object and event so that when the specific fields are changed this event is triggered. then link the workflow template to this event

steps:

(to trigger workflow when LFBK-BANKN is changed or when new vendor is created)

- SCDO : a new entry is created called ZTEST. it is generated. only table name is given here LFBK. nothing else is given

- SWED : check that this new entry is seen in SWED. Check mark Action Create and Action Change columns

- SWEC : click on New Entries button and business object LFB1 and change document object ZTEST is given

Following message is seen :

Key for change doc. object ZTEST and business object type LFB1 are incompatible

Diagnosis

The key structure between the change document and the business object

type were checked for consistency. It was determined that the key with

which the change document object ZTEST was constructed does not

correspond to the key for business object type LFA1.

Procedure

Check your input.

You can use the object type you have entered in spite of this warning if

there is a function module in the corresponding system table (maintained

via transaction SWED) which "translates" the key for the change document

into the object key.

Am I using the wrong busines object ??

should I give other table name in SCDO ?

have I missed any steps in creating the change object ?

how can I 'translate' the key of change document to object key ?

thank you for any inputs

B

Accepted Solutions (1)

Accepted Solutions (1)

suresh_subramanian2
Active Contributor
0 Kudos

Hello !

Create the event "created" and "changed" in the subtype of LFA1 and delegate it.

Configure the event created and changed in SWEC by choosing "On create" and "On Change" radio button.

Change document for vendor master is KRED.

Regards,

S.Suresh

bhakti2
Active Participant
0 Kudos

thank you, KRED worked.

bhakti2
Active Participant
0 Kudos

Hello Suresh,

After implementing KRED, in the testing phase we have realised that the KRED is not working for bank data for vendor (LFBK-BANKS, BANKN, BANKL) Though it is available in the condition editor for KRED while configurign in SWEC, it does not capture the creation of bank data for vendor.

I have tried to configure separate event for 'on create' scenario bcoz putting bank data in vendor would be creating data in LFBK but it doesnt help.

Kindly advice

any inputs will do

thank you v much

Bhakti

Answers (3)

Answers (3)

bhakti2
Active Participant
0 Kudos

worked with 'KEY' field name in field restriction part of SWEC, giving * in old and new value

this triggered change event if LFBK key was changed

but again there were issues so dropped the approach

checked for change pointer tables in check function module and acheived the functionality

bhakti2
Active Participant
0 Kudos

KRED worked, but not for LFBK data...... kindly help......

Eddie_Morris
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi

If you still need to translate the object key there is an option to create a custom function and insert it in SWED. Use function template function SWE_CD_TEMPLATE_EVENT_FB_2 which has the correct interface and add you code to translate in order to make the key compatible.

If you look at some of the function modules that are already in SWED you will see what interface and code is needed. e.g. functions CJPN_BUS_2001_2054_OBJECT_KEY, CO_VB_CHDOC_BUS_OBJECT_KEY.

Regards,

Eddie

chandramohan_ak
Explorer
0 Kudos

Hey check this link.