Starting workflow from a program

Zmudzin,Tomasz,VEVEY,GL-DS/DM Tomasz.Zmudzin at nestle.com
Wed Oct 9 08:30:00 EDT 2002


In other words -- you need to insert that COMMIT WORK after your call =
to
SWE_EVENT_CREATE, because this call (indirectly) updates the database. =
Then
it will work.
 
Kind regards,
Tomasz
 
P.S. In perhaps 80% of cases you don't need that COMMIT WORK because =
the
SWE_EVENT_CREATE call is placed in a program that will commit anyway =
when
saving data. In such cases you actually need to be very careful; coding =
your
own COMMIT WORK after raising the event could break the transaction =
logic.
But this is obviously not the case in your case...
 
-----Original Message-----
From: Becker Stephan (extern)
[mailto:Stephan.Becker.ext at mchw.siemens.de]
Sent: Wednesday,9. October 2002 13:54
To: SAP-WUG at MITVMA.MIT.EDU
Subject: AW: Starting workflow from a program
 
 
the starting of the workflow is a logical unit of work, contains db =
updates,
and therefore needs a commit work..=20
 
-----Urspr=FCngliche Nachricht-----
Von: Jose Burgman [AST] [mailto:jose.burgman at ast.co.za]
Gesendet: Mittwoch, 9. Oktober 2002 13:47
An: SAP-WUG at MITVMA.MIT.EDU
Betreff: Re: Starting workflow from a program
 
 
Hi there
 
No. I'm not doing any database updates.
 
Jose
 
-----Original Message-----
From: Zmudzin,Tomasz,VEVEY,GL-DS/DM [mailto:Tomasz.Zmudzin at nestle.com]
Sent: Wednesday, October 09, 2002 1:37 PM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Re: Starting workflow from a program
 
 
Just to make sure -- do you COMMIT WORK after the call?
 
Kind regards,
Tomasz
 
-----Original Message-----
From: Jose Burgman [AST] [mailto:jose.burgman at ast.co.za]
Sent: Wednesday,9. October 2002 12:23
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Starting workflow from a program
 
 
Hi every-one
 
I've created a dialogue program in which one of the facilities the user =
has
is to start a workflow. I've created the subtype ZKNA1 (with status
released) with an event called ZAPPROVE and delegated it system wide to
KNA1. The event has a multiline element. I've created the event =
container
and initialised it and loaded my internal table into the event =
container
using the relevant macros. I then call the FM SWE_EVENT_CREATE. The
interface needs the object type (tried KNA1 and then ZKNA1 - used =
literal),
the object key (customer number - used FM definition) and the event
(ZAPPROVE - used literal) and pass the event container. The workflow is
active and the event linkage is in place (checked using SWETYPV). When =
I
execute the program nothing happens - no event is triggered in swel. =
I've
run it in debug mode and everything _SEEMS_ to be OK in the FM - return =
code
is 0 when it completes - I've also tested it using SE37 and the event
container does get filled - but still no event trigger.
 
So ... any-one have any ideas?
 
Regards
 
Jose
______________________________________________
 
"This information is intended only for the person or entity to which it =
is
addressed and
may contain private, confidential, proprietary and/or privileged =
material
and may be subject
to confidentiality agreements.
 
Any review, retransmission, dissemination, or any other use of or =
taking of
any action in
reliance upon this information, by persons or entities other than the
intended recipient,
is prohibited.
 
If you received this in error, please contact the sender and delete the
material from all
storage media.
 
The company is neither liable for proper, complete transmission of the
information contained
in this communication, any delay in its receipt or that the mail is
virus-free"
______________________________________________
 
"This information is intended only for the person or entity to which it =
is
addressed and
may contain private, confidential, proprietary and/or privileged =
material
and may be subject
to confidentiality agreements.
 
Any review, retransmission, dissemination, or any other use of or =
taking of
any action in
reliance upon this information, by persons or entities other than the
intended recipient,
is prohibited.
 
If you received this in error, please contact the sender and delete the
material from all
storage media.
 
The company is neither liable for proper, complete transmission of the
information contained
in this communication, any delay in its receipt or that the mail is
virus-free"
 


More information about the SAP-WUG mailing list