on 09-20-2010 5:02 PM
hi
If there is one feed from sap ,we can insert or update database records(if not already inserted then update). but can we delete also ? or a separate interface is needed for deletion of a record in the database table?
Thanks
1..N mapping(with out BPM) would solve the issue. Just use multiple message types. One for Insert/update and the other one for delete. In the mapping choose which message you need to populate. You need both the message types as your target messages with occurance set to0..1 for both.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi.
You can use INSERT, UPDATE, DELETE and others.
Follow the HELP SAP link about it:
Defining XML Documents for Message Protocol XML SQL Format
http://help.sap.com/saphelp_nwpi711/helpdata/en/2e/96fd3f2d14e869e10000000a155106/frameset.htm
Regards
Bruno
Thats fine, i understand we can do all these operations.
I have a single feed and the action is one of the fields in the source structure ( action : update_insert or Delete)
but my question is as we know update_insert : it updates if not already inserted.but can we do all operations in one interface: i imply even the delete. If so how ?
one solution could be to send the flag : DELETE also from the source side and do a map that if action = delete then do some logic. I wanted to understand this logic: whether we need to create another statement node or access ?
Thanks
Hi.
Yes, it's possible!
You can use MULTI-MAPPING and your conditions will be in the message mapping (whether it is a UPDATE_INSERT statement or it is a DELETE statement).
Multi-Mapping without BPM - Yes, itu2019s possible!
/people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
Regards.
Bruno
> one solution could be to send the flag : DELETE also from the source side and do a map that if action = delete then do some logic. I wanted to understand this logic: whether we need to create another statement node or access ?
You need another statement.
You can have different statements with different actions or different tables in one XI message.
Statement node is mapped to the repeating segment from the source structure.
action is coming as a separate field from the source structure since insert and updates can be implicitly done with the key logic but deletes have to be explicitly specified from the source field whether a particular record needs to be deleted.
So suppose a flag on source structure comes as DELETE, so another receiving structure statement node needs to be created since table for insert or update or delete is the same , just the action is different and action is coming as a flag from the source structure?
what is the mapping logic we need to put at Statement level for creating this conditional create?
Thanks
Edited by: sap_logic on Sep 20, 2010 9:54 PM
Hi,
You can control the generation of the DELETE structure at its statement level.
Check the Source field for Delete flag and based on that create the statement or suppress the statement of delete.
Use ifWithoutElse mapping function for this.
-Supriya.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
At action level also this can be controlled.
If source field has delete flag set , in action map it to Constant (DELETE) else map it to action to UPDATE_INSERT.
IF then else could be used. I tried it works well.
At statement level i am mapping the source segment which is repeating.
IS this logic also correct?
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.