Override a Look Up SQL Query

Is it possible to override the look up SQL query in the Key Look Up Operator?
Suppose I want to run the following query
select customer, max(revenue) from CUSTOMER group by customer_id and then look up the customer id and get the max revenue from the look up and populate the target table.
Is it possible with a Key Look Up operator or we need to use an aggregator and join it with the main flow.

You are spot on. Thats what I have experienced while working with OWB for the last couple of months.
1.The look up is actually a join. Dont understand then why it is called a look up. It should have been called a pseudo joiner.
2. The second irritating part is - there is nothing called a multiple look up match policy. If more than one records are matched,then the records loaded to the target are also increased. You dont have something called " Select first match " or "Select last match" etc etc.
3. You dont have the facility to override the look up query, which can at times be required and can be a very smart way of doing a mapping.
3. Due to this poor functionality of the key look up operator, I was myself compelled to split a single innocent looking mapping to two parts, which is painful.
An ETL tool having this kind of look up functionality, I am afraid is pathetic.
I am eager to see what changes they make in 10g R2 if at all.#
regards
-Arnab

Similar Messages

  • Sql query to find all contacts for an account

    I wonder if someone wrote an sql query to find all contacts for an account number in Oracle customer master. We are on EBS 11.5.10.
    I am also looking for sql query to find all ship to addresses for an account number.
    Thanks.

    Can you also post the query for people who read this post and are also looking for an answer?
    Regards,
    Johan Louwers.

  • SQL query to get DDL for Adding PK.

    Guys,
    I'm looking for SQL query that gets me the "ALTER TABLE <TABLE_NAME> ADD CONSTRAINT <constraint_name> PRIMARY KEY (X,Y,...);" statments of all tables in my schema containing Primary Keys.
    Could someone help me with the query please?
    Regards,
    Bhagat

    You need this
    SELECT 'ALTER TABLE '||table_name||' ADD CONSTRAINT '||constraint_name||' PRIMARY KEY ('||column_name||');'
      FROM ( SELECT uc.table_name
                   ,uc.constraint_name
                   ,RTRIM (XMLAGG (XMLELEMENT (ucc, column_name || ',')).extract ('//text()'), ',')  column_name
              FROM user_constraints        uc
                  ,user_cons_columns       ucc
             WHERE uc.constraint_type      = 'P'
               AND uc.constraint_name      = ucc.constraint_name
          GROUP BY uc.table_name
                  ,uc.constraint_name
    ORDER BY table_name;   Regards
    Arun

  • Complete novice needs help getting SQL Query into Crystal Reports XI

    Post Author: MissMarnie
    CA Forum: Data Connectivity and SQL
    So I was given an intro level web course and a monster reference guide in prep to format a report. One of our developers wrote me everything I need for the report into a SQL Query and now I'm supposed to format it in CR XII literally do not know what to do from here. I'm able to set up the correct server as a datasource, if that's useful, but I don't know how to make the querey into a bunch of formattable fields in  CR. If anyone can walk me through this, I'd be so grateful. I've attempted to look up SQL query in both the help and the book but I keep hitting a wall. The help dialog says things like "press this button" with no reference to what "this button" is. I'm sure it's obvious to the knowledgeable but I'm in a complete fog. Thanks in advance   

    Post Author: synapsevampire
    CA Forum: Data Connectivity and SQL
    IF you're trying to get assistance with setting up a query as the source for a report, try posting your Crystal version and the database type.
    Different software works differently.
    In CR 9 and above, under the connection to the database you'll see Add Command. Select that and you can paste the query in.
    As for not knowing how to generate a report, that requires experience, there's no generic solution of course..
    -k

  • How to find out which Tables have been accessed without looking at the SQL query ?

    Hi,
    I would like to know is there a way to find out what queries have been executed and on which tables without looking at the SQL query.
    I have an old C++ code which calls some library functions to access the Oracle database. The source code for the library is not available to me yet. The functions selects/updates/deletes and inserts based on some input parameters I give. I do not know which tables it affects. How do I find out the actual SQL query and/or the tables it accesses ? I was told about V$SQL table that
    has the most recently executed queries, but
    I did'nt see any queries connected to my process.
    Could anybody help me on this ?
    Thanks
    Jagdeep
    [email protected]
    null

    PRECISE/SQL can help you if you have access to it
    2nd option can be that turn on SQL_TRACE
    Run executable of ur c++ program
    it will create a trace file in user_dump_dest
    and then using TKPROF u can see all quesries and their plan also.
    HTH
    Gagan Deep Singh
    <BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by (jagdeeps):
    Hi,
    I would like to know is there a way to find out what queries have been executed and on which tables without looking at the SQL query.
    I have an old C++ code which calls some library functions to access the Oracle database. The source code for the library is not available to me yet. The functions selects/updates/deletes and inserts based on some input parameters I give. I do not know which tables it affects. How do I find out the actual SQL query and/or the tables it accesses ? I was told about V$SQL table that
    has the most recently executed queries, but
    I did'nt see any queries connected to my process.
    Could anybody help me on this ?
    Thanks
    Jagdeep
    [email protected]<HR></BLOCKQUOTE>
    null

  • Looking for and SQL query to match CTI OS agent login ID with the Directory Number (instrument)

    Hi All,
    I am looking for an SQL query to request the HDS database to find out which Directory Number / instrument  was associated with a specific CTI OS agent login ID.
    Has anyone done such a query before ?
    Thanks and Regards
    Nick

    Hi,
    this should work in 8.0 and 8.5:
    SELECT
    ag.PeripheralNumber AS [LoginID],
    al.Extension,
    al.LogoutDateTime
    FROM [instance]_hds.dbo.Agent_Logout al
    JOIN [instance]_awdb.dbo.Agent ag ON al.SkillTargetID = ag.SkillTargetID
    Of course, replace [instance] with the ICM instance.
    The query returns a table with three columns, first is the login ID aka PeripheralNumber, Extension is... well, the agent's extension, and LogoutDateTime is the timestamp when the agent logged out.
    G.

  • [SOLVED]overriding VO's SQL query in an application module

    Hi, can anybody help me in searching examples of everriding some aspects of VO in an application module.
    As i learned we can override, for example the "WHERE" clause of an VO's SQL query in different application modules, using as i supply the addWhereClause method on SomeViewObjImpl object.
    ... but are there any examples of using this possibility? Should i create a custom method in application module java class?
    Thanks in advance. Best Regards.Alex.
    Message was edited by:
    Timin
    Message was edited by:
    Timin

    Hi, can anybody help me in searching examples of everriding some aspects of VO in an application module.
    As i learned we can override, for example the "WHERE" clause of an VO's SQL query in different application modules, using as i supply the addWhereClause method on SomeViewObjImpl object.
    ... but are there any examples of using this possibility? Should i create a custom method in application module java class?
    Thanks in advance. Best Regards.Alex.
    Message was edited by:
    Timin
    Message was edited by:
    Timin

  • Looking for a SQL query to get all the possible Alert Messages from the Rules in a Management Pack

    For reporting, I'm looking to get a SQL query of all the possible Alert Messages for Rules configured in a Management Pack (not necessarily the ones that have thrown alerts).  I can do this for Monitors, but not for Rules. 
    The configured alert messages for the Management Pack Monitors
    go like this:  ManagementPack > MonitorView> RuleModule > RuleModule.Alert Message > Localized Text
    The configured alert messages for the Management Pack Rules
    should go something like this, but there is a missing link:  ManagementPack > RuleView > RuleModule > ? Missing Link ? > Localized Text
    The Rules are tied to the Module, but I don't see a connection from the RulesModule to the Alert Message that I see in the LocalizedText. The Rule names do not always equal the Alert name. 
    Can someone provide the missing link?

    Hi,
    please try below powershell code to find the corresponding management pack for specific alert:
    $Alert = get-scomalert | where {$_.Name -like 'Agent Proxy Not Enabled*'} | select -first 1
    If ($alert.IsMonitorAlert -eq "True") {
    write-host "Ths is a monitor-generated alert"
    get-scommonitor -ID $Alert.MonitoringRuleID | select Enabled, DisplayName, ManagementPack
    else
    write-host "This is a rule-generated alert"
    get-scomrule -ID $Alert.MonitoringRuleID | select Enabled, DisplayName, ManagementPack
    In addition, please also refer to the below link:
    http://blogs.technet.com/b/mazenahmed/archive/2011/12/02/using-powershell-to-map-opsmgr-active-alert-to-its-corresponding-rule-monitor-and-management-pack-name.aspx
    Regards,
    Yan Li
    Regards, Yan Li

  • Looking for an SQL query to retreive callvariables + ECC from a RUN SCRIPT RESULT (Translation to VRU)

    Hi Team,
    I am looking for an SQL query to check the data (ECC + CallVariable) received following a RUN SCRIPT RESULT when requesting an external VRU with a Translation Route to VRU with a "Run External Script".
    I believe the data are parsed between the Termination Call Detail + Termination Call Variable .
    If you already have such an SQL query I would very much appreciate to have it.
    Thank you and Regards
    Nick

    Omar,
    with all due respect, shortening a one day's interval might not be an option for a historical report ;-)
    I would recommend to take a look the following SQL query:
    DECLARE @dateFrom DATETIME, @dateTo DATETIME
    SET @dateFrom = '2014-01-24 00:00:00'
    SET @dateTo   = '2014-01-25 00:00:00'
    SELECT
    tcv.DateTime,
    tcd.RecoveryKey,
    tcd.RouterCallKeyDay,
    tcd.RouterCallKey,
    ecv.EnterpriseName AS [ECVEnterpriseName],
    tcv.ArrayIndex,
    tcv.ECCValue
    FROM Termination_Call_Variable tcv
    JOIN
    (SELECT RouterCallKeyDay,RouterCallKey,RecoveryKey FROM Termination_Call_Detail WHERE DateTime > @dateFrom AND DateTime < @dateTo) tcd
    ON tcv.TCDRecoveryKey = tcd.RecoveryKey
    LEFT OUTER JOIN Expanded_Call_Variable ecv ON tcv.ExpandedCallVariableID = ecv.ExpandedCallVariableID
    WHERE tcv.DateTime > @dateFrom AND tcv.DateTime < @dateTo
    With variables, you can parametrize your code (for instance, you could write SET @dateFrom = ? and let the calling application fill in the datetime value in for you).
    Plus joining two large tables with all rows like you did (TCD-TCV) is never a good option.
    Another aspect to consider: all ECC's are actually arrays (always), so it's not good to leave out the index value (tcv.ArrayIndex).
    G.

  • SQL Query Help Needed

    I'm having trouble with an SQL query. I've created a simple logon page wherein a user will enter their user name and password. The program will look in an Access database for the user name, sort it by Date/Time modified, and check to see if their password matches the most recent password. Unfortunately, the query returns no results. I'm absolutely certain that I'm doing the query correctly (I've imported it directly from my old VB6 code). Something simple is eluding me. Any help would be appreciated.
    private void LogOn() {
    //make sure that the user name/password is valid, then load the main menu
    try {
    //open the database connection
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Connection con = DriverManager.getConnection("jdbc:odbc:LawOffice2000", "", "");
    Statement select = con.createStatement();
    String strTemp = "Select * From EMPLOYEES Where INITIALS = '" + txtUserName.getText() + "' Order By DATE Desc, TIME Desc";
    ResultSet result = select.executeQuery(strTemp);
    while(result.next()) {
    if (txtPassword.getPassword().toString() == result.getString("Password")) {
    MenuMain.main();
    else {
    System.out.println("Password Bad");
    System.out.println(txtUserName.getText());
    System.out.println(result.getString("Password"));
    break; //exit loop
    //close the connection
    con.close(); }
    catch (Exception e) {
    System.out.println("LawOfficeSuite_LogOn: " + e);
    return; }
    }

    The problem is here: "txtPassword.getPassword().toString() == result.getString("Password"))"
    Don't confuse String's equals() method with the equality operator '=='. The == operator checks that two references refer to the same object. If you want to compare the contents of Strings (whether two strings contain the same characters), use equals(), e.g. if (str1.equals(str2))...
    Example:String s1 = "foo";
    String s2 = new String("foo");
    System.out.println("s1 == s2: " + (s1 == s2)); // false
    System.out.println("s1.equals(s2): " + (s1.equals(s2))); // trueFor more information, check out Comparison operators: equals() versus ==

  • Need Help in Splitting a String Using SQL QUERY

    Hi,
    I need help in splitting a string using a SQL Query:
    String IS:
    AFTER PAINT.ACOUSTICAL.1..9'' MEMBRAIN'I would like to seperate this string into multiple lines using the delimeter .(dot)
    Sample Output should look like:
    SNO       STRING
    1            AFTER PAINT
    2            ACOUSTICAL
    3            1
    4            
    5            9" MEMBRAIN
    {code}
    FYI i am using Oracle 9.2                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    There's this as well:
    with x as ( --generating sample data:
               select 'AFTER PAINT.ACOUSTICAL.1..9" MEMBRAIN' str from dual union all
               select 'BEFORE PAINT.ELECTRIC.2..45 caliber MEMBRAIN' str from dual)
    select str,
           row_number() over (partition by str order by rownum) s_no,
           cast(dbms_xmlgen.convert(t.column_value.extract('//text()').getstringval(),1) as varchar2(100)) res
    from x,
         table(xmlsequence(xmltype('<x><x>' || replace(str,'.','</x><x>') || '</x></x>').extract('//x/*'))) t;
    STR                                                S_NO RES                                                                                                
    AFTER PAINT.ACOUSTICAL.1..9" MEMBRAIN                 1 AFTER PAINT                                                                                        
    AFTER PAINT.ACOUSTICAL.1..9" MEMBRAIN                 2 ACOUSTICAL                                                                                         
    AFTER PAINT.ACOUSTICAL.1..9" MEMBRAIN                 3 1                                                                                                  
    AFTER PAINT.ACOUSTICAL.1..9" MEMBRAIN                 4                                                                                                    
    AFTER PAINT.ACOUSTICAL.1..9" MEMBRAIN                 5 9" MEMBRAIN                                                                                        
    BEFORE PAINT.ELECTRIC.2..45 caliber MEMBRAIN          1 BEFORE PAINT                                                                                       
    BEFORE PAINT.ELECTRIC.2..45 caliber MEMBRAIN          2 ELECTRIC                                                                                           
    BEFORE PAINT.ELECTRIC.2..45 caliber MEMBRAIN          3 2                                                                                                  
    BEFORE PAINT.ELECTRIC.2..45 caliber MEMBRAIN          4                                                                                                    
    BEFORE PAINT.ELECTRIC.2..45 caliber MEMBRAIN          5 45 caliber MEMBRAIN      
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to create a Matrix table using this data in SQL Query Analyzer

    Hello all,
    I have a problem while I am trying to represent my Sql Table namely table1 in Matrix form
    my table Format is
    city1 city2 Distance--------------------------------------------------------
    Mumbai Delhi 100
    Delhi Banaras 50
    Mumbai Rajasthan 70
    Banaras haryana 40
    Mumbai Mumbai 0
    784 entries
    there are 784 cities each having link to other
    Now i want my output as
    Mumbai Delhi Banaras haryana
    Mumbai 0 100 -- --
    Delhi 100 0 50 --
    Banaras
    haryana
    respective distance from one city to other should be shown
    final Matrix would be 784*784
    I am using SQL Query Analyser for this
    Please help me in this regard

    I'm pretty much certain that you don't want to do this in pure SQL. So that means that you want to do it with a reporting tool. I'm not familiar with SQL Query Analyzer, but if it is in fact a reporting tool you'll want to consult its documentation looking for the terms "pivot" or perhaps "cross tab."

  • Retreving Hexadecimal Values from a table using SQL query.

    Hi,
    I'm looking for a query to retreive Hexadecimal values contained in a column using SQL query.
    The column contains the values of all types, alphanumeric, numeric and hexadecimal.
    I need to retreive only hexadecimal values.
    any help to me in this regard will be appreciated.
    Thanks

    Presumably, you can be sure that any valid hex value is indeed MEANT to BE a hex value. For example the value 'ACE' is meant to be a hexadecimal value and not the word.

  • How to tune this SQL Query?

    Hi all expert out there,
    I am using Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production With the Partitioning, Real Application Clusters, OLAP, Data Mining and Real Application Testing options.
    I have this ERP 11i query took 3-4hours to execute. can anyone help to have a look at the Query so make it more faster? I am already out of my idea of solving this. Kindly helpzzz...
    SELECT
    /*+ first_rows(1)*/
    hou.name "OU" ,-- e.g. Seagate Technology USOP1 ,
    mc.description,
    oel.ordered_item "Product Part Number",
    oeh.order_number "Order Num",
    hp.party_name "Bill To Cust Name",
    hcsu.location "Ship To Cust Num",
    oel.line_number || '.' || oel.shipment_number "Order Line Num",
    ft.nls_territory "Ship To Country",
    mc.segment7 "designapplication",
    ccm.formattedcapacity||'GB' "Capacity",
    oel.attribute1 "Order Category",
    oel.Subinventory "Subinventory",
    to_char(oel.actual_shipment_date,'MM/DD/YYYY DY') "Shipment Date",
    NVL(oel.shipped_quantity,0) "Net Units"
    FROM
    oe_order_headers_all oeh
    ,oe_order_lines_all oel
    ,apps.hz_parties hp
    ,apps.hz_cust_accounts hca
    ,apps.hz_cust_site_uses_all hcsu
    ,apps.hz_cust_acct_sites_all hcas
    , apps.seaeng_ccfamilymodelinfo ccm
    ,apps.hz_party_sites hps
    ,apps.fnd_territories ft
    ,apps.hz_locations hl
    ,apps.hr_organization_units hou
    ,apps.mtl_parameters mp
    ,apps.mtl_item_categories mic
    ,apps.mtl_categories_b mc
    ,apps.fnd_lookup_values flv
    WHERE
    oeh.header_id = oel.header_id
    AND oel.flow_status_code = 'CLOSED'
    AND oeh.invoice_to_org_id = hcsu.site_use_id
    AND hl.country = ft.territory_code
    AND hps.location_id = hl.location_id
    AND hcas.party_site_id = hps.party_site_id
    AND hcsu.cust_acct_site_id = hcas.cust_acct_site_id
    AND hcas.cust_account_id = hca.cust_account_id
    AND hca.party_id = hp.party_id
    AND oeh.org_id = hou.organization_id
    AND oel.ship_from_org_id = mp.organization_id
    AND oel.inventory_item_id = mic.inventory_item_id
    AND mic.category_id = mc.category_id
    AND mic.category_set_id = 4
    AND mc.description = ccm.stmodelnumber
    AND flv.lookup_code = hca.sales_channel_code
    AND flv.lookup_type = 'SALES_CHANNEL'
    AND mc.segment7 IN ('PSG','ESG','NSG')
    AND flv.lookup_code NOT IN ('RTL','AD-RTL','EU')
    AND oel.attribute1 IN ('NB','NBEOL','NBSEA')
    AND oel.subinventory IN ('KFGI','AFGI','SFGIF','FGIF')
    AND hou.organization_id = 189
    AND trunc(oel.actual_shipment_date) between TO_DATE('01-Jan-2009','DD-MON-YYYY') and TO_DATE('31-JAN-2009','DD-MON-YYYY')
    regards,
    Lygine
    Edited by: user8989062 on Jun 7, 2010 6:39 PM

    5) The TKPROF output for this statement looks like the following:
    SELECT
    /*+ first_rows(1)*/
    hou.name "OU" ,-- e.g. Seagate Technology USOP1 ,
    mc.description,
    oel.ordered_item "Product Part Number",
    oeh.order_number "Order Num",
      hp.party_name  "Bill To Cust Name",
    hcsu.location "Ship To Cust Num",
    oel.line_number || '.' || oel.shipment_number "Order Line Num",
    ft.nls_territory  "Ship To Country",
    mc.segment7 "designapplication",
    ccm.formattedcapacity||'GB' "Capacity",
    oel.attribute1 "Order Category",
    oel.Subinventory "Subinventory",
    to_char(oel.actual_shipment_date,'MM/DD/YYYY DY') "Shipment Date",
    NVL(oel.shipped_quantity,0) "Net Units"
    FROM
          oe_order_headers_all oeh
         ,oe_order_lines_all   oel
         ,apps.hz_parties  hp
         ,apps.hz_cust_accounts  hca
         ,apps.hz_cust_site_uses_all   hcsu
         ,apps.hz_cust_acct_sites_all  hcas
        , apps.seaeng_ccfamilymodelinfo ccm
         ,apps.hz_party_sites hps
         ,apps.fnd_territories ft
         ,apps.hz_locations hl
         ,apps.hr_organization_units  hou
         ,apps.mtl_parameters  mp
         ,apps.mtl_item_categories mic
         ,apps.mtl_categories_b mc
         ,apps.fnd_lookup_values flv
    WHERE
               oeh.header_id = oel.header_id
    AND   oel.flow_status_code = 'CLOSED'
    AND   oeh.invoice_to_org_id = hcsu.site_use_id
    AND   hl.country = ft.territory_code
    AND   hps.location_id = hl.location_id
    AND   hcas.party_site_id = hps.party_site_id
    AND   hcsu.cust_acct_site_id = hcas.cust_acct_site_id
    AND   hcas.cust_account_id = hca.cust_account_id
    AND   hca.party_id   = hp.party_id
    AND   oeh.org_id = hou.organization_id
    AND   oel.ship_from_org_id = mp.organization_id
    AND   oel.inventory_item_id = mic.inventory_item_id
    AND   mic.category_id = mc.category_id
    AND   mic.category_set_id = 4
    AND   mc.description = ccm.stmodelnumber
    AND   flv.lookup_code = hca.sales_channel_code
    AND   flv.lookup_type = 'SALES_CHANNEL'
    AND mc.segment7 IN ('PSG','ESG','NSG')
    AND flv.lookup_code NOT IN ('RTL','AD-RTL','EU')
    AND oel.attribute1 IN ('NB','NBEOL','NBSEA')
    AND oel.subinventory IN ('KFGI','AFGI','SFGIF','FGIF')
    AND hou.organization_id = 189
    AND trunc(oel.actual_shipment_date) between TO_DATE('01-Jan-2009','DD-MON-YYYY') and TO_DATE('31-JAN-2009','DD-MON-YYYY')
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.79       0.79          0          0          0           0
    Execute      1      0.00       0.00          0          0          0           0
    Fetch        7     22.23     240.85      19781     536082          0         592
    total        9     23.02     241.64      19781     536082          0         592
    Misses in library cache during parse: 1
    Optimizer mode: FIRST_ROWS
    Parsing user id: 173 
    Rows     Row Source Operation
        592  NESTED LOOPS  (cr=536082 pr=19781 pw=0 time=240822989 us)
        592   NESTED LOOPS  (cr=534885 pr=19776 pw=0 time=239960969 us)
        592    NESTED LOOPS  (cr=533688 pr=19776 pw=0 time=239902332 us)
        594     NESTED LOOPS  (cr=532493 pr=19776 pw=0 time=239811721 us)
        594      NESTED LOOPS  (cr=531892 pr=19776 pw=0 time=239794703 us)
        594       NESTED LOOPS  (cr=530693 pr=19772 pw=0 time=239325284 us)
        594        NESTED LOOPS  (cr=529498 pr=19770 pw=0 time=239152940 us)
        594         NESTED LOOPS  (cr=527709 pr=19766 pw=0 time=236850676 us)
        594          NESTED LOOPS  (cr=525920 pr=19764 pw=0 time=235640068 us)
       2990           NESTED LOOPS  (cr=516943 pr=19688 pw=0 time=195144282 us)
       2990            NESTED LOOPS  (cr=516936 pr=19688 pw=0 time=195120297 us)
       2990             NESTED LOOPS  (cr=510806 pr=19682 pw=0 time=194678671 us)
       3000              HASH JOIN  (cr=504799 pr=19669 pw=0 time=193829763 us)
       3000               NESTED LOOPS  (cr=472280 pr=360 pw=0 time=49218087 us)
          1                NESTED LOOPS  (cr=1029 pr=34 pw=0 time=1745829 us)
          1                 TABLE ACCESS BY INDEX ROWID HR_ALL_ORGANIZATION_UNITS_TL (cr=424 pr=25 pw=0 time=1361442 us)
          1                  INDEX UNIQUE SCAN HR_ALL_ORGANIZATION_UNTS_TL_PK (cr=423 pr=25 pw=0 time=1361397 us)(object id 44637)
          1                 TABLE ACCESS BY INDEX ROWID HR_ALL_ORGANIZATION_UNITS (cr=605 pr=9 pw=0 time=384370 us)
          1                  INDEX UNIQUE SCAN HR_ORGANIZATION_UNITS_PK (cr=1 pr=0 pw=0 time=27 us)(object id 43498)
       3000                TABLE ACCESS BY INDEX ROWID OE_ORDER_LINES_ALL (cr=471251 pr=326 pw=0 time=47466249 us)
    156922                 INDEX RANGE SCAN OE_ORDER_LINES_N20 (cr=420 pr=7 pw=0 time=787919 us)(object id 37005064)
    263469               TABLE ACCESS FULL MTL_ITEM_CATEGORIES (cr=32519 pr=19309 pw=0 time=144242743 us)
       2990              TABLE ACCESS BY INDEX ROWID MTL_CATEGORIES_B (cr=6007 pr=13 pw=0 time=843569 us)
       3000               INDEX UNIQUE SCAN MTL_CATEGORIES_B_U1 (cr=3007 pr=2 pw=0 time=162636 us)(object id 37199)
       2990             TABLE ACCESS BY INDEX ROWID SEAENG_CCFAMILYMODELINFO (cr=6130 pr=6 pw=0 time=437784 us)
       2990              INDEX UNIQUE SCAN SEAENG_CCFAMILYMODELINFO_U1 (cr=2997 pr=0 pw=0 time=52872 us)(object id 35838918)
       2990            INDEX UNIQUE SCAN MTL_PARAMETERS_U1 (cr=7 pr=0 pw=0 time=16332 us)(object id 37657)
        594           TABLE ACCESS BY INDEX ROWID OE_ORDER_HEADERS_ALL (cr=8977 pr=76 pw=0 time=40491633 us)
       2990            INDEX UNIQUE SCAN OE_ORDER_HEADERS_U1 (cr=5987 pr=45 pw=0 time=2504442 us)(object id 41952)
        594          TABLE ACCESS BY INDEX ROWID HZ_CUST_SITE_USES_ALL (cr=1789 pr=2 pw=0 time=1208576 us)
        594           INDEX UNIQUE SCAN HZ_CUST_SITE_USES_U1 (cr=1195 pr=1 pw=0 time=105934 us)(object id 25124976)
        594         TABLE ACCESS BY INDEX ROWID HZ_CUST_ACCT_SITES_ALL (cr=1789 pr=4 pw=0 time=2300224 us)
        594          INDEX UNIQUE SCAN HZ_CUST_ACCT_SITES_U1 (cr=1195 pr=2 pw=0 time=152238 us)(object id 25124996)
        594        TABLE ACCESS BY INDEX ROWID HZ_PARTY_SITES (cr=1195 pr=2 pw=0 time=170875 us)
        594         INDEX UNIQUE SCAN HZ_PARTY_SITES_U1 (cr=601 pr=1 pw=0 time=104550 us)(object id 25124993)
        594       TABLE ACCESS BY INDEX ROWID HZ_LOCATIONS (cr=1199 pr=4 pw=0 time=467329 us)
        594        INDEX UNIQUE SCAN HZ_LOCATIONS_U1 (cr=601 pr=0 pw=0 time=57749 us)(object id 25124992)
        594      TABLE ACCESS BY INDEX ROWID FND_TERRITORIES (cr=601 pr=0 pw=0 time=15562 us)
        594       INDEX UNIQUE SCAN FND_TERRITORIES_U1 (cr=7 pr=0 pw=0 time=6492 us)(object id 33083)
        592     TABLE ACCESS BY INDEX ROWID HZ_CUST_ACCOUNTS (cr=1195 pr=0 pw=0 time=88925 us)
        594      INDEX UNIQUE SCAN HZ_CUST_ACCOUNTS_U1 (cr=601 pr=0 pw=0 time=27607 us)(object id 81600)
        592    INDEX RANGE SCAN FND_LOOKUP_VALUES_U1 (cr=1197 pr=0 pw=0 time=56714 us)(object id 32878)
        592   TABLE ACCESS BY INDEX ROWID HZ_PARTIES (cr=1197 pr=5 pw=0 time=860140 us)
        592    INDEX UNIQUE SCAN HZ_PARTIES_U1 (cr=599 pr=0 pw=0 time=51136 us)(object id 25126074)
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       7        0.00          0.00
      row cache lock                                  1        0.00          0.00
      gc current block 2-way                      24112        0.00         19.28
      gc cr grant 2-way                             406        0.00          0.19
      db file sequential read                       441        0.09         14.11
      gc cr block 2-way                             284        0.00          0.23
      gc cr block busy                              147        0.19          9.59
      gc current block congested                      2        0.00          0.00
      gc cr multi block request                   13079        0.00          3.98
      SQL*Net message from client                     7        0.27          1.87
      gc cr failure                                  39        0.00          0.02
      cr request retry                               39        0.98         38.27
      SQL*Net more data to client                    12        0.00          0.00
      db file scattered read                       2446        0.13        132.58
      gc cr disk read                                 5        0.00          0.00
    ********************************************************************************6) The DBMS_XPLAN.DISPLAY_CURSOR output:
    SQL> select * from table(dbms_xplan.display_cursor(null, null, 'ALLSTATS LAST'));
    PLAN_TABLE_OUTPUT
    SQL_ID  b8pfhfxscqn1m, child number 0
    SELECT  /*+ gather_plan_statistics */  hou.name "OU" ,-- e.g. Seagate Technology USOP1 ,  mc.descript
    oeh.order_number "Order Num",   hp.party_name  "Bill To Cust Name",  hcsu.location "Ship To Cust Num",
    Num",  ft.nls_territory  "Ship To Country",  mc.segment7 "designapplication",  ccm.formattedcapacity
    oel.Subinventory "Subinventory",  to_char(oel.actual_shipment_date,'MM/DD/YYYY DY') "Shipment Date",
    oe_order_headers_all oeh      ,oe_order_lines_all   oel      ,apps.hz_parties  hp      ,apps.hz_cust
    ,apps.hz_cust_acct_sites_all  hcas     , apps.seaeng_ccfamilymodelinfo ccm      ,apps.hz_party_sites hps
        ,apps.hr_organization_units  hou      ,apps.mtl_paramete
    Plan hash value: 414863479
    | Id  | Operation                                  | Name                           | Starts | E-Rows | A-Rows |   A-Time   | Buffers | Reads  |  O
    |   1 |  NESTED LOOPS                              |                                |      1 |      1 |    592 |00:02:25.13 |     535K|  57267 |       |
    |   2 |   NESTED LOOPS                             |                                |      1 |      1 |    592 |00:02:24.22 |     533K|  57185 |      
    |   3 |    NESTED LOOPS                            |                                |      1 |      1 |    592 |00:02:24.15 |     532K|  57183 |     
    |   4 |     NESTED LOOPS                           |                                |      1 |      1 |    594 |00:02:24.00 |     531K|  57171 |     
    |   5 |      NESTED LOOPS                          |                                |      1 |      1 |    594 |00:02:23.98 |     530K|  57170 |    
    |   6 |       NESTED LOOPS                         |                                |      1 |      1 |    594 |00:02:23.49 |     529K|  57129 |   
    |   7 |        NESTED LOOPS                        |                                |      1 |      1 |    594 |00:02:23.08 |     528K|  57096 |  
    |   8 |         NESTED LOOPS                       |                                |      1 |      1 |    594 |00:02:22.51 |     526K|  57031 |       |
    |   9 |          NESTED LOOPS                      |                                |      1 |      1 |    594 |00:02:21.79 |     524K|  56968 |       |
    |  10 |           NESTED LOOPS                     |                                |      1 |      1 |   2990 |00:02:09.65 |     515K|  55703 |      
    |  11 |            NESTED LOOPS                    |                                |      1 |      1 |   2990 |00:02:09.62 |     515K|  55703 |     
    |  12 |             NESTED LOOPS                   |                                |      1 |      1 |   2990 |00:02:08.47 |     509K|  55599 |     
    |* 13 |              HASH JOIN                     |                                |      1 |      2 |   3000 |00:02:07.88 |     503K|  55516 |   974K
    |  14 |               NESTED LOOPS                 |                                |      1 |      2 |   3000 |00:01:39.07 |     471K|  23025 |   
    |  15 |                NESTED LOOPS                |                                |      1 |      1 |      1 |00:00:00.01 |       4 |      0 |  
    |  16 |                 TABLE ACCESS BY INDEX ROWID| HR_ALL_ORGANIZATION_UNITS_TL   |      1 |      1 |      1 |00:00
    |* 17 |                  INDEX UNIQUE SCAN         | HR_ALL_ORGANIZATION_UNTS_TL_PK |      1 |      1 |      1 |00:00:00.0
    |* 18 |                 TABLE ACCESS BY INDEX ROWID| HR_ALL_ORGANIZATION_UNITS      |      1 |      1 |      1 |00:00:
    |* 19 |                  INDEX UNIQUE SCAN         | HR_ORGANIZATION_UNITS_PK       |      1 |      1 |      1 |00:00:00.01
    |* 20 |                TABLE ACCESS BY INDEX ROWID | OE_ORDER_LINES_ALL             |      1 |      2 |   3000 |00:01
    |* 21 |                 INDEX RANGE SCAN           | OE_ORDER_LINES_N20             |      1 |  47575 |    156K|00:00:01.76 |     420
    |* 22 |               TABLE ACCESS FULL            | MTL_ITEM_CATEGORIES            |      1 |  96977 |    263K|00:00:28.49
    |* 23 |              TABLE ACCESS BY INDEX ROWID   | MTL_CATEGORIES_B               |   3000 |      1 |   2990 |00:00:0
    |* 24 |               INDEX UNIQUE SCAN            | MTL_CATEGORIES_B_U1            |   3000 |      1 |   3000 |00:00:00.21
    |  25 |             TABLE ACCESS BY INDEX ROWID    | SEAENG_CCFAMILYMODELINFO       |   2990 |      1 |   2990 |
    |* 26 |              INDEX UNIQUE SCAN             | SEAENG_CCFAMILYMODELINFO_U1    |   2990 |      1 |   2990 |00:00:
    |* 27 |            INDEX UNIQUE SCAN               | MTL_PARAMETERS_U1              |   2990 |      1 |   2990 |00:00:00.02 |    
    |* 28 |           TABLE ACCESS BY INDEX ROWID      | OE_ORDER_HEADERS_ALL           |   2990 |      1 |    594 |00:00:
    |* 29 |            INDEX UNIQUE SCAN               | OE_ORDER_HEADERS_U1            |   2990 |      1 |   2990 |00:00:04.29 |   
    |  30 |          TABLE ACCESS BY INDEX ROWID       | HZ_CUST_SITE_USES_ALL          |    594 |      1 |    594 |00:00:
    |* 31 |           INDEX UNIQUE SCAN                | HZ_CUST_SITE_USES_U1           |    594 |      1 |    594 |00:00:00.31 |   
    |  32 |         TABLE ACCESS BY INDEX ROWID        | HZ_CUST_ACCT_SITES_ALL         |    594 |      1 |    594 |00:00:
    |* 33 |          INDEX UNIQUE SCAN                 | HZ_CUST_ACCT_SITES_U1          |    594 |      1 |    594 |00:00:00.23 |   
    |  34 |        TABLE ACCESS BY INDEX ROWID         | HZ_PARTY_SITES                 |    594 |      1 |    594 |00:00:0
    |* 35 |         INDEX UNIQUE SCAN                  | HZ_PARTY_SITES_U1              |    594 |      1 |    594 |00:00:00.17 |     601
    |  36 |       TABLE ACCESS BY INDEX ROWID          | HZ_LOCATIONS                   |    594 |      1 |    594 |00:00:00.4
    |* 37 |        INDEX UNIQUE SCAN                   | HZ_LOCATIONS_U1                |    594 |      1 |    594 |00:00:00.17 |   
    |  38 |      TABLE ACCESS BY INDEX ROWID           | FND_TERRITORIES                |    594 |      1 |    594 |00:00:00
    |* 39 |       INDEX UNIQUE SCAN                    | FND_TERRITORIES_U1             |    594 |      1 |    594 |00:00:00.02
    |* 40 |     TABLE ACCESS BY INDEX ROWID            | HZ_CUST_ACCOUNTS               |    594 |      1 |    592 |00:00:0
    |* 41 |      INDEX UNIQUE SCAN                     | HZ_CUST_ACCOUNTS_U1            |    594 |      1 |    594 |00:00:00.04 |
    |* 42 |    INDEX RANGE SCAN                        | FND_LOOKUP_VALUES_U1           |    592 |      1 |    592 |00:00:00.06 |   
    |  43 |   TABLE ACCESS BY INDEX ROWID              | HZ_PARTIES                     |    592 |      1 |    592 |00:00:00.91 |  
    |* 44 |    INDEX UNIQUE SCAN                       | HZ_PARTIES_U1                  |    592 |      1 |    592 |00:00:00.40 |     599
    Predicate Information (identified by operation id):
      13 - access("OEL"."INVENTORY_ITEM_ID"="MIC"."INVENTORY_ITEM_ID")
      17 - access("HAOTL"."ORGANIZATION_ID"=189 AND "HAOTL"."LANGUAGE"=USERENV('LANG'))
           filter(DECODE("HR_SECURITY"."VIEW_ALL"(),'Y','TRUE',"HR_SECURITY"."SHOW_RECORD"('HR_ALL_ORGAN
      18 - filter("HAO"."BUSINESS_GROUP_ID"=DECODE("HR_GENERAL"."GET_XBG_PROFILE"(),'Y',"HAO"."BUSINESS_
      19 - access("HAO"."ORGANIZATION_ID"=189)
      20 - filter(("OEL"."FLOW_STATUS_CODE"='CLOSED' AND INTERNAL_FUNCTION("OEL"."ATTRIBUTE1") AND INTER
      21 - access("OEL"."SYS_NC00342$">=TO_DATE(' 2009-01-01 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND "O
                  'syyyy-mm-dd hh24:mi:ss'))
      22 - filter("MIC"."CATEGORY_SET_ID"=4)
      23 - filter(("MC"."DESCRIPTION" IS NOT NULL AND INTERNAL_FUNCTION("MC"."SEGMENT7")))
      24 - access("MIC"."CATEGORY_ID"="MC"."CATEGORY_ID")
      26 - access("MC"."DESCRIPTION"="CCM"."STMODELNUMBER")
      27 - access("OEL"."SHIP_FROM_ORG_ID"="MP"."ORGANIZATION_ID")
      28 - filter("OEH"."ORG_ID"=189)
      29 - access("OEH"."HEADER_ID"="OEL"."HEADER_ID")
      31 - access("OEH"."INVOICE_TO_ORG_ID"="HCSU"."SITE_USE_ID")
      33 - access("HCSU"."CUST_ACCT_SITE_ID"="HCAS"."CUST_ACCT_SITE_ID")
      35 - access("HCAS"."PARTY_SITE_ID"="HPS"."PARTY_SITE_ID")
      37 - access("HPS"."LOCATION_ID"="HL"."LOCATION_ID")
      39 - access("HL"."COUNTRY"="FT"."TERRITORY_CODE")
      40 - filter(("HCA"."SALES_CHANNEL_CODE"<>'RTL' AND "HCA"."SALES_CHANNEL_CODE"<>'AD-RTL' AND "HCA".
      41 - access("HCAS"."CUST_ACCOUNT_ID"="HCA"."CUST_ACCOUNT_ID")
      42 - access("FLV"."LOOKUP_TYPE"='SALES_CHANNEL' AND "FLV"."LOOKUP_CODE"="HCA"."SALES_CHANNEL_CODE"
           filter(("FLV"."LOOKUP_CODE"<>'RTL' AND "FLV"."LOOKUP_CODE"<>'AD-RTL' AND "FLV"."LOOKUP_CODE"<
      44 - access("HCA"."PARTY_ID"="HP"."PARTY_ID")
    90 rows selected.
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              &nbs

  • How to view the sql query?

    hi,
      how to view the sql query formed from the xml structure in the receiver jdbc?

    You can view SAP Note at
    http://service.sap.com/notes
    But you require SMP login ID for this which you should get from your company. The content of the notes are as follows:
    Reason and Prerequisites
    You are looking for additional parameter settings. There are two possible reasons why a feature is available via the "additional parameters" table in the "advanced mode" section of the configuration, but not as documented parameter in the configuration UI itself:
    Category 1: The parameter has been introduced for a patch or a SP upgrade where no UI upgrade and/or documentation upgrade was possible. In this case, the parameter will be moved to the UI and the documentation as soon as possible. The parameter in the "additional parameters" table will be deprecated after this move, but still be working. The parameter belongs to the supported adapter functionality and can be used in all, also productive, scenarios.
    Category 2. The parameter has been introduced for testing purposes, proof-of-concept scenarios, as workaround or as pre-released functionality. In this case, the parameter may or may not be moved to the UI and documentation, and the functionality may be changed, replaced or removed. For this parameter category there is no guaranteed support and usage in productive scenarios is not supported.
    When you want to use a parameter documented here, please be aware to which category it belongs!
    Solution
    The following list shows all available parameters of category 1 or 2. Please note:
    Parameter names are always case-sensitive! Parameter values may be case-sensitive, this is documented for each parameter.
    Parameter names and values as documented below must be used always without quotaton marks ("), if not explicitly stated otherwise.
    The default value of a parameter is always chosen that it does not change the standard functionality
    JDBC Receiver Adapter Parameters
    1. Parameter name: "logSQLStatement"
                  Parameter type: boolean
                  Parameter value: true for any string value, false only for empty string
                  Parameter value default: false (empty String)
                  Available with: SP9
                  Category: 2
                  Description:
                  When implementing a scenario with the JDBC receiver adapter, it may be helpful to see which SQL statement is generated by the JDBC adapter from the XI message content for error analysis. Before SP9, this can only be found in the trace of the JDBC adapter if trace level DEBUG is activated. With SP9, the generated SQL statement will be shown in the details page (audit protocol) of the message monitor for each message directly.
                  This should be used only during the test phase and not in productive scenarios.
    Regards,
    Prateek

Maybe you are looking for

  • Trying to implement a VPD policy but got the following error ORA-20001

    hey good day, I'm trying to implement a VPD policy to my application. After I have performed the below task (Label 1) in oracle 10g database. When I'm about to access my application page in ApEx 3.2.1 I got the following error ORA-20001: get_dbms_sql

  • How do I change the Finder Sidebar size?

    It an earlier preview build of Lion, I was able to change the Finder sidebar text size to make it smaller.  The default was too large, taking up too much real estate.  Unfortunately, I don't remember what I did to fix it.  Finder Preferences and View

  • Document expiration date?

    Hi, I don´t know if this is possible... I want put a date expiratacion in a document, can i? How? Thanks in advance, Regardsm

  • TOPS concept in Oracle EBS

    Hi, What are the tops in ebs directory structure. DATA_TOP, APPL_TOP, Custom top i need to understand. Please let me know. Thanks,. Ganesh

  • Writeback Issues

    Hi All, I have been trying to get the Writeback feature working ... I have followed a few examples on the internet but am stuck with the same error when I actually try and save to the DB Generic error so I don't really know where to look ... any thou