Wb_rt_api_exec.run_task

What is the function owbrt.wb_rt_api_exec.run_task intended for?
I can't find it in this forum nor on Google nor on OTN nor in the OWB documentation.
Why is it there and why is it never mentioned?
Best regards,
Erik Ykema

please have a look in metalink:
there you can find that this is the replacement for the oem templates (the code is not wrapped, so you can see, that it is nearly the same in PL/SQL as the oem template in the sql file)

Similar Messages

  • Wb_rt_api_exec.run_task system_params and custom_params to schedule a job

    Hi all,
    Did anybody ever use system_params and custom_params in the wb_rt_api_exec.run_task function to execute a process flow execution?
    I have three process flows under three different Item names within the same runtime repository, so the point here would be to differenciate them using the system_params and/or custom_params.
    Using this syntax:
    prodowbrt.wb_rt_api_exec.run_task('MY_PROCESS_FLOWS_LOC', 'ProcessFlow', 'MY_PROCESS_FLOW', '', 'item_key=MY_ITEM_NAME', 1);
    This ends up with ORA-01422 error messages when I try running it into SQL*Plus
    Anybody could help?
    Thank you!

    Hi,
    I'm not to sure about the custom params, but the parameter 'processFlow' should be changed to 'process'.
    Ragnar

  • Error in Process flow running in SQL owb_run_own.wb_rt_api_exec.run_task

    Hi all
    We are having issue with owb_run_own.wb_rt_api_exec.run_task using Sql Plus
    When i try to run through Warehouse Builder Process flow ran Successfully
    When i try to run through SQL Plus using owb_run_own.wb_rt_api_exec.run_task We are getting error
    ORA-20099: ORA-20003: Process Flow FailedSerious <PROCEDURE_NAME >unknown error
    RPE-02018: Oracle Workflow schema OWF_MGR on host OWD2HOST cannot be accessed using service OWDX.XXXX.XXXX through port 1523. Please check the location details and try again.
    Can any one help please
    Thanks in Advance
    Edited by: user1849 on May 5, 2009 9:56 AM

    Hi all
    We are having issue with owb_run_own.wb_rt_api_exec.run_task using Sql Plus
    When i try to run through Warehouse Builder Process flow ran Successfully
    When i try to run through SQL Plus using owb_run_own.wb_rt_api_exec.run_task We are getting error
    ORA-20099: ORA-20003: Process Flow FailedSerious <PROCEDURE_NAME >unknown error
    RPE-02018: Oracle Workflow schema OWF_MGR on host OWD2HOST cannot be accessed using service OWDX.XXXX.XXXX through port 1523. Please check the location details and try again.
    Can any one help please
    Thanks in Advance
    Edited by: user1849 on May 5, 2009 9:56 AM

  • Is there some error log for wb_rt_api_exec.run_task?

    Hi,
    I am trying to execute a mapping using "wb_rt_api_exec.run_task" by executing the following
    declare
    result_num number;
    begin
    result_num:= NEW_OWNER.wb_rt_api_exec.run_task('NEW_USER', 'PLSQLMAP', 'TEST_MAP', ',', ',', 0 ,0);
    end;
    And this is the output that I get:
    Stage 1: Decoding Parameters
    | location_name=NEW_USER
    | task_type=PLSQLMAP
    | task_name=TEST_MAP
    Stage 2: Opening Task
    | l_audit_execution_id=167
    Stage 3: Overriding Parameters
    Stage 4: Executing Task
    | l_audit_result=3 (FAILURE)
    Stage 5: Closing Task
    Stage 6: Processing Result
    | exit=3
    Command was executed successfully
    Now I have no idea why the execution of task failed? Is there some log file where I can lookup what the error is?
    Thanks,

    I had seen the error in Execution log accessed through Repository browser.
    But Ive resovled it now.
    Actually, the user (NEW_USER) connected to with sqlplus did not have privileges on the registered location - so I connected to OWB Design Center as that user(NEW_USER) and registered the location entering the password. Thats it. It worked!!

  • Error when using wb_rt_api_exec.run_task api to call process flow

    Dear All,
    I am using OWBV 10.2.0.3 and currently have some issue with it.
    I have a process flow and I'm executing it using wb_rt_api_exec api.
    When I ran it, that process flow failes with below error messages.
    RPE-01003: An infrastructure condition prevented the request from completing.
    RPE-01038: Failed to evaluate expression null. Please modify the expression, redeploy and retry again.
    RPE-01003: An infrastructure condition prevented the request from completing.
    RPE-02227: Cannot test Control Center user OWF_MGR. This user must match the login credentials of the evaluation location configured on owning module.
    ORA-01017: invalid username/password; logon denied
    But using same user when I log on to the OWB client I can run that process flow without any error. So it seems to be there is no any sesurity issues too.
    Furthermore I have done below things.
    OWF_MGR (Processflow user), OWB_MGR (repositiry user) and RUNTIMEUSR (user used to run the processflow) all registered under control center.
    There are couple of forum post here. I followed all those and didnt work anything for me.
    Early response highly regards,
    mc
    Edited by: mc**** on Jan 19, 2011 4:13 PM

    Hi,
    look these forum threads {message:id=3140661} and {message:id=2695999}
    I think you need connect with Design Center under user which you used for executing processflow and register workflow location
    Regards,
    Oleg

  • Wb_rt_api_exec in pl/sql as OWB target

    I've got a question similar to the one posted by Donna Kelley on 26-mar-2007 (
    Re: 10gR2: How do you run OWB from Enterprise Manager (OEM) and Scheduler?
    I'm unable to figure out the grants needed to execute wb_rt_api_exec.run_task within a pl/sql procedure when the procedure is being run by the OWB target user.
    We just upgraded OWB in devo from 10.1.0.4 to 10.2.0.1.31. In the earlier version, there was no problem with the target user executing wb_rt_api_exec (although we used open, execute, close instead of run_task). The runtime repository owner granted execute on wb_rt_api_exec to the target schema. And then the 2 roles wb_r_owbruntime and wb_u_owbruntime were also granted to target. That's all it required.
    In the new version, I can execute wb_rt_api_exec only as the design repository owner. I've granted the target user execute on wb_rt_api_exec. Also granted the 2 roles owb_d_owbowner and owb_o_owbowner roles to the target user (see sqlplus_exec_template.sql). But within a pl/sql procedure with the procedure run as the target user, the return code is 3 (failure). I can also not run sqlplus_exec_template as the target user. But I can run it successfully as the design repository owner.
    This seems strange. We're running ETL mappings to populate target tables. It should be easy to run the pl/sql procedure as the target user. I don't want to run it as the repository owner because that would involve a bunch of grants on target tables. Seems silly.
    I'd welcome any thoughts and advice.
    Many thanks.
    Gary

    First, David, thanks very much for your help. Based on your example, what I'm trying to do should work.
    Below is a very simplified example that demonstrates the problem. Note that executing the procedure as the target user produces an error (ie, the return value is 3) while executing it as the design repository owner succeeds.
    Comments and advice are welcomed from all. I very well could be missing something obvious. Thanks to all.
    devo> @who
    OWBTARGET
    devo> start t1
    devo> create procedure t1 authid current_user as
    2      sql_stmt varchar2(50) := 'set role owb_d_owbdesign, owb_o_owbdesign';
    3 begin
    4      execute immediate sql_stmt;
    5      dbms_output.put_line(to_char(owbdesign.wb_rt_api_exec.run_task(
    6      'RPTDEVO_LOC', 'PLSQLMAP', 'TERM_TO_DMS_CURR', ',', ',', 0, 0)));
    7 end;
    8 /
    Procedure created.
    devo> grant execute on t1 to owbdesign;
    Grant succeeded.
    devo> exec t1
    Stage 1: Decoding Parameters
    | location_name=RPTDEVO_LOC
    | task_type=PLSQLMAP
    | task_name=TERM_TO_DMS_CURR
    Stage 2: Opening Task
    | l_audit_execution_id=5390
    Stage 3: Overriding Parameters
    Stage 4: Executing Task
    | l_audit_result=3 (FAILURE)
    Stage 5: Closing Task
    Stage 6: Processing Result
    | exit=3
    3
    PL/SQL procedure successfully completed.
    devo> @check_role_privs owbtarget
    devo> select grantee "grantee",
    2      granted_role "role",
    3      admin_option "option"
    4 from dba_role_privs
    5 where grantee = upper('&1')
    6 order by 2
    7 ;
    admin
    grantee role option
    OWBTARGET AQ_USER_ROLE NO
    CONNECT NO
    OLAP_USER NO
    OWBR_OWBDESIGN NO
    OWB_D_OWBDESIGN NO
    OWB_OWBDESIGN NO
    OWB_O_OWBDESIGN NO
    RESOURCE NO
    SELECT_CATALOG_ROLE NO
    9 rows selected.
    devo> connect owbdesign
    Connected.
    devo> @who
    OWBDESIGN
    devo> exec owbtarget.t1
    Stage 1: Decoding Parameters
    | location_name=RPTDEVO_LOC
    | task_type=PLSQLMAP
    | task_name=TERM_TO_DMS_CURR
    Stage 2: Opening Task
    | l_audit_execution_id=5400
    Stage 3: Overriding Parameters
    Stage 4: Executing Task
    | l_audit_result=1 (SUCCESS)
    Stage 5: Closing Task
    Stage 6: Processing Result
    | exit=1
    1
    PL/SQL procedure successfully completed.

  • Wb_rt_api_exec problem  in 10G OEM

    I'm trying to schedule a process in 10G OEM built in OWB. All validation, generation, deployment is fine. I can't find the docs to guide me in this process. The docs deal with the oem_exec_template.sql - which says to use wb_rt_api_exec.run_task for 10G OEM. Any idea what to do for scheduling in 10G OEM??
    Based on examples in Metalink forum this is what I'm putting into the SQL script job in OEM. Errors included as well.
    declare
    ret number;
    begin
    ret:=runtime_owner.wb_rt_api_exec.run_task('RUNTIME', 'EASYDW', 'PROCESS', 'F4211LOAD','','',1);
    end;
    Copyright (c) 1982, 2004, Oracle. All rights reserved.
    SQL> SQL> SQL> SQL> Connected.
    SQL> SQL> 2 3 4 5 6 ret:=runtime_owner.wb_rt_api_exec.run_task('RUNTIME', 'EASYDW', 'PROCESS', 'F4211LOAD','','',1);
    ERROR at line 4:
    ORA-06550: line 4, column 6:
    PLS-00306: wrong number or types of arguments in call to 'RUN_TASK'
    ORA-06550: line 4, column 1:
    PL/SQL: Statement ignored
    declare
    ret number;
    begin
    ret:=runtime_owner.wb_rt_api_exec.run_task('RUNTIME', 'EASYDW', 'PROCESS', 'F4211LOAD','','');
    end;
    ERROR at line 1:
    ORA-20001: Task not found - Please check the Task Type, Name and Location are
    correct.
    ORA-06512: at "RUNTIME_OWNER.WB_RT_API_EXEC", line 620
    ORA-06512: at line 4

    Thanks guys. You were both right - wrong process name and too many parameters. And I realized I used the database locations value - not the Process flows locations.
    This worked =
    runtime_owner.wb_rt_api_exec.run_task('process flows locations', 'PROCESS', 'process name','','',1);
    declare
    ret number;
    begin
    ret:=runtime_owner.wb_rt_api_exec.run_task('DWDEST', 'PROCESS', 'PROC','','',1);
    end;
    /

  • Usage of wb_rt_api_exec.execute_in_background

    In wb_rt_api_exec_example.txt, the basic steps to run a map are:
    1 - initialize session roles
    2 - wb_rt_api_exec.open
    3 - override SYSTEM params
    4 - override CUSTOM params
    5 - wb_rt_api_exec.execute
    6 - wb_rt_api_exec.close
    If I wanted to use wb_rt_api_exec.execute_in_background, would I also need to call the close procedure?
    1 - initialize session roles
    2 - wb_rt_api_exec.open
    3 - override SYSTEM params
    4 - override CUSTOM params
    5 - wb_rt_api_exec.execute_in_background
    6 - ?? wb_rt_api_exec.close ??
    I can't use wb_rt_api_exec.run_task (as it is used in oem_exec_background_template.sql) since I need to be able to get the audit_execution_id that is returned when you open a task.

    Hi
    Maybe you can call simple wb_rt_api_exec.execute (sample file: owb/rtp/sql/wb_rt_api_exec_example.txt, procedure override_custom_input_params).
    You can try to call close after you execute background process (i don't know, but maybe there is some execution stuck), if there is no errors, then why not?
    Regards

  • Wb_rt_api_exec over a database link

    When I call wb_rt_api_exec over a database link I receive:
    ORA-20001: Task not found - Please check the Task Type, Name and Location are correct.
    ORA-06512: at "OWB_10_2_0_1_31.WB_RT_API_EXEC", line 704.
    When I run the command on the other database it works.
    Is there a way to do this?
    Thanks,
    Joe

    We had the same error when starting a package with WB_RT_API_EXEC.RUN_TASK from JBoss Middleware. It ran fine when started directly from SQLDeveloper, but threw the error when started from JBoss. Adding the pragma solved the problem, we also had to put a commt; at the end of the procedure.

  • 10GR2 - Cannot get wb_rt_api_exec to execute a Process Flow

    Hi,
    In version 10.1.3, I was able to use the wb_rt_api_exec procedure to execute process flows within a stored procedure (and called by an Enterprise Manager job).
    I have tried something similar in 10GR2, but when I run stored procedure, it says it has executed successfully, but the process flow has not run.
    My Stored procedure code is like:-
    CREATE OR REPLACE PROCEDURE PROC_TEST IS
    ret NUMBER;
    BEGIN
    ret:= rep_owner.wb_rt_api_exec.run_task('PROCESS_LOCATION','PROCESS','WF_TEST','','',1,1);
    END PROC_TEST;
    I have noticed there is an extra parameter p_background at the end of the run_task function and was not sure if I am setting it correctly. The procedure compiles ok, but does not run the process flow.
    Can anyone help please?
    Thanks
    GB

    To run workflow from SQLPLUS I used the following script:
    set serveroutput on
    variable exec_return_code number;
    begin
    -- Initialize Return Code
    :exec_return_code := rep_ISM_DEV2.wb_rt_api_exec.RESULT_FAILURE;
    -- Run Task
    :exec_return_code := rep_ism_dev2.wb_rt_api_exec.run_task('OWF_LOCATION','PROCESS','ALL_MARTS_PF', ' ' );
    end;
    Prior to running this script I have
    1.     grant execute on rep_owner.WB_RT_API_EXEC to rep_user;
    2.     OWF_MGR is registered as Repository user.
    It is possible that you will get an error: PE-02018: Oracle Workflow schema OWF_MGR on host XXX.XX.XX.XX cannot be accessed using service ORCL through port 1521. Please check the location details and try again.
    To overcome this problem log in to OWB Control Center as the target User (Runtime user) and executed the PF package from there manually. You will get a message that OWF_MGR location was registered by other user and you will get asked to supply the OWF_MGR password. The manual execution should finish normally. After that I am able to run the PF from a command line without problems. It looks like running the PF from the control center stores the OWF_MGR login information somewhere (anybody knows where?) and you do not need to supply it any longer.
    Hope it helps.
    Vladimir

  • Takes time to start mapping.

    I am struggling with a strange problem.
    i have a process flow which is like
    start ----> Fork---->Mapping1
    |
    |
    V
    Mapping2.
    when i start the process flow with help of wb_rt_api_exec.run_task(); process flow starts immediately and creates an entry for process flow in ALL_RT_AUDIT_EXECUTIONS immediately
    but Mapping1 and Mapping1 are started after 15-20 minutes and no entry is created in ALL_RT_AUDIT_EXECUTIONS till then.
    any help is appericiated in this regard.
    Regards,
    rd_rbs

    cant see a reason unless there are some networking issues or deadlocks(which prevents the mapping from executed) or a DBMS SLEEP anywhere in your mapping(i reckon if someone would do that sort of thing)

  • How to Schedule Job using Database Control for SQLPLUS script?

    Hi All,
    I am using Database version 10.2. I would like to schedule a SQLPLUS script job using Database control (Not using Grid Control!). The following is the script.
    ========================================================
    define OEM_FRIENDLY=1
    define OWB_BACKGROUND=0
    set serveroutput on
    set verify off
    whenever sqlerror exit failure;
    define REPOS_OWNER='&1.'
    define LOCATION_NAME='&2.'
    define TASK_TYPE='&3.'
    define TASK_NAME='&4.'
    define SYSTEM_PARAMS='&5.'
    define CUSTOM_PARAMS='&6.'
    alter session set current_schema = &REPOS_OWNER.;
    set role owb_d_&REPOS_OWNER., owb_o_&REPOS_OWNER.;
    variable exec_return_code number;
    begin
    -- Initialize Return Code
    :exec_return_code := wb_rt_api_exec.RESULT_FAILURE;
    -- Run Task
    :exec_return_code := wb_rt_api_exec.run_task('&LOCATION_NAME.',
    '&TASK_TYPE.',
    '&TASK_NAME.',
    '&CUSTOM_PARAMS.',
    '&SYSTEM_PARAMS.',
    &OEM_FRIENDLY.,
    &OWB_BACKGROUND.);
    end;
    exit :exec_return_code;
    ===========================================================
    Is it possible to schedule SQLPLUS script with 6 different parameters? If yes then how can I schedule for monday to friday or only for Saturday and sundays.
    Please provide brief steps.
    Thanks for your help in advance.
    - Mehul

    Let me explain to you about scheduler.
    You can schedule a pl/sql stored procedure TEST_S as follows...
    Begin
    dbms_scheduler.create_job(
    job_name=>'MY_JOB',
    Job_Type=>'STORED_PROCEDURE',
    job_action=>'TEST_S',
    start_date=>sysdate,
    repeat_interval=>'freq=monthly;BYDAY=MON,TUE,WED,THU,FRI',
    end_date=>null');
    END;
    You can also also execute o/s script like .bat or .sh. For this job type should be EXECUTABLE.
    Example of converting a .sql script in .bat script...
    insert.sql
    insert into dept values(50,'IT','LONDON');
    exit
    insert.bat
    sqlplus scott/tiger @insert.sql
    Executing now...
    C:\Documents and Settings>insert.bat
    C:\Documents and Settings>sqlplus scott/tiger @insert.sql
    SQL*Plus: Release 10.2.0.1.0 - Production on Thu Mar 1 08:01:00 2007
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    1 row created.
    Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - P
    oduction
    With the Partitioning, OLAP and Data Mining options
    C:\Documents and Settings>
    So first read about DBMS_SCHEDULER and do the work in prompt. Then you can go and schedule it even by database control.
    Scheduling by database control...
    http://www.oracle.com/technology/oramag/oracle/04-jul/o44tech_dba.html
    Scheduler
    http://download-uk.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_sched.htm#CIHEHDHA
    PS: By default each job you created is disable state. Please enable it by enable procedure of DBMS_SCHEDULER package.

  • Get current LOCATION in ProcessFlow (PF) or Mapping

    How can I get current LOCATION from running PF or Mapping?
    I need to run PF.
    Name of PF passing via parameter of PF.
    I know about wb_rt_api_exec.run_task, but first parameter is LOCATION.

    It is possible to get location from ALL_RT_AUDIT_EXECUTIONS OWB public view (column OBJECT_LOCATION_NAME),
    if I understand your requirements properly.
    Filter rows from ALL_RT_AUDIT_EXECUTIONS via execution_audit_id, in processflow you can use predefined variable AUDIT_ID for currently running processflow audit id
    Regards,
    Oleg

  • Error in sqlplus_exec_template for executing a process workflow

    Hi,
    en_dev_rep_owner = owb reposittory owner owb10g2
    LC_OWF = owf location
    PROCESSFLOW = tasktype
    WF_DIMS = Process flow (not the process package)
    This is returning the following error :
    SQL> connect en_dev_rep_owner/en_dev_rep_owner@en_dm_dev_test
    Connected.
    SQL> start D:\oracle\owb10g2\owb\rtp\sql\sqlplus_exec_template.sql en_dev_rep_ow
    ner LC_OWF PROCESSFLOW WF_DIMS
    Enter value for 5:
    Enter value for 6:
    Session altered.
    Role set.
    Stage 1: Decoding Parameters
    | location_name=LC_OWF
    | task_type=PROCESSFLOW
    | task_name=WF_DIMS
    Stage 2: Opening Task
    begin
    ERROR at line 1:
    ORA-20001: Task not found - Please check the Task Type, Name and Location are
    correct.
    ORA-06512: at "EN_DEV_REP_OWNER.WB_RT_API_EXEC", line 704
    ORA-06512: at line 12
    Thanks in advance

    define OEM_FRIENDLY=0
    define OWB_BACKGROUND=0
    l_custom_params := '&CUSTOM_PARAMS.';
    l_task_type := 'PROCESSFLOW';
    l_location_name := '&LOCATION_NAME.';
    l_task_name := '&TASK_NAME.'; - workflow name
    dbms_output.put_line('Stage 1: Source files will be loaded into Staging '||l_task_name);
    :exec_return_code := wb_rt_api_exec.run_task(l_location_name
    ,'&TASK_TYPE.'
    ,l_task_name
    ,l_custom_params
    ,'&SYSTEM_PARAMS.'
    , &OEM_FRIENDLY.
    , &OWB_BACKGROUND.);
    dbms_output.put_line('Stage 2: Task Finished');
    I hope that the cut and paste didn't mess up the format

  • Invoking a mapping from another DB in a process flow

    Hi experts, have anyone try to invoke/execute an OWB mapping from another database in a process flow? Is it possible to do that?
    My process flow (in the Staging db) scenario is to execute several OWB mapping in the Staging db, then the final step is to execute an OWB mapping which is created in the warehouse db.
    Is that possible?
    Edited by: wwardana on Apr 5, 2009 9:09 PM

    Look at this thread
    [Calling WB_RT_API_EXEC.RUN_TASK over database link|http://forums.oracle.com/forums/thread.jspa?threadID=775938]
    Regards,
    Oleg

Maybe you are looking for

  • Syncing the ipod touch

    SO i was trying to update my touch today and it stopped halfway through and a pop up said that "this computer is no longer autherized to play purchased items on the Ipod "XXX" WOuld you like to autherize it?" I and after i autherized the computer it

  • How do i select a particular cell from a AbstractTableModel?

    I m using abstractTableModel to create my table. My table display 4 columns of different info, now i can capture my info from the other window and compare the value with my table but i don't know how to highlight/or select the particular rows in tabl

  • Need help with a mapping

    Hi, I have problems to create an update on the NULL values in a table with the mapping operators of the OWB mapping editor. The SQL syntax is the following: UPDATE T006_SITE SET T006A11FK_COUNTRYID = (select MAX(T002A01PK_COUNTRYID) from T002_COUNTRY

  • CSS Positioning in Internet Explorer 7

    Everything seems to be fine in Firefox on both Mac and PC, but when I tried viewing things on my home pc in Explorer, my divs are out of whack. I recently added a slideshow function I found, but I don't think that caused the problems since it doesn't

  • How to make agency-level HTML banner ads

    I've done a ton of Flash banner ads at agency-level over the years, but I'm trying to figure out how to create html banners now, in addition. Here are the HTML Ad Spec requirements: - HTML code cannot exceed 3k - 2 images maximum, total file size of