Check FM issues 4.6c

Sheldon Oxenberg soxenber at csc.com
Thu Jan 10 13:06:39 EST 2008


One option is to use SAP Function Module ENQUE_SLEEP:

  CALL FUNCTION 'ENQUE_SLEEP'
       EXPORTING
            SECONDS = 30.

Regards,
Sheldon C. Oxenberg

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
Registered in USA No: C-489-59

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------




                                                                           
             "Sample, Rick"                                                
             <Rick.Sample at gbe.                                             
             com>                                                       To 
             Sent by:                  "SAP Workflow Users' Group"         
             sap-wug-bounces at m         <sap-wug at mit.edu>                   
             it.edu                                                     cc 
                                                                           
                                                                   Subject 
             01/10/2008 10:58          RE: Check FM issues 4.6c            
             AM                                                            
                                                                           
                                                                           
             Please respond to                                             
               "SAP Workflow                                               
               Users' Group"                                               
             <sap-wug at mit.edu>                                             
                                                                           
                                                                           




I hear what you are saying, but we still end up with two  WFs.  One
will just be terminated before anything happens.

I know we can not put a WAIT UP TO x SECONDS in CFM.
But any other way to know of to pause one of the two CASEs?

That is, if RELEASESTEPCREATED, no pause.
If CHANGED, pause for a few seconds ( giving RELEASESTEPCREATED case to
start WF) and then
I read swwwihead to see if I already have a WF started.


-----Original Message-----
From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf
Of Sheldon Oxenberg
Sent: Thursday, January 10, 2008 9:04 AM
To: SAP Workflow Users' Group
Subject: RE: Check FM issues 4.6c

Rick,

If you know that this case results in two workflows within a short
period
of time, you could use an initial WAIT Step (background method with
ENQUEUE_SLEEP) to place the workflow on hold before processing, and have
a
TERMINATING EVENT for that workflow, so that when the other event
occurs,
this will TERMINATE the workflow that is in the WAIT Step, and start the
new workflow.

In this way, the first workflow never really tried to do anything, was
then
terminated, and you get your second workflow to do the real processing?

Havin fun,
Sheldon C. Oxenberg

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
Registered in USA No: C-489-59

------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC
to
any order or other contract unless pursuant to explicit written
agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------






             "Sample, Rick"

             <Rick.Sample at gbe.

             com>
To
             Sent by:                  "SAP Workflow Users' Group"

             sap-wug-bounces at m         <sap-wug at mit.edu>

             it.edu
cc



Subject
             01/10/2008 09:37          RE: Check FM issues 4.6c

             AM





             Please respond to

               "SAP Workflow

               Users' Group"

             <sap-wug at mit.edu>









Starting two WFs and kill the other is workable, but not desirable.

I made the lookup in the CDPOS 'work', but in my experience that has
always cause problems
with starting WF via events by reading change tables.
That FM I hung off the SWEC EINKBELEG-BUS2012-CHANGED.

I am looking at EXITS right now and put out a customer service message
to SAP. Maybe they got something obvious I am missing.

Thanks
Rick


-----Original Message-----
From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf
Of Sheldon Oxenberg
Sent: Thursday, January 10, 2008 7:59 AM
To: SAP Workflow Users' Group
Subject: RE: Check FM issues 4.6c

One option is to place a FORK Step and then a parallel WAIT FOR EVENT
Step
and TERMINATE WORKFLOW Step in the workflow.

When the second event is detected by the WAIT FOR EVENT Step, that first
instance of the workflow will be TERMINATED.  Then the second replicate
instance of the workflow will be STARTED.

Regards,
Sheldon C. Oxenberg

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
Registered in USA No: C-489-59

------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC
to
any order or other contract unless pursuant to explicit written
agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------






             "Sample, Rick"

             <Rick.Sample at gbe.

             com>
To
             Sent by:                  "SAP Workflow Users' Group"

             sap-wug-bounces at m         <sap-wug at mit.edu>

             it.edu
cc



Subject
             01/09/2008 02:46          RE: Check FM issues 4.6c

             PM





             Please respond to

               "SAP Workflow

               Users' Group"

             <sap-wug at mit.edu>









Entry in SWEC for RELEASESTEPCREATED has already been removed before
this adventure started.

1. I could go look at the CDPOS from CFM and get the last change.
    But I hate going to change tables due to performance. (especially
with events!)
2. I could create a separate task and hang that on the change event. In
Task, wait one minute,
     then check if WF exists bla, bla, bla.
     Ugly, but would work.

