ABAP in Process Chains

I am trying to run an ABAP from a process chain and need some of the information from the process chain itself.  The documentation on ABAPs in process chains includes the following:
Using the Program variant you can transfer the Process variant to the program at the time of scheduling. Input the Process variant as a value for the Program variant and add the following lines to your program:
PARAMETERS variant TYPE rspc_variant.
The system exports the technical name of the latest process chain, as well as the dynamic parameter Instance and Log ID in the shared buffer.To receive this parameter, add the following lines to your program:
DATA: l_instance TYPE rspc_instance,
      l_logid    TYPE rspc_logid,
      l_chainid  TYPE rspc_chain.
IMPORT instance TO l_instance
       log_id   TO l_logid
       chain_id TO l_chainid
       FROM DATABASE BUFFER rspc_buffer(ab)
       ID variant.
Can anyone explain how to "Using the Program variant you can transfer the Process variant to the program at the time of scheduling. Input the Process variant as a value for the Program variant"
Thanks very much,

Hi,
We have a similar requirement where we want to pass the  values of a program into an ABAP program being used in a process chain. For e.g the Program 1 has values entered by the user and we want to make use of those values in Program 2.Program 2 is used in the process chain. Program 1 triggers a process chain. We wanted to make use of following program and we got a syntax error for the "DATABASE BUFFER" statement.
PARAMETERS variant TYPE rspc_variant.
DATA: l_instance TYPE rspc_instance,
l_logid TYPE rspc_logid,
l_chainid TYPE rspc_chain.
IMPORT instance TO l_instance
log_id TO l_logid
chain_id TO l_chainid
FROM DATABASE BUFFER rspc_buffer(ab)
ID variant.
Any help is appreciated.
Thanks.

