Sequence of execution of Oracle Joins

Hi All,
I am applying combination of outer-join & equi-join on around 5-6 tables.
But I am not getting expected results.
I just wanted to know how Oracle applies execution of this joins, outer & equi.

Here is the data on which I am playing,
--Employee table  
CREATE TABLE "EMP"
   ("EMP_ID" NUMBER(10,0) NOT NULL ENABLE,
     "FNAME" NVARCHAR2(50) NOT NULL ENABLE,
     "LNAME" NVARCHAR2(50) NOT NULL ENABLE
--Mapping between Task type & Department
   CREATE TABLE "TASKTYPE_FOR_DEPT"
   (     "TASKTYPE_FOR_DEPT_ID" NUMBER(10,0) NOT NULL ENABLE,
     "DEPT_ID" NUMBER(10,0) NOT NULL ENABLE,
     "TASK_TYPE_CD" NVARCHAR2(10) NOT NULL ENABLE
-- Departmentwise employee hierarchy  
CREATE TABLE "EMP_HIERARCHY"
   (     "EMP_ID" NUMBER(10,0) NOT NULL ENABLE,
     "DEPT_ID" NUMBER(10,0) NOT NULL ENABLE
   -- Tasks Details
CREATE TABLE "TASKS"
   (     "TASK_ID" NUMBER(10,0) NOT NULL ENABLE,
     "TASK_PRIORITY" NVARCHAR2(10) NOT NULL ENABLE,
     "TASK_TYPE" VARCHAR2(20 BYTE)
   -- Tasks allocation
CREATE TABLE "TASKSALLOCATION"
   (     "TASKALLOCATION_ID" NUMBER(10,0) NOT NULL ENABLE,
     "EMP_ID" NUMBER(10,0) NOT NULL ENABLE,
     "TASK_ID" NUMBER(10,0) NOT NULL ENABLE
Insert into EMP (EMP_ID,FNAME,LNAME) values (1,'XYZ','DFD');
Insert into EMP (EMP_ID,FNAME,LNAME) values (2,'DFDS','FD');
Insert into EMP (EMP_ID,FNAME,LNAME) values (3,'FDSF','GFH');
Insert into EMP (EMP_ID,FNAME,LNAME) values (6,'GFHGF','GFHS');
Insert into EMP (EMP_ID,FNAME,LNAME) values (4,'GFD','FDG');
Insert into EMP (EMP_ID,FNAME,LNAME) values (5,'DSFDS','FDSAF');
Insert into EMP (EMP_ID,FNAME,LNAME) values (7,'GHGY','EWE');
Insert into EMP (EMP_ID,FNAME,LNAME) values (8,'FGRFSAD','SADF');
Insert into TASKTYPE_FOR_DEPT (TASKTYPE_FOR_DEPT_ID,DEPT_ID,TASK_TYPE_CD) values (1,1,'T1');
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (1,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (2,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (3,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (4,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (5,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (6,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (7,1);
Insert into EMP_HIERARCHY (EMP_ID,DEPT_ID) values (8,1);
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (1,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (2,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (3,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (4,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (5,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (6,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (7,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (8,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (9,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (10,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (11,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (12,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (13,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (14,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (15,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (16,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (17,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (18,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (19,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (20,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (21,'LOW','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (22,'HIGH','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (23,'MEDIUM','T1');
Insert into TASKS (TASK_ID,TASK_PRIORITY,TASK_TYPE) values (24,'LOW','T1');
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (1,1,1);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (2,2,1);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (3,3,2);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (4,3,3);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (5,4,4);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (6,4,5);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (7,4,6);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (8,4,7);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (9,5,6);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (10,6,8);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (12,8,8);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (13,8,10);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (14,8,11);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (15,8,12);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (16,6,13);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (17,5,14);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (18,3,12);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (19,3,13);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (20,2,15);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (21,1,16);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (22,2,17);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (23,1,18);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (24,4,19);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (25,6,20);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (26,5,21);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (27,1,22);
Insert into TASKSALLOCATION (TASKALLOCATION_ID,EMP_ID,TASK_ID) values (28,3,23);
COMMIT;We want all resources belongs to department for a given case type with assinged tasks count & grouping with priority.
I tried the following query,
select emp.fname || ' ' || emp.lname EMP_NAME
     , sum(DECODE(tasks.TASK_PRIORITY, 'HIGH', 1, 0)) HIGH
     , sum(DECODE(tasks.TASK_PRIORITY, 'MEDIUM', 1, 0)) MEDIUM
     , sum(DECODE(tasks.TASK_PRIORITY, 'LOW', 1, 0)) LOW
  from emp,
  EMP_HIERARCHY,
  TASKSALLOCATION,
  TASKS,
  TASKTYPE_FOR_DEPT 
  where
   TASKTYPE_FOR_DEPT.TASK_TYPE_CD = 'T1'
   emp.EMP_ID = TASKSALLOCATION.EMP_ID(+)
  and TASKSALLOCATION.TASK_ID = tasks.TASK_ID(+)
  and tasks.TASK_TYPE = TASKTYPE_FOR_DEPT.TASK_TYPE_CD
  and TASKTYPE_FOR_DEPT.dept_id = EMP_HIERARCHY.dept_id
-- and EMP_HIERARCHY.emp_id = emp.EMP_ID
group by emp.fname || ' ' || emp.lname;
It is not working properly.
Actually we are also looking the employee for whom task has been not allocated but belong to same department.
In above resultset employee 'GHGY EWE'.
We are expecting resultset something like this.
with
    t as
          select     'GFHGF GFHS' as emp_name, 1 as highPriority,     2 as mediumPriority, 0 as lowPriority FROM dual union all
          select     'FDSF GFH',               1     ,     2     ,     2     FROM dual union all
          select     'XYZ DFD'     ,          3     ,     0     ,     1     FROM dual union all
          select     'GHGY EWE',          0     ,     0     ,     0     FROM dual union all
          select     'DFDS FD',               1     ,     1     ,     1     FROM dual union all
          select     'GFD FDG',               3     ,     1     ,     1     FROM dual union all
          select     'FGRFSAD SADF',          1     ,     2     ,     1     FROM dual union all
          select     'DSFDS FDSAF',          0     ,     1     ,     2     FROM dual
          );Note : We are using Oracle 11.2.0.2.0 version

Similar Messages

  • Customer Exit Variable and Condition in a Query (Sequence of Execution)

    Hi,
      For a query i defined a Customer exit variable and a condition....
    Which will first execute...wether it is a  Variable and then Condition or vise versa
    Is there any way we can control sequence of execution
    My requirment is first to execute the condition and the variable how can i control this
    Thanks

    Hi
    In your customer exit you will be having a field by name I_STEP which will help you to handle the time of execution of the variable.
    Assign points if helpful
    Prathish

  • Sequence of execution

    Hello to every body
    I need to know about sequence of execution in a select command.
    I have a sql command that use a function.some thing like:
    select id, function(item)
    from tbl
    where conditions...
    I want to know that if my function on item execute before where section or vise versa.
    I try to explain it more. I want to know that sql engine fetch rows according to where clause and then execute my function or execute my function and then fetch the rows according to where clause.
    If you have a document or some thing that explain about sql engine and sequence of execution please let me know.
    Your help is really appreciated.

    EXPLAIN PLAN SET STATEMENT_ID='TSH' FOR
    SELECT *
    FROM emp e, dept d
    WHERE e.deptno = d.deptno
    AND e.ename = 'SMITH';
    SELECT *
    FROM TABLE(DBMS_XPLAN.DISPLAY('PLAN_TABLE','TSH','BASIC'));
    for this u need to have PLAN_TABLE in your schema
    Regards,
    Abu

  • Sequence of execution of events

    Can anyone tell me what is the sequence of execution of events i

    Hello,
    Take a look on this: http://help.sap.com/saphelp_nw04s/helpdata/en/9f/db9a1435c111d1829f0000e829fbfe/frameset.htm
    Regards.

  • Difference between oracle join syntaxes and ANSI join syntaxes

    What is difference between oracle join syntaxes and ANSI join syntaxes ?
    why oracle is having different syntaxes for joins than ANSI syntaxes ?
    Also Join syntaxes are different in some oracle vesrions ?

    BluShadow wrote:
    3360 wrote:
    Yes it is. The Oracle database wasn't initially designed to be ANSI compliant. As you correctly state the ANSI standards weren't around when it was initially designed, so the statement is perfectly correct. ;)Ok, in one sense it may be correct but it is a completely misleading statement. Not sure why you think it's misleading.Because there was no ANSI standard, so making it sound like a design choice The Oracle database wasn't initially designed to be ANSI compliant. would suggest to most readers that there was a standard to be compliant to.
    Like saying Ford originally did not design their cars to incorporate safety features such as ABS, seat belts and air bags.
    The OP asked "why oracle is having different syntaxes for joins than ANSI syntaxes ?" and the answer is that Oracle wasn't initially designed with ANSI compliance, so it has it's old non-ANSI syntax,As shown above, the old syntax was ANSI compliant at the time and to call it non-ANSI is either incorrect or misleading dependent on your point of view.
    and since ANSI syntax became the standard it now supports that. And since ANSI switched to a new standard, Oracle had to implement the new standard as well as the previous ANSI standard would be more accurate in my opinion.
    Nothing misleading as far as I'm aware in that.I find the whole discussion about ANSI and Oracle's supposed non-compliance, reads like it was Oracle's choice to deviate from the standards, when it was ANSI's bullheaded decisions to pointlessly change standards that left Oracle and other vendors out of compliance, and that was a decision made solely by ANSI.
    This is probably the reason ANSI no longer produces SQL standards, the endless syntax fiddling would eventually have made forward left under outer joins a reality.
    {message:id=1785128}

  • Sequence of execution of report

    HI BW Experts,
    Can any one tell me what is sequence of execution like RKF, CKF,Filters,Formulas etc. of the report
    Regards
    RK

    hello,
    the sequence may be
    1.Filters
    2.RKF
    3.CKF , Formula
    For furtehr understanding,please refer the link:
    http://help.sap.com/saphelp_nw2004s/helpdata/en/e3/e60138fede083de10000009b38f8cf/frameset.htm
    Reg,
    Dhanya

  • Sequence Execution in oracle apps forms

    hi all
    I want to know the execution sequence of the form personalization, CUSTOM PLL , Profile options in oracle apps for a specified form
    thanks

    Hi;
    What is your EBS?
    Please check below thread which is similar as your question
    Re: Form Personalization
    Regard
    Helios

  • ORA-01002: fetch out of sequence- error when accesing oracle sp from c#

    We have a stored procedure when we exceute it from Sql plus tool ot Toad works fine. But when we call it from C# .ne code gives us the following error.
    ORA-01002: fetch out of sequence ORA-02063: preceding line from SQA1
    Please help.

    with out these lines it works
    (fae_primary_agent_ind = 'X') or
    ((fae_primary_agent_ind is null) and (agn_agt_comp_st_cd = ‘65’)
    This is the stored proc. It works in oracle. It does not work only when we call it from C#.
    CREATE OR REPLACE
    PROCEDURE abc (
    p_report_date IN VARCHAR2,
    p_cur OUT Getadrdata.t_cursor,
    p_run_mode OUT NUMBER
    AS
    v_report_dt DATE;
    backed_out NUMBER := 0;
    previously_paid NUMBER := 0;
    BEGIN
    v_report_dt := TO_DATE (p_report_date, 'DDMMYYYY');
    SELECT COUNT (*)
    INTO backed_out
    FROM r2t_adr_payment a, DUAL
    WHERE a.fap_acctg_dt = v_report_dt
    AND a.fap_status_cd = 'B';
    IF backed_out = 0
    THEN
         SELECT COUNT (*)
    INTO previously_paid
    FROM r2t_adr_payment a, DUAL
    WHERE a.fap_acctg_dt = v_report_dt
    AND a.fap_status_cd = 'P';
    END IF;
    IF backed_out > 0 or previously_paid > 0
    THEN
    p_run_mode := 2;
    OPEN p_cur FOR
    SELECT fae_agent_nbr agent_nbr, fae_ssn_last_4digits ssn_nbr,
    fae_address_ln1 address_line1, fae_address_ln2 address_line2,
    fae_city_nm city, fae_state_cd state, fae_zip_cd zip,
    fae_bus_phone business_phone, fae_supv_region_cd region,
    fae_territory_cd territory, fae_market_cd market,
    -- FAE_AGT_COMP_ST_CD COMP_STAT_CD,
    agn_agt_comp_st_cd comp_stat_cd, fae_emplmt_dt emp_date,
    fae_agent_type_cd status_cd, fae_first_nm first_name,
    fae_last_nm last_name,
    rpt_agent_bonus_class_id p_agent_bonus_class_id
    FROM r2t_adr_epc_agent_info LEFT OUTER JOIN rgt_points
    ON fae_agent_nbr = rpt_agent_nbr
    LEFT OUTER JOIN p1t_tot_agent ON fae_agent_nbr =
    agn_agent_nbr
    INNER JOIN r2t_adr_payment
    ON fae_agent_nbr = fap_primary_agent_nbr
    WHERE FAE_AGENT_TYPE_CD = '41'
    AND rpt_acctg_dt = v_report_dt
    AND v_report_dt BETWEEN agn_start_eff_dt AND agn_end_eff_dt
    AND fap_acctg_dt = v_report_dt
    AND fap_status_cd = 'B'
    UNION ALL
    SELECT fae_agent_nbr agent_nbr, fae_ssn_last_4digits ssn_nbr,
    fae_address_ln1 address_line1, fae_address_ln2 address_line2,
    fae_city_nm city, fae_state_cd state, fae_zip_cd zip,
    fae_bus_phone business_phone, fae_supv_region_cd region,
    fae_territory_cd territory, fae_market_cd market,
    -- FAE_AGT_COMP_ST_CD COMP_STAT_CD,
    agn_agt_comp_st_cd comp_stat_cd, fae_emplmt_dt emp_date,
    fae_agent_type_cd status_cd, fae_first_nm first_name,
    fae_last_nm last_name,
    0 p_agent_bonus_class_id
    FROM r2t_adr_epc_agent_info
    LEFT OUTER JOIN p1t_tot_agent ON fae_agent_nbr =
    agn_agent_nbr
    INNER JOIN r2t_adr_payment
    ON fae_agent_nbr = fap_primary_agent_nbr
    WHERE fae_agent_type_cd = '13'
    AND v_report_dt BETWEEN agn_start_eff_dt AND agn_end_eff_dt
    AND fap_acctg_dt = v_report_dt
    AND fap_status_cd = 'B';
    ELSE
    p_run_mode := 1;
    OPEN p_cur FOR
    SELECT fae_agent_nbr agent_nbr, fae_ssn_last_4digits ssn_nbr,
    fae_address_ln1 address_line1, fae_address_ln2 address_line2,
    fae_city_nm city, fae_state_cd state, fae_zip_cd zip,
    fae_bus_phone business_phone, fae_supv_region_cd region,
    fae_territory_cd territory, fae_market_cd market,
    -- FAE_AGT_COMP_ST_CD COMP_STAT_CD,
    agn_agt_comp_st_cd comp_stat_cd, fae_emplmt_dt emp_date,
    fae_agent_type_cd status_cd, fae_first_nm first_name,
    fae_last_nm last_name,
    rpt_agent_bonus_class_id p_agent_bonus_class_id
    FROM r2t_adr_epc_agent_info LEFT OUTER JOIN rgt_points
    ON fae_agent_nbr = rpt_agent_nbr
    LEFT OUTER JOIN p1t_tot_agent ON fae_agent_nbr =
    agn_agent_nbr
    WHERE rpt_acctg_dt = v_report_dt
    -- Next line for testing of a subset of data - testing purposes only
    -- AND FAE_SUPV_REGION_CD ='002'
    AND FAE_AGENT_TYPE_CD = '41'
    AND (
    (RPT_AGENT_BONUS_CLASS_ID = '3' AND SUBSTR(FAE_EMPLMT_DT,1,2) <> '01' AND ADD_MONTHS(FAE_EMPLMT_DT, 7 ) <= v_report_dt) OR
    (RPT_AGENT_BONUS_CLASS_ID = '3' AND SUBSTR(FAE_EMPLMT_DT,1,2) = '01' AND ADD_MONTHS(FAE_EMPLMT_DT, 6 ) <= v_report_dt) OR
    (RPT_AGENT_BONUS_CLASS_ID = '1')
    AND (
    (fae_primary_agent_ind = 'X') or
    ((fae_primary_agent_ind is null) and (agn_agt_comp_st_cd = ‘65’)
    AND v_report_dt BETWEEN agn_start_eff_dt AND agn_end_eff_dt
    UNION ALL
    SELECT fae_agent_nbr agent_nbr, fae_ssn_last_4digits ssn_nbr,
    fae_address_ln1 address_line1, fae_address_ln2 address_line2,
    fae_city_nm city, fae_state_cd state, fae_zip_cd zip,
    fae_bus_phone business_phone, fae_supv_region_cd region,
    fae_territory_cd territory, fae_market_cd market,
    -- FAE_AGT_COMP_ST_CD COMP_STAT_CD,
    agn_agt_comp_st_cd comp_stat_cd, fae_emplmt_dt emp_date,
    fae_agent_type_cd status_cd, fae_first_nm first_name,
    fae_last_nm last_name, 0 p_agent_bonus_class_id
    FROM r2t_adr_epc_agent_info LEFT OUTER JOIN p1t_tot_agent
    ON fae_agent_nbr = agn_agent_nbr
    WHERE fae_agent_type_cd = '13'
    -- Next line for testing of a subset of data - testing purposes only
    -- AND FAE_SUPV_REGION_CD ='002'
    AND fae_primary_agent_ind = 'X'
    AND v_report_dt BETWEEN agn_start_eff_dt AND agn_end_eff_dt;
    END IF;
    EXCEPTION
    WHEN NO_DATA_FOUND
    THEN
    --DBMS_OUTPUT.PUT_LINE ('no data ' || SQLERRM);
    NULL;
    WHEN OTHERS
    THEN
    --DBMS_OUTPUT.PUT_LINE ('error ' || SQLERRM);
    --OPEN p_cur FOR
    -- SELECT NULL
    -- FROM DUAL;
              RAISE;
    END abc;

  • Is there a SEQUENCE object, like in Oracle?

    I want to create a table and I have 2 fields, user name and user e-mail. The user e-mail would be the key, but, for performance issues, I think it's advisable to create a 3rd field, simply to assign an ID to each row - a numerical field.
    So as to every time a record is inserted in the table, this 3rd ID row is assigned a value automatically, with the next number in the sequence for the current record being added - if there are 11 records in the table and a 12th is being added, then the ID would be automatically set to 12 during the insertion of this 12th record.
    I would do this in Oracle through a SEQUENCE object.
    There's something equivalent I could use in SAP ?
    Thanks,
    Avraham

    In SAP we have 'number ranges' which serves the same purpose.
    http://help.sap.com/erp2005_ehp_03/helpdata/EN/08/51415d43b511d182b30000e829fbfe/frameset.htm
    The above link would give you fair amount of knowledge to create your own number range
    Cheers,
    KD

  • Error in job execution in oracle reports

    Hi,
    The end user is getting the following error when executing a job in Oracle reports.
    " RWCGI GET JOB OUTPUT
    Cannot get output of Job ID 4 you requested on December ,08 2008 , 11:35:18
    Job is not done yet .Try again later"
    Can you please help .PLEASE !!!

    Hi
    Metalink is reporting some similar errors, please see that:
    Cause
    SSO turned on for one component only, either Forms or Reports.
    This problem has been reported and is documented in an unpublished bug.
    Solution
    To take advantage of SSO, out-of-the-box, the SINGLESIGNON parameter in the
    rwservlet configuration file (rwservlet.properties) is set to YES to indicate
    that you will use single sign-on to authenticate users. You may change this to
    NO if you choose to not use single sign-on. If you choose NO, the Reports
    Server will use its own authentication mechanism to authenticate users (i.e.,
    the mechanism used in Reports6i). The rwservlet configuration file is usually
    found in the ORACLE_HOME\reports\conf directory. This value is usually
    commented out after installation however the default value is YES.
    This is the expected behavior. For the Forms/Reports integration, Forms will send
    to Reports thecurrent SSO user. However, with this particular configuration, you
    still log into SSO to run Reports. Thus, nexttime you run the form, you are logged
    into SSO and thus things work because Forms passes thatSSO user info to Reports.
    The way to not have the report run the 2nd time would be to log off of SSO when the first
    form was exited, but that defeats the purpose of SSO in the first place!
    So enable for Forms and Reports SSO or disable SSO for both.
    Read more on Doc ID:      Note:289666.1
    Subject:      REP-52251: Cannot Get Output Of Job Id
    Doc ID:      Note:289666.1
    Subject:      Understanding Reports Execution from Forms Under High Availability
    and
    Note 367887.1 - Rep-52251: Cannot Get Output Of Job Id You Requested, When Calling Reports From Forms

  • Sequencing and Trigger on Oracle 9i lite database

    We created a schema (TESTSCHEMA) on Oracle 8.1.7 Enterprise edition and have a created a trigger which will use the sequence object to generate primary key for the table (TEST_TABLE)
    Sequence creation:
    CREATE SEQUENCE TESTSCHEMA.TEST_TABLE_SEQUENCE START WITH 6000 INCREMENT BY 1 MINVALUE 6000 MAXVALUE 6999 NOCACHE NOCYCLE NOORDER ;
    Trigger creation:
    CREATE OR REPLACE TRIGGER TEST_TABLE INSERT BEFORE INSERT ON TEST_TABLE FOR EACH ROW
    DECLARE
    pkValue NUMBER;
    BEGIN
    pkValue := 0;
    Select TEST_TABLE_SEQUENCE.NextVal into pkValue from dual;
    :NEW.TEST_KEY := pkValue;
    END TEST_TABLE_INSERT;
    We have created a snapshot of the schema on mobile server, synchronized the data with the client (Win32 for testing purpose).
    The trigger works fine on the server, but when I run the same query on the lite database with msql it gives me an error:
    [POL-3221] null key in primary index
    I was wondering if Sequence generation and Triggers are supported on Oracle 9i lite database ? Or am I missing out something ??
    Any information/ help is appreaciated
    Thanks
    Neeraj

    You can't use SAVEPOINT / ROLLBACK TO SAVEPOINT statements in the database trigger:
    ORA-04092: cannot SET SAVEPOINT in a trigger
    ORA-04092: cannot ROLLBACK in a trigger
    I am not sure what you need exactly, but you can try this:
    Simulating ROLLBACK TO SAVEPOINT Behavior in a Database Trigger
    http://www.quest-pipelines.com/pipelines/plsql/tips02.htm#JUNE
    Regards,
    Zlatko Sirotic

  • Sequence number creation in oracle 11gR2

    Hi.. i am using oracle 11.2 version. how can i create my sequence value starts from 1..i am currently getting 2..pls help me..

    862189 wrote:
    Hi.. i am using oracle 11.2 version. how can i create my sequence value starts from 1..i am currently getting 2..pls help me..I'm going to guess that you're seeing the side effects of deferred segment creation.
    This does get mentioned in the reference manual under "create sequence": http://download.oracle.com/docs/cd/E18283_01/server.112/e17118/statements_6015.htm
    If this is the case then creating the target table with the "segment creation immediate" should address your problem: http://download.oracle.com/docs/cd/E18283_01/server.112/e17118/statements_7002.htm#i2095331
    Regards
    Jonathan Lewis

  • Execution of oracle cliet take long time in HPUX

    Hi all
    I have problem with oracle home 11.2.0.2 on HPUX B.11.31 U ia64
    In server I have two oracle home:
    1. oracle 10.2.0.4 which work ok
    2. 11.2.0.2 :
    execution of sqlplus /nolog (or another client like imp/ exp) take a lot of time (3 minutes) , I tried to trace with tusc : tusc sqlpus / nolog > to_file.log
    and it wait in poll(0x9fffffffffff5.... :
    socket(AF_INET, SOCK_DGRAM, 0) ...................................................................................................... = 7
    sendto(7, "b19601\0\001\0\0\0\0\0\0\bb u r ".., 26, 0, 0x6000000000417560, 0x10) .................................................... = 26
    gettimeofday(0x9fffffffffff5ec0, NULL) .............................................................................................. = 0
    poll(0x9fffffffffff5ee0, 1, 10000) .................................................................................................. [sleeping]
    poll(0x9fffffffffff5ee0, 1, 10000) .................................................................................................. = 0
    processor and memory is ok without pick
    Do You have any idea wher is problem ? because database in oracle home 11g work ok in this home , when I connect from remote sqlplus client though sqlnet
    Thank You Brano

    Try [url http://download.oracle.com/docs/cd/E11882_01/network.112/e10835/sqlnet.htm#BIIIJHGH]sqlnet tracing. Charles Hooper has some more detailed examples of using a network monitoring tool: http://hoopercharles.wordpress.com/category/network-monitoring/
    You might consider we don't have crystal balls and can't quite understand what little you've told us. What is the client? What is pick?

  • Sequence diagram lifeline in Oracle BPA Suite

    I try to create sequence diagram in Oracle Busines Process Architect 11g. I use type of model "UML Sequence diagram". But in palette there is no object with type "Lifeline". How can I add lifelines to my sequence diagram?

    i guess you are clicking on file>new>model , or something like that.
    y dont you first go to designer/explorer , make sure you see the navigator frame, and click on "local" in navigator frame to start the local database first. adn then login to any database to create a model/group.
    In case it does not even happen then, and it still says unable to start the local server, check out the logs in <Oracle BPA Suite>\LocalServer\log directory and check what the error is.

  • Handling Sequence of Services in Oracle Service Bus 11g

    Hi there,
    I am very new to Oracle Service Bus, I want to achieve the following sequence of operations in OSB, please help me or guide me how to achieve it in sequence manner.
    1) Transfer .txt file from STFP server to local shared folder.
    2) Calling EJB service to process (Read the file) and insert/update in DB.
    3) Once the EJB service operation is over, transfer the file from local folder "Inbox" to local folder "archive" folder.
    4) Sent the success or failure batch job email message to administrator.
    Thanks in Advance.
    Regards,
    Raj

    Hi,
    I've created the 2 Proxy services and related business services, one service is used to move the file from one location to another and another service is used to call the EJB (using JEJB transport). I am using the sequential service call to call one after another (1st Move file then Call JEJB). The following error I am getting, pls help me to resolve this issue.
    <Jun 3, 2013 11:48:47 AM SGT> <Error> <OSB Kernel> *<BEA-380003> <Exception on TransportManagerImpl.sendMessageAsync: unchecked exception:, java.lang.IllegalStat*
    **eException: [JEJBTransport:387313]Colocated call is not supported by JEJB transp ort provider.*java.lang.IllegalStateException: [JEJBTransport:387313]Colocated call is not supported by JEJB transport provider.*
    at com.bea.wli.sb.transports.jejb.JEJBTransportProvider.sendMessageAsync
    (JEJBTransportProvider.java:860)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
    java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
    sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    Truncated. see log file for complete stacktrace
    >
    Thanks.
    Edited by: 966429 on Jun 3, 2013 2:45 AM

Maybe you are looking for

  • Please Help... Photoshop Misbehaving?

    Hi guys, I've been a photoshop user for years and have never encountered anything like this in the past. I was running PS CS6 with no problems for months. Suddenly without any change to the computer that I am aware of, PS will not Open or Create New

  • Transaction timeout for FTP Put as an attachment

    Hi, When I am trying to get a file from E Business Suite(Oracle Apps) and place the same in to FTP Outbound as an attachment, I am getting the below exception. This did not happen in PS2 but it is happening in PS3(11.11.1.4) with the same code, can s

  • View Java Stored Procedures

    Hello, How can I find the names of Java stored procedures created in the database and what are the published stored procedures? thanks Ranganath Samudrala

  • IPod 1st generation exploded in my hand, i was listening to music. How can i contact them?

    I was listening to music one night last week and my 1st generation nano exploded in my hand and my first reaction was throwing it on the floor because i was too scared to react properly and when i saw that it was still burning i took the headset cabl

  • TPM BIOS Dialog Asks To Clear TPM - Dialog is not touch sensitive and will not proceed

    When resetting Windows 10 on my Stream 8 it sends a request to the BIOS to clear the TPM after reaching 100%.  The problem is that this dialog is not touch aware.  I can't choose either option.  Powering down the tablet just brings this back up when