I don't like either one. Surely there must be a more elegant way to
handle this situation. Eh?

Rick Sample
SAP Business Workflow Developer
Graybar, Inc.

-----Original Message-----
From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf
Of Sheldon Oxenberg
Sent: Tuesday, January 08, 2008 11:57 AM
To: SAP Workflow Users' Group
Subject: RE: Check FM issues 4.6c

There is a manual implementation part to SAP Note 797775, which is not
automatic with the srv pack.
In Transaction SWEC, delete the row with the following entry: EINKBELEG
->
BUS2012 -> RELEASESTEPCREATED.
Could you check your Transaction SWEC to see if this entry exists?

Regards,
Sheldon C. Oxenberg

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
Registered in USA No: C-489-59

------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC
to
any order or other contract unless pursuant to explicit written
agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------






             "Sample, Rick"

             <Rick.Sample at gbe.

             com>
To
             Sent by:                  "SAP Workflow Users' Group"

             sap-wug-bounces at m         <sap-wug at mit.edu>

             it.edu
cc



Subject
             01/08/2008 12:05          RE: Check FM issues 4.6c

             PM





             Please respond to

               "SAP Workflow

               Users' Group"

             <sap-wug at mit.edu>









We have that note in for we are at srv pack 50.

I need to start a new WF for event bus2012.RELEASESTEPCREATED and
I need to start a new WF for event bus2012.CHANGED.

If new PO, bus2012.RELEASESTEPCREATED is triggering.
For my situation, a user in the approval process may reject the PO and
need to send
back to creator for changes. So, I have to reset the Release Strategy,
send back to creator,
and allow changes. Now, if his changes do not effect the org Release
Strategy, no problem. Just the
change event triggers and all is fine.

If user makes changes to PO AND these changes effect release strategy, I
get both events triggering
causing me two WFs.

Any other suggestions?

Rick



-----Original Message-----
From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf
Of Sheldon Oxenberg
Sent: Monday, January 07, 2008 5:16 PM
To: SAP Workflow Users' Group
Subject: Re: Check FM issues 4.6c

We had a similar problem in 4.6c.  Maybe you could see if SAP Note
797775
is helpful to your issue.

Regards,
Sheldon C. Oxenberg

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
Registered in USA No: C-489-59

------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC
to
any order or other contract unless pursuant to explicit written
agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
------------------------------------------------------------------------
------------------------------------------------------------------------
----------------------------------------------------------------






             "Sample, Rick"

             <Rick.Sample at gbe.

             com>
To
             Sent by:                  "Sample, Rick"

             sap-wug-bounces at m         <Rick.Sample at gbe.com>, "SAP

             it.edu                    Workflow Users' Group"

                                       <sap-wug at mit.edu>


cc
             01/07/2008 05:05

             PM
Subject
                                       Check FM issues 4.6c



             Please respond to

               "SAP Workflow

               Users' Group"

             <sap-wug at mit.edu>









I need to start a WF for events bus2012.RELEASESTEPCREATED or
bus2012.CHANGED.

I am having a problem because both events trigger at the same time.
So a simple check to see if a WF already is running is not working.

I know there is a solution, but it is eluding me at the moment...

Basic code:
...
    WHEN 'RELEASESTEPCREATED' or 'CHANGED'.

      SELECT a~wi_id b~wi_stat INTO TABLE t_wi_id
         FROM sww_contob AS a INNER JOIN swwwihead AS b
         ON a~wi_id = b~wi_id
         WHERE a~objtype    = l_obj
         AND   a~objkey     = l_doc
         AND   b~wi_rh_task = 'WS99999999'.
      LOOP AT t_wi_id.
        CASE t_wi_id-status.
          WHEN 'WAITING'.
            RAISE workflow_off.
            EXIT.
          WHEN 'READY'.
            RAISE workflow_off.
            EXIT.
          WHEN 'SELECTED'.
            RAISE workflow_off.
            EXIT.
          WHEN 'STARTED'.
            RAISE workflow_off.
            EXIT.
          WHEN OTHERS.
        ENDCASE.
      ENDLOOP.
...


_______________________________________________
SAP-WUG mailing list
SAP-WUG at mit.edu
http://mailman.mit.edu/mailman/listinfo/sap-wug





More information about the SAP-WUG mailing list