Similar Messages

  • How to include an ABAP program in process Chain

    Hello Gurus,
    I have a situation where I have to go to SE38 and run an ABAP program which fills the active table of ODS2 by taking data from another ODS1.The data from ODS2 is again fed to another ODS3. So my question now is how do I create a process chain which takes care of this scenario.Especially include ABAP program in the process chain.Looking forward to your replies.
    Regards,
    Kalyan

    hi,
    take a look 'how to' ABAP in process chain
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/3507aa90-0201-0010-6891-d7df8c4722f7

  • Call ABAP Program in Process Chain

    Dear BW Gurus,
    I need to call an Process chain which includes ABAP Program.
    The ABAP Program doesn't have the variants but it accepts the inputs from the user and sets into a YXXXX table.
    I am not getting how to proceed in this regard.
    Kindly guide.
    Best Regards,
    Harsh

    hi,
    chk these links below.. they contain the resolution for your query
    Call ABAP Program in Process Chain
    ABAP in Process Chains
    Also chk this relase which ia an entire guiding one to ABAP Program in Process Chain
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/3507aa90-0201-0010-6891-d7df8c4722f7

  • Process chain taking long time

    Hi,
        I developed a Process chain. In developemnt for Completion of the Update rules(Start routine) its taking 60m( for around 50,000 records).
    After transporting the Process chain to Production for Start routine completion (For 1,70,000 records) its taking 7hrs and sometimes its failing as the "Process is Over due" and sometimes due to "Short dump".
    How to handle this.........
    Thanks

    Hi js,
    Check the ST22... Any dumps
    Check out for the short dump in source system and try loading the delta again
    then
    I have got the problem when u have posted...but little later.Even I was about to post the issue.. Actually my issue was...
    My PC is like this
    1) Start Process
    2) Delete index
    3) Load IP
    4) delete overlapping request
    5) create Index
    6) ABAP program
    Process chain hangs at Overlapping requests process type but the status was yellow. And the previous step (3) was success. From there its not moving to next further steps.. But the Job in SM37 was canceled.
    I saw Ur post and saw the note 833168 and which matches exactly our issue.
    Like we run the PCs thru the TIDAL where due to some problems PC got triggered twice... I can see the two logs in the PC. (Log view) and two requests at RSMO.
    Everything was recovered again thru manual steps. This is the first time we encountered... the note helped us ... We now are very cautious about the Tidal runs...
    Now PC is running perfectly
    we have instructed the Supported team to make the necessary changes or fix this issues in TIDAL...
    i hope this is helpful to u
    bye now
    suresh

  • Run process chain on last three days of the month

    Hello
    I need to run process chain on last three days of the month. For example , It should run on 28, 29 and 30th dates of June.
    There is no option to put a code in the start process of the process chain.
    I can run it every day and put a code in the infopackage/DTP so that empty load (0 records) will be done on other days.
    This doesnt sound as a good option.
    Do u know any other options?

    Hi
    See the code and details how to do it, and change the code as per your requirement.
    http://wiki.sdn.sap.com/wiki/display/profile/Surendra+Reddy
    Triggering  the Process Chains at Particular Date using Events
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/business-intelligence/s-u/triggering%20%20the%20process%20chains%20at%20particular%20date%20using%20events.pdf
    BI-ABAP (Trigger Process Chains on evry month 3rd and 4th day).
    https://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=81428842 
    Thanks
    Reddy

  • Planning a process chain from 2 to 15 every month

    Dear Gurus,
    I have created a process chain but I must plan it daily from day 2 to day 15 every month. If I check the period values to plan it I can just select: daily, weekly, monthly... but I need it to be daily but just those days.
    Can anybody help me with it?
    Many thanks!
    Regards,
    Jordi

    Hi,
    You can do it by using simple programs/events.
    See some usefull Blogs/Articles/Wiki in the following URL..
    https://wiki.sdn.sap.com/wiki/display/profile/Surendra+Reddy
    Triggering  the Process Chains at Particular Date using Events
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/business-intelligence/s-u/triggering%20%20the%20process%20chains%20at%20particular%20date%20using%20events.pdf
    BI-ABAP (Trigger Process Chains on evry month 3rd and 4th day).
    https://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=81428842 
    How to trigger the Process Chains in BW from ECC
    /people/surendrakumarreddy.koduru/blog/2009/03/18/how-to-trigger-the-process-chains-in-bw-from-ecc
    Thanks
    Reddy

  • BI-Process Chains

    hi every  body,
                 coming to the point...i want to run process chains on Monday, Wednesday and Friday in every week..Is it possible..How?
    Please reply for this question

    Hi,
    It is very much possible .....
    1. Using Events we can do it.
    2. Using simple PRogram we can do it.
    Case 1:
    http://wiki.sdn.sap.com/wiki/display/profile/Surendra+Reddy
    BI-ABAP (Trigger Process Chains on evry month 3rd and 4th day).
    https://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=81428842 
    Triggering  the Process Chains at Particular Date using Events
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/business-intelligence/s-u/triggering%20%20the%20process%20chains%20at%20particular%20date%20using%20events.pdf
    Case 2:
    For below FM give the Date and then base don that find the Day in week and if your Week day is matching with Output then Trigger the Process Chain using Events. You need to include the FM to trigger PC in this program, so read both Case 1 and Case 2 and modify the program.
    DATA:V_date type sy-datum.
    DATA:V_day(1) type c.
    v_date = sy-datum.
    CALL FUNCTION 'DATE_COMPUTE_DAY'
              EXPORTING
                DATE = V_DATE
              IMPORTING
                DAY = V_DAY.
    IF sy-subrc = 0.
    IF V_DAY GE '1' AND V_DAY LE '5'.
    MESSAGE i162(00) WITH 'Successful'.
    ELSE.
      Message e000(sabapdocu) with 'Error'.
    endif.
    Thanks
    Reddy

  • Email Alert for Process Chain for ABAP Process Type

    Hi BW Experts,
                             I created a process chain based on ABAP Process Type ( for Broadcasting rsrd_broadcast_starter). I want to add alert message for each ABAP process if it is failed. But I cant see any option showing Successfull or Error or Always when I select create message option on the process type. How ever I can see for other process chain which is loading data (Process Type is Info Package ) from SAP into BW.
                             Please some one tell me why it is not showing alert message for ABAP Process Type.
    Thanks
    Ganesh Reddy.
    Edited by: Ganesh Reddy on Jul 13, 2009 10:16 PM

    I dont have the exact answer for your question, But as a work around i can suggest you that.
    If these ABAP programs are included in a chain and this local chain is a part of meta chain then you can create a message on the local chain.By right clicking on the local chain >Create Message>Success
                                                                                    --->Failure
    >Always
    Hope this resolves the problem tempervorly.I will get back to you once i have
    Or the permanent solution is
    Its big and also easy method to perform, by this you will be able to get all the options for a ABAP Program also.If you have any questions please let me know.
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/business-intelligence/a-c/creating%20an%20abap%20process%20type%20for%20process%20chains%20in%20bi.pdf

  • GETWA_NOT_ASSIGNED error while running abap prog in process chain

    Hi.
    I am getting a runtime error GETWA_NOT_ASSIGNED while running an ABAP program in process chain.
    But when i execute pro in SE38 , it's not giving any error.
    Please any one can suggets what will be error.

    Hi,
      i also used to get error for a program executed through process chain but when it is executed in se38 it used to work... that is because my program try to access a application server folder and reads the file from there... the authorisation to this is not proper through process chain ..... once authorisation to the folder was given properly .. i am able to run...
      Such things can happen in your case also... Try to analyse the dump in st22.... what happened ...
    Regards
    vamsi

  • How to finish ABAP program in the process chains

    Hello All,
    we have one ABAP program in the process chains which was created in the BW system only.
    this program we are using in the synchronous mode. according to my understanding we can not capture the failure of the ABAP program when it is in the synchronous mode.
    but i found a way through one this forum topic to capture the failure of the program through asynchrous mode by calling a function module RSPC_ABAP_FINISH but it was with the R/3 program in BW.
    can we use the same function module for BW program also.
    kindly let me know what steps we need to follow for the BW program in the process chains to capture the failure status.
    Regards,
    Ala.

    Hi Ala,
    we created an own processtype, look at this HowTo: https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/45d8a990-0201-0010-a290-f22083728179
    and than also an abap which can end red or green:
    PARAMETERS: red   RADIOBUTTON GROUP radi,
                green RADIOBUTTON GROUP radi.
    IF NOT green IS INITIAL.
      MESSAGE i162(00) WITH 'Status' 'Green'.
    ELSE.
      MESSAGE e162(00) WITH 'Status' 'Red'.
    ENDIF.
    with i-message process ends green, with e-message process ends red.
    /manfred

  • Process Type ABAP does not work properly via process chain

    Dear SDNers
    I am running a process chain and it contains process type ABAP program. ABAP program was running correctly till now via this process chain. ABAP program process type generally takes approximately 2 hours to run. But now, this process type for ABAP program just run for less than 1 minute and finishes successfully. The issue is that ABAP program does not run at all.
    I ran the ABAP program in background and it took approximately 2 hours to run. ABAP Program is local means in our BW system and does not involve Remote Function call. We have BI7.0 system
    Has some one came across this type of issue?
    Best Regards
    Pradip

    Has the aleremote user or which ever user you have defined for background scheduling changed permissions recently?
    What happens if you create an adhoc chain and include this ABAP variant, does it run then?
    What does the log say in SM37 when run via process chain?
    Cheers
    Craig

  • ABAP Program using Selection Screen in Process Chain

    Hi,
    I have included an ABAP Program in the Process Chain.
    The ABAP Program takes a selection screen value from user before execution.
    I have created a variant for both the ABAP Process (YPV_ABC) and a variant for the Selection Screen (YPV_XYZ).
    The ABAP Program executes perfectly well in SE 38.
    I get the following message when I execute the Process Chain.
    "Status Change of Process ABAP YPV_ABC.
    Save Status and Trigger Events if Appropriate "
    When I click Yes, the ABAP Process becomes red.
    These are error messages in the log
    516 -  Job started     
    550 -  Step 001 started (program RSPROCESS, variant &0000000012961, user ID ALEREMOTE)
    25 -    Could not ascertain code page     
    546 -  Job cancelled after system exception ERROR_MESSAGE     
    My questions are:
    1) Is it possible to use an  ABAP Program which has a user input screen in Process Chain?
    2) Could you please help  with the above error?

    1) Is it possible to use an ABAP Program which has a user input screen in Process Chain?
    ABAP programs, with variants established for selection screens, are possible. We use them quite extensively for setting triggers to allow Process Chain to continue after an Interrupt Process has been hit.
    2) Could you please help with the above error?
    I'm not quite sure what could be causing this. When you tested this program in SE38, did you test it with the same variant for the selection screen and did you execute it in background?

  • How to add Abap program in process chain to check the another process chain status and do accordingly

    Hello All,
    My requirement is related to process chain 1 . I have one process chain in that i have to  put abap program in middle of that chain . This program will check the status of one another process chain 2 status ( whether it was completed or it is going on). if it is completed then continue the Process chain 1  to further activity else wait to complete Process chain 2 .
    Here i have to use process chain 2 as a parameter.
    Kindly provide me solution .
    Regards
    Saurabh

    Hi Saurabh,
    You need to create ABAP program in which you check the values for required process chain in
    following table
    RSPCLOGCHAIN (Feilds ANALYZED_STATUS LOG_ID)
    Depend on values you can trigger next process or you can wait unitil this process chain complete.you need to check status from table using ABAP.
    If you are not aware about how to write ABAP program then take help from ABAP Team.
    Regards,
    Ganesh Bothe

  • Trigger process chains using  ABAP program selection screen.

    Hi All
    I am loading flat files through process chains. My requirment is such that i need to create a ABAP selection screen so that user can load the flat file from his PC. when the user is loading the flat file i have to copy the file onto the application server folder and then display him the monitor errors/warnings (if any). when my data load is complete i need to archive the file with time stamp onto the application server folder.
    Please help me in this regard....
    thanks and regards
    sairam phani

    Hi,
    1. Using TA: AL11 create a folder in application server.
    2. There is a program to send the flat file to application server on r/3 side.
    Program Name:RC1TCG3Z.
    3. Regarding archiving...I have no idea.
    Regards,
    Vijay.

  • How to reset an failed asynchron abap-process in a process-chain?

    Hi specialists,
    I've got a process-chain which triggers (as one of its steps) an abap-program.
    The program should run asychroniously, so the process-chain waits until the programm reports its ending.
    When the abap-program fails/crashes/dumps, then the endings is never reported and the process-chain gets stuck.
    If I try to re-run that process-chain, it fails again with the message "Variant XYZ still executing from previous run".
    What I already found so far is the following note:
    The process chain management will not know if your program terminates!
    Thus if you re-start the chain, this will also terminate, because the old run would not have finished yet. To avoid this, you need to manually set the process in the chain log view in the process monitor to terminate before you start again.
    My problem: I cannot find any possibility to set the process to "terminate" in the chain's log view.
    Could you please gimme a hint where I can find that option?
    Best regards,
      Marco

    Hi,
    You can remove the process chain from scheduling before staring the process chain again.
    Also can edit the entries in RSPROCESSLOG table before running the process chain.
    Alternatively you can create a custom ABAP process type which handles the success as well as fail cases.
    Refer : [How To- Trigger subsequent processes in a Process Chain based on the Success or Failure of ABAP program|/people/balaji.venugopal/blog/2009/04/07/how-to-trigger-subsequent-processes-in-a-process-chain-based-on-the-success-or-failure-of-abap-program]
    Hope this helps,
    Regards,
    anil

