Simultaneous change documents only triggering one event
Workflow99@aol.com
Workflow99 at aol.com
Fri Oct 1 12:47:05 EDT 2004
Hi Partha,
1) Yes. You would actually enter the FM name in SWEC for the event that is
getting triggered.
2) Try the template SWE_CD_TEMPLATE_EVENT_FB.
3) One change document is associated with one object key. The CDHDR and
CDPOS records for that key are available to you in the FM as well as the event
that triggered the execution of the FM. You can examine the changes and decide
to either raise or not raise the event. If you delete the event from the int.
table no event is triggered. On the other hand you can populate the events
int. table with any other events you want to trigger for the same object key.
4) I am not sure if it is a good idea to explicitly raise events from within
this FM. If you have to do it, make sure you use the update task version of
SWE_EVENT_CREATE. All the parameters for SWE_CD_TEMPLATE_EVENT_FB or optional
and are populated by SAP. Your code can examine the changes, make DB reads
and decide what events to raise.
Regards,
Ramki Maley
Workflow Developer, USCBP.
248-613-1287 (C)
In a message dated 9/30/2004 5:32:40 PM Eastern Standard Time,
pchatterjee at deloitte.com writes:
Hi Ramki,
A few follow-up questions:
1) I assume I am to enter a z-version of SWE_CD_TEMPLATE_EVENT_FB_2
under t-code SWED to enable this functionality?
2) When I enter a z-version of this, SAP insists on OBJECTKEY being part
of its interface even though this is not part of the interface being
delivered in the template FM. SWED will not save unless I put this in
so I am a little in the dark as to what the 'Structure' field in SWED is
being used for.
3) If I use a z-version of this in SWED, and I pass out multiple
OBJECTKEY/EVENT will multiple events be raised from SAP?
4) Is the idea in using a z-version of SWE_CD_TEMPLATE_EVENT_FB_2 to
pass out multiple EVENTS/CHANGEDOCUMENT_POSITION values that then gets
interpreted by SAP to raise events? And if so, then why is SAP asking
for OBJECTKEY as part of the interface in SWED? Or am I supposed to use
this function module to call events using SWE_EVENT_CREATE?
If there is additional documentation you can point me to as how these
function modules are interpreted by SAP I would appreciate it.
With regards,
Partha Chatterjee
-----Original Message-----
From: SAP Workflow [mailto:Owner-SAP-WUG at MITVMA.MIT.EDU] On Behalf Of
Workflow99 at aol.com
Sent: Thursday, September 30, 2004 3:27 AM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Re: Simultaneous change documents only triggering one event
Hi Partha,
I do trigger multiple events for the same change document number. In my
case
the object is ANLA and change could be in any of the tables associated
with
it (ANLA, ANLB, ANLC, ANLU, ANLZ etc).You can still use the event FM to
get
the the results you need (see FM SWE_CD_TEMPLATE_EVENT_FB_2).
Regards,
Ramki Maley
Workflow Developer, USCBP.
248-613-1287 (C)
In a message dated 9/29/2004 8:03:20 PM Eastern Standard Time,
pchatterjee at deloitte.com writes:
Hi Ramki,
The problem is not multiple events on a single change document
object--I
already have that and that functions correctly.
The problem is I need multiple events triggered simultaneously from the
same change document number. In my case, I have multiple entries for
the same change document number (different table keys for each entry)
in
CDHDR table. SAP is kicking off an event for the first record in a
single change document but ignoring the others since the other entries
do not have their own change document number but rather just their own
unique tabkey entry under the same change document number.
I suspect this functionality is as intended by SAP but I need some way
of working around it if there is not configuration to change the
functionality.
With regards,
Partha Chatterjee
-----Original Message-----
From: SAP Workflow [mailto:Owner-SAP-WUG at MITVMA.MIT.EDU] On Behalf Of
Workflow99 at aol.com
Sent: Wednesday, September 29, 2004 12:13 PM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Re: Simultaneous change documents only triggering one event
Hi Partha,
I have multiple events defined on a single change document object and
all my
events trigger correctly (R/3 6.20). One option is to write an event
function
module for the triggered event and control the triggering of the second
event from there.
Regards,
Ramki Maley
Workflow Developer, USCBP.
248-613-1287 (C)
In a message dated 9/29/2004 2:58:23 PM Eastern Standard Time,
pchatterjee at deloitte.com writes:
Hi All,
I have change documents to trigger workflows in the EHS area. They
work
fine, however, when I save 2 records at the same time and they create
2
simultaneous change documents (same change document number but
different
table keys) they only trigger one of the 2 necessary events.
I would expect to see 2 events raised but I only see one. I have
turned
on the Event Queue and it only sees one event as well.
I can think of a workaround where I can use the event that does
trigger
to start the workflow and then have a background step that checks if a
second (third, fourth etc.)workflow should be started but I would
prefer
to change the problem at the source.
Any ideas?
Thanks,
Partha Chatterjee
Regards,
Ramki Maley
Workflow Developer, USCBP.
248-613-1287 (C)
More information about the SAP-WUG
mailing list