Workflow container gets updated with values when we trigger event synchronously only not for TRFC?

Ravi Dixit dolbydix at gmail.com
Tue Jan 26 18:39:26 EST 2010


Hi Arghadip

We are ready to "throw some light" only if you can explain the issue you
face, in simple English. From what I could follow, you may not be passing
the required parameters...

Cheers
Ravi

On Wed, Jan 27, 2010 at 8:37 AM, <sap-wug-request at mit.edu> wrote:

> Send SAP-WUG mailing list submissions to
>        sap-wug at mit.edu
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://mailman.mit.edu/mailman/listinfo/sap-wug
> or, via email, send a message with subject or body 'help' to
>        sap-wug-request at mit.edu
>
> You can reach the person managing the list at
>        sap-wug-owner at mit.edu
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of SAP-WUG digest..."
>
>
> Today's Topics:
>
>   1. Workflow container gets updated with values when we trigger
>      event     synchronously only not for TRFC? (arghadip kar)
>   2. RE: AW: AW: Getting current agent (name) from workflow work
>      item (Shoaib Mirza)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Tue, 26 Jan 2010 11:54:49 -0800 (PST)
> From: arghadip kar <arghadipkar at yahoo.com>
> Subject: Workflow container gets updated with values when we trigger
>        event   synchronously only not for TRFC?
> To: sap-wug at mit.edu
> Message-ID: <518726.67982.qm at web50308.mail.re2.yahoo.com>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi All
>
> The workflow gets triggered with all the container element getting properly
> updated if I Trigger the event from Tcode SWUE with Trigger FM Synchronously
> Checked. I further debugged and found this FM gets called when I select this
> flag.
> ?CALL FUNCTION im_handler->m_linkage-recfb
> ????? DESTINATION im_handler->m_linkage-rfcdest
> ????? EXPORTING
> ?????????? objtype??????????? = l_bor_objtype
> ?????????? objkey???????????? = l_bor_objkey
> ?????????? event????????????? = l_bor_event
> ?????????? rectype??????????? = l_bor_rectype
> ?????????? exceptions_allowed = 'X'
> ????? IMPORTING
> ?????????? rec_id???????????? = l_receiver_id
> ????? TABLES
> ?????????? event_container??? = lt_event_container
> ????? EXCEPTIONS
> ?????????? temp_error???????? = 1
> ?????????? OTHERS???????????? = 99.? " catch all exceptions
> When I Uncheck this Flag this FM gets called in background.
> ????? CALL FUNCTION im_handler->m_linkage-recfb
> ?????????? IN BACKGROUND TASK
> ?????????? AS SEPARATE UNIT
> ?????????? DESTINATION im_handler->m_linkage-rfcdest
> ?????????? EXPORTING
> ??????????????? objtype??????????? = l_bor_objtype
> ??????????????? objkey???????????? = l_bor_objkey
> ??????????????? event????????????? = l_bor_event
> ??????????????? rectype??????????? = l_bor_rectype
> ??????????????? exceptions_allowed = space
> ?????????? TABLES
> ??????????????? event_container??? = lt_event_container.
> ????? CALL FUNCTION 'ID_OF_BACKGROUNDTASK'
> ?????????? IMPORTING
> ??????????????? tid = l_trfc_id.
> When we trigger this event synchronously it gets triggered Under the user
> Id who runs SWUE tcode. For not synchronous it gets triggered with WF-BATCH.
> WF-BATCH has SAP_ALL and SAP_NEW Authorization. The workflow gets
> triggered(for not synchronous) after sometime without the container element
> getting populated after giving a RFC Status as *System overloaded, repeat
> immediately by batch*. When i Trigger the event synchronously we have no RFC
> Status.In standard event gets triggered through TRFC and not through
> synchronous.
> Can you please throw some light on what is the issue.
>
> Thanks
>
> Arghadip Kar
>
> SAP Workflow Expert
>
> IBM INDIA
>
>
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://mailman.mit.edu/pipermail/sap-wug/attachments/20100126/101952a3/attachment-0001.htm
>
> ------------------------------
>
> Message: 2
> Date: Tue, 26 Jan 2010 21:37:21 +0000
> From: Shoaib Mirza <shoaib_mirza at hotmail.com>
> Subject: RE: AW: AW: Getting current agent (name) from workflow work
>        item
> To: <sap-wug at mit.edu>
> Message-ID: <COL123-W327A4BDEEF9779683E025CE35E0 at phx.gbl>
> Content-Type: text/plain; charset="windows-1252"
>
>
>
>
> Hi
>
>
>
> This doesn't seem to work, or are we missing something in the code.
>
> This gives the details of the top level workflow item.  I can not see the
> latest work item being processed in the workflow.
>
>
>
> Any ideas how to get this information?
>
>
>
> Thanks
>
> Sunni
>
>
>
> From: Benjamin.Koeb at comlineag.de
> To: sap-wug at mit.edu
> Date: Tue, 26 Jan 2010 20:22:00 +0100
> Subject: AW: AW: Getting current agent (name) from workflow work item
>
>
>
>
>
>
>
> Hi Sunni,
>
> that?s no problem, if you have the ?top? workitem, just select swwwihead
> with ?where?-clause:  WI_CHCKWI = your_top_wi_id
> Try this select statement:
>  SELECT SINGLE * FROM SWWWIHEAD into wa_SWWWIHEAD
>    WHERE WI_CHCKWI = lv_top_wi_id
>    AND wi_type = 'W'
>    AND ( WI_STAT = 'READY' or WI_STAT = 'STARTED' ).
> You should get the actual workitem, with this information you can call the
> function module.
>
> Hope that helps?
>
> Benny
>
>
>
> Von: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] Im Auftrag
> von Shoaib Mirza
> Gesendet: Dienstag, 26. Januar 2010 18:17
> An: sap-wug at mit.edu
> Betreff: RE: AW: Getting current agent (name) from workflow work item
>
> Hi
>
> Thanks for that, but my issue is that I don't have the work item id of the
> current task.  I only have the 'top' work item id of the workflow.  That
> does not have any agents.
>
> So I need to go down the workflow to the final workitem and get the agents
> from that.  (Maybe then I can use the function below to get the agents)
>
> Any ideas how I can do that.
>
> Kind Regards
> Sunni
>
>
>
>
> From: Benjamin.Koeb at comlineag.de
> To: sap-wug at mit.edu
> Date: Tue, 26 Jan 2010 17:51:09 +0100
> Subject: AW: Getting current agent (name) from workflow work item
>
> Hi Sunni,
>
> you can read the actual (Workitem status = started) agent from table
> SWWWIHEAD-WI_AAGENT with key = WI_ID. This works fine for workitems with
> status = started, if the status = ready the field wi_aagent is empty! For
> workitems with status ready, try to use function module
> SAP_WAPI_WORKITEM_RECIPIENTS:
>
> CALL FUNCTION 'SAP_WAPI_WORKITEM_RECIPIENTS'
>        EXPORTING
>          workitem_id                = lv_wi_id
>        tables
>          recipients                 = it_recipients.
>
> That?s my way, maybe there are better ones?
>
> Regards,
>
> Benny
>
>
>
> Von: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] Im Auftrag
> von Shoaib Mirza
> Gesendet: Dienstag, 26. Januar 2010 17:37
> An: sap-wug at mit.edu
> Betreff: Getting current agent (name) from workflow work item
>
> Hi
>
> Please can you let me know how I would go about getting the current agent
> of a workflow from the workitem id of the workflow.  I looked for a wapi but
> could not find one suitable.
>
> Kindest Regards
> Sunni
>
>
>
> Do you have a story that started on Hotmail? Tell us now
>
>
>
>
> Got a cool Hotmail story? Tell us now
> _________________________________________________________________
> We want to hear all your funny, exciting and crazy Hotmail stories. Tell us
> now
> http://clk.atdmt.com/UKM/go/195013117/direct/01/
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL:
> http://mailman.mit.edu/pipermail/sap-wug/attachments/20100126/53d368da/attachment.htm
>
> ------------------------------
>
> _______________________________________________
> SAP-WUG mailing list
> SAP-WUG at mit.edu
> http://mailman.mit.edu/mailman/listinfo/sap-wug
>
>
> End of SAP-WUG Digest, Vol 62, Issue 61
> ***************************************
>



-- 
Best Regards
Ravi Dixit
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/sap-wug/attachments/20100127/d5cb6cbf/attachment.htm


More information about the SAP-WUG mailing list