Maybe you are looking for

  • Excise value not showing in MIGO

    Dear Team I am using TAXINN. In PO the condition value which i mentain in FV11 are flowing Like BED,ED CESS,AND SEC ED CESS. But in Migo i m able to see only ED Cess. Plz give me sloution for this.....Let me know if SAP note Number  is there for SEC

  • Online Meet-up 6. How does RFID infrastructure figure as a part of ESA ?

    ESA is a technology similar to RFID as a technology. For Ex: If a company does not have an SAP system at this moment. We have to work with their legacy system. Then we need to use the ESA. With the ESA, it will be easier to work with any system.ESA i

  • Writing html file in a jeditorpane

    I have read one of your threads titled as "How to insert a string in a JEditorPane (Urgent)". according to this thread I am using insertString() method to write in an jeditorpane. what I am writing is an html file. when I used insertString() method i

  • Entering Cosr Center in Already Posted Document

    Hi Guru I have posted one FI Document and in which GL account was not created as a cost element so Cost Center is not asked at the time of posting. Later GL account is created as a cost element. Now the porblem is how to update Cost Center in Posted

  • Picking output not hitting breakpoint in print program

    Hi Guys, I have an o/p type ZK00, I need to debug the print program and the script for it. I have placed a breakpoint in the print program at the designated routine in TNAPR (Entry). Now when I try to save the delivery I expect it to hit the code but