WF-BATCH

Srinivasan Ramanan r_m_n_n at hotmail.com
Tue Nov 8 12:15:16 EST 2005


Hi ,
In this case WF_initiator is WF-BATCH itself since this BAPI is called in 
the background...
Try the following in foreground...
Please check by debugging the BAPI by putting break point before calling the 
BAPI...and check the values sy-uname , uname and  t_BAPIHR1005-CHANGED_BY.

then in the workflow log check who is WF_initiator.

I guess both uname and wf_initiaor will be fore-ground SAP user name.

if that is the case then try submitting a job in the back ground where you 
could choose user name in setp of the job...any way you are running this in 
background...

best of luck
Srinivasan


>From: "Josie Henriques" <jhenriques_procwork at timbrasil.com.br>
>Reply-To: "SAP Workflow Users' Group" <sap-wug at mit.edu>
>To: "SAP Workflow Users' Group" <sap-wug at mit.edu>
>Subject: RE: WF-BATCH
>Date: Tue, 8 Nov 2005 13:54:37 -0200
>
>  This BAPI is called in background .
>
>       t_BAPIHR1005-CLIENT            = sy-mandt.
>       t_BAPIHR1005-PLAN_VER          = plvar.
>       t_BAPIHR1005-OBJ_TYPE          = otype.
>       t_BAPIHR1005-OBJ_ID            = objid.
>       t_BAPIHR1005-INFOTYPE          = '1005'.
>       t_BAPIHR1005-PL_STATUS         = istat.
>       t_BAPIHR1005-FROM_DATE         = BEGDA.
>       t_BAPIHR1005-TO_DATE           = ENDDA.
>       t_BAPIHR1005-IT_REC_NO         = i1005-seqnr.
>       t_BAPIHR1005-CHANGED_ON        = aedtm.
>       t_BAPIHR1005-CHANGED_BY        = uname.
>       t_BAPIHR1005-COUNTRY_GROUPING  = i1005-molga.
>       t_BAPIHR1005-TYPE              = i1005-trfar.
>       t_BAPIHR1005-AREA              = v_trfgb.
>       t_BAPIHR1005-ESGFORCAP         = i1005-trfkz.
>       t_BAPIHR1005-LOWEST_GROUP      = i1005-trfg1.
>       t_BAPIHR1005-HIGHEST_GROUP     = i1005-trfg2.
>       t_BAPIHR1005-LOWEST_LEVEL      = i1005-trfs1.
>       t_BAPIHR1005-HIGHEST_LEVEL     = i1005-trfs2.
>       t_BAPIHR1005-COMP_FROM         = i1005-budg1.
>       t_BAPIHR1005-COMP_TO           = i1005-budg2.
>       t_BAPIHR1005-MEAN_VALUE        = i1005-midpt.
>       t_BAPIHR1005-PLANNED_COMP_TYPE = i1005-CPIND.
>       append t_BAPIHR1005.
>
>     Uname has the WF_intiator.
>
>Josie Henriques
>
>-----Original Message-----
>From: sap-wug-bounces at mit.edu [mailto:sap-wug-bounces at mit.edu] On Behalf Of 
>Srinivasan Ramanan
>Sent: terça-feira, 8 de novembro de 2005 11:50
>To: sap-wug at mit.edu
>Subject: RE: WF-BATCH
>
>If a BAPI function is called and executed by user WF-BATCH then you will
>have WF-BATCH as the user who created the object in SAP tables..
>
>You can use WF-BATCH to schedule and run a background job....but those jobs
>which are part of workflow should run under the autorization of the user 
>who
>actually execute the work item, not of wF-BATCH...
>
>In otehr words ..
>Job created by WF-BATCH
>Job run under authorization of user ---work item executor , in your case
>WF_intiator..
>What field in which BAPI structure you are filling the actual user name
>instead of WF-BATCH ?
>Are you executing this BAPI call in dialog or background ?
>
>Srinivasan
>
>
>_______________________________________________
>SAP-WUG mailing list
>SAP-WUG at mit.edu
>http://mailman.mit.edu/mailman/listinfo/sap-wug

_________________________________________________________________
Is your PC infected? Get a FREE online computer virus scan from McAfee® 
Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963



More information about the SAP-WUG mailing list