Select from view -v- table

Hi Guys,
I was just hoping to get your opinion on something.
I have a procedure in Production that is taking longer and longer to finish and sticks on one certain section of code.
The code is an INSERT into the main dimension table.
This same procedure runs fine on TEST and the section of code completes an awful lot quicker.
The traffic on Production is a lot heavier and there have been applications developed by people other than myself which SELECT from this dimension table. I'm assuming, based on the fact the code in Test and Production are identical, that this increased traffic could be eating up the bandwith and slowing the jobs.
So, I was thinking - if I create Views and let the other applications hit the views as opposed to the main table, will this help speed it up. I did this before on a Teradata platform using a 'dirty read' which worked quite well but Oracle doesn't seem to offer this option.
What do you guys think? Could this work or do I need to take a different approach.
Thank You.

GerardMcL wrote:
I meant ordinary views.
I was wondering if there was a way of putting some locking code in or asking for a dirty read that would speed up the SELECT from the table?There is no such thing as a dirty read with Oracle -- Teradata, SQL Server, Sybase, IBM, etc., have different locking architectures where reads can block write and writes can block reads, and that is not an issue with Oracle.
If there's a query performance problem, which is what that will be if the SELECTs are slow, then if you could follow the following links, that will help diagnosis immensely:
[How to Post A Tuning Request|http://forums.oracle.com/forums/thread.jspa?threadID=863295&tstart=0]
And:
[When your Query takes too long|http://forums.oracle.com/forums/thread.jspa?messageID=1812597#1812597]
There is such as thing as stale reads, against Materialized Views, which are views that actually materialize and store the results of a query, and which then can subsequently be queried.

Similar Messages

  • No value is select  from  user define  table

    Hi ALL,
                 i am using  B1if , i am sending  data  B1 to  isr , i am using user define table  but problem  no value is select  from  user define  table  .
    my table ID  is @SSRPOD 
    <payload operation="">
         <ns0:MT_POD_B1_System xmlns:ns0="http://xxxx.com/SC/B1/Dlvr/CustDlvr/ExtPrfOfDlvr">
              <POD>
                   <Header>
                        <SalesOrderNumber>
                             <xsl:value-of select="$msg/BOM/BO/@SSRPOD/row/U_SalOrdNo" />
                        </SalesOrderNumber>
                        <ArrivalDate>
                             <xsl:value-of select="$msg/BOM/BO/@SSRPOD/row/U_TaxDate" />
                        </ArrivalDate>
                        <Detail>
                             <DOLineQuantity>
                                  <xsl:value-of select="$msg/BOM/BO/@SSRPOD/row/U_Quantity" />
                             </DOLineQuantity>
                             <UOM>
                                  <xsl:value-of select="$msg/BOM/BO/@SSRPOD/row/U_Unitmsr" />
                             </UOM>
                        </Detail>
                   </Header>
              </POD>
         </ns0:MT_POD_B1_System>
    </payload>
    I have set following things. 
    Inbound Channel
        scenirio step identifier :z.xxxx
        Inbound Channel(IPO):INB_B1_EVNT_ASYN_EVT
        InboundType:Asynchronous
        Process Trigger:B1Event
        Identification Method: B1Event
        Identification Parameter:n.a
        Identifier:?????                                  
        Identifier Namespace:??????
      can anyone help me?
    Edited by: Sinha_Sinha on Feb 3, 2012 7:47 AM

    Found an authorization object was missing, that enabled the case types to show but hitting the GO button brought a page that can not be viewed in IE.  on to the next hurdle..........

  • How to assign tasks in Approval Workflow to a set of users selected from a Lookup table

    Hi all,
    I am new to Project Server and I am using Project Server 2013 On premises deployement. Please help me on how to achieve the below scenario:
    I have a requirement where, the initial PDP will have 2 fields (Reviewers and Approvers), wherein the engineer himself will select who the reviewer and approver from the Lookup tables.
    Now I have to start task process with these selected people for approval.
    Say for example , engineer has selected Alice and Bob as 2 reviewers, then
    In the workflow I have :
                 Start Task process with
    Project Data: Reviewers (which is giving error as
    [System.ArgumentException: AssignedTo at Microsoft.Activities.Hosting.Runtime.Subroutine.SubroutineChild.Execute(CodeActivityContext context) at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager
    bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation) ]
    Then I tried logging the value of Project Data: Reviewers, It logged the value as Alice, Bob (which looks pretty good),
    Then I tried assigning only 1 person as Reviewer, then also I get the same error.
    So can anybody please tell me where I went wrong. Is it not possible to fetch the data from the values selected as Project Data from the Lookup tables ? If not then what is the workaround I can use to achieve this ?
    Thanks,
    Shanky

    Hi Paul,
    Yes I am using SP designer for Workflows. And yes, You were right, there was a mismatch in the names of AD account and the Lookup table, now with 1 person selected from the lookup table it is assigning the task properly. However with multiple selection,
    it is failing.
    As Robert mentioned, the fetched value is a text as "Alice, Bob", which makes 2 usernames as a single text. So when I try to assign a task to this group, which returns value as "Alice, Bob", workflow fails to find such AD user, as it
    is an invalid value.
    So is there any way I can seperate this out to form 2 different username ? I checked for string extraction function in th Workflow, but nothing helped me for this scenario.
    Any input will be helpful.
    Thanks,
    Shanky

  • Selecting from 2 different tables

    is this possible?
    i just want to select from two different tables in one select statement and they have the same WHERE clause

    SELECT
      a.pkggrp,
      a.pkgtype,
      a.area,
      a.process,
      a.ww,
      count(a.ww) as LOTSGATED,
      sum(a.samplesize) as SUMSAMPLESIZE,
      sum(a.total_defects) as SUMTOTALDEFECTS,
      sum(case a.auditresult when 'pass' then 1 else 0 end) COUNTPASS,
      sum(case a.auditresult when 'fail' then 1 else 0 end) COUNTFAIL,
      case sum(case a.auditresult when 'fail' then 1 else 0 end)
        when 0 then 0
      else round(sum(case a.auditresult when 'fail' then 1 else 0 end) / count(a.ww) * 100,2)
        end LRR,
      case sum(case a.auditresult when 'fail' then 1 else 0 end)
        when 0 then 0
      else round(sum(case a.auditresult when 'fail' then 1 else 0 end) / sum(a.samplesize) * 1000000,0)
        end PPM,
      count(c.itrnum)
    FROM
      t_prodproc_monitoring a, t_itr c
    WHERE
      a.ww=c.ww
      and a.ww between 1 and 50
      and c.ww between 1 and 50
    GROUP BY
      a.pkggrp,
      a.pkgtype,
      a.area,
      a.process,
      a.ww
    ORDER BY
      a.pkggrp,
      a.pkgtype,
      a.area,
      a.process,
      a.ww ascthis gave me a
    "c". "ww": invalid identifier

  • SELECTing from a large table vs small table

    I posted a question few months back about teh comparison between INSERTing to a large table vs small table ( fewer number of rows ), in terms of time taken.
    The general consensus seemed to be that it would be teh same, except for teh time taken to update the index ( which will be negligible ).
    1. But now, following teh same logic, I m confused why SELECTINg from a large table should be more time taking ("expensive" ) than SELECTing from a small table.
    ( SELECTing using an index )
    My understanding of how Oracle works internally is this :
    It will first locate the ROWID from teh B-Tree that stores the index.
    ( This operation is O(log N ) based on B-Tree )
    ROWID essentially contains teh file pointer offset of teh location of the data in teh disk.
    And Oracle simply reads teh data from teh location it deduced from ROWID.
    But then the only variable I see is searching teh B-Tree, which should take O(log N ) time for comparison ( N - number of rows )
    Am I correct above.
    2. Also I read that tables are partitioned for performance reasons. I read about various partiotion mechanisms. But cannot figure out how it can result in performance improvement.
    Can somebody please help

    user597961 wrote:
    I posted a question few months back about teh comparison between INSERTing to a large table vs small table ( fewer number of rows ), in terms of time taken.
    The general consensus seemed to be that it would be teh same, except for teh time taken to update the index ( which will be negligible ).
    1. But now, following teh same logic, I m confused why SELECTINg from a large table should be more time taking ("expensive" ) than SELECTing from a small table.
    ( SELECTing using an index )
    My understanding of how Oracle works internally is this :
    It will first locate the ROWID from teh B-Tree that stores the index.
    ( This operation is O(log N ) based on B-Tree )
    ROWID essentially contains teh file pointer offset of teh location of the data in teh disk.
    And Oracle simply reads teh data from teh location it deduced from ROWID.
    But then the only variable I see is searching teh B-Tree, which should take O(log N ) time for comparison ( N - number of rows )
    Am I correct above.
    2. Also I read that tables are partitioned for performance reasons. I read about various partiotion mechanisms. But cannot figure out how it can result in performance improvement.
    Can somebody please helpIt's not going to be that simple. Before your first step (locate ROWID from index), it will first evaluate various access plans - potentially thousands of them - and choose the one that it thinks will be best. This evaluation will be based on the number of rows it anticipates having to retrieve, whether or not all of the requested data can be retrived from the index alone (without even going to the data segment), etc. etc etc. For each consideration it makes, you start with "all else being equal". Then figure there will be dozens, if not hundreds or thousands of these "all else being equal". Then once the plan is selected and the rubber meets the road, we have to contend with the fact "all else is hardly ever equal".

  • Error while selecting from view that references external table

    Can someone explain why the error near the bottom of the code below is occuring? If USER1 grants SELECT on the external table to USER2, then USER2 can select from the view without any problems; however, I want to avoid giving USER2 access to all of the columns in the external table. (I only want to give USER2 access to two of the four columns.)
    SQL> CONNECT sys AS SYSDBA
    Connected as SYS@ as sysdba
    SQL> CREATE USER user1 IDENTIFIED BY user1
    User created.
    SQL> CREATE USER user2 IDENTIFIED BY user2
    User created.
    SQL> GRANT CONNECT, CREATE TABLE, CREATE VIEW TO user1
    Grant complete.
    SQL> GRANT CONNECT TO user2
    Grant complete.
    SQL> GRANT READ, WRITE ON DIRECTORY EXT_DATA_DIR TO user1, user2
    Grant complete.
    SQL> CONNECT user1/user1
    Connected as USER1@
    SQL> CREATE TABLE emp_xt
      emp_id     NUMBER,
      first_name VARCHAR2(30),
      last_name  VARCHAR2(30),
      phone      VARCHAR2(15)
    ORGANIZATION EXTERNAL
      TYPE ORACLE_LOADER
      DEFAULT DIRECTORY EXT_DATA_DIR
      ACCESS PARAMETERS
        RECORDS DELIMITED BY NEWLINE
        FIELDS TERMINATED BY ','
        OPTIONALLY ENCLOSED BY '"'           
      LOCATION ('emp.txt')
    REJECT LIMIT 0
    Table created.
    SQL> SELECT COUNT(1) FROM emp_xt
      COUNT(1)
             4
    1 row selected.
    SQL> CREATE OR REPLACE VIEW emp_xt_view AS SELECT first_name, last_name FROM emp_xt;
    View created.
    SQL> SELECT COUNT(1) FROM emp_xt_view
      COUNT(1)
             4
    1 row selected.
    SQL> GRANT SELECT ON emp_xt_view TO user2
    Grant complete.
    SQL> CONNECT user2/user2
    Connected as USER2@
    SQL> SELECT COUNT(1) from user1.emp_xt_view
    SELECT COUNT(1) from user1.emp_xt_view
    Error at line 0
    ORA-29913: error in executing ODCIEXTTABLEOPEN callout
    ORA-29400: data cartridge error
    ORA-04043: object "USER1"."EMP_XT" does not exist
    SQL> CONNECT user1/user1
    Connected as USER1@
    SQL> GRANT SELECT ON user1.emp_xt TO user2
    Grant complete.
    SQL> CONNECT user2/user2
    Connected as USER2@
    SQL> SELECT COUNT(1) from user1.emp_xt_view
      COUNT(1)
             4
    1 row selected.
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    user503699 wrote:
    user1983440 wrote:
    Can someone explain why the error near the bottom of the code below is occuring? If USER1 grants SELECT on the external table to USER2, then USER2 can select from the view without any problems; however, I want to avoid giving USER2 access to all of the columns in the external table. (I only want to give USER2 access to two of the four columns.)As you have demonstrated, I guess the view approach only works for database tables. External tables are actually files on the file system. Even through OS, it is not possible to grant READ/WRITE access to only part of the file. The access is for entire file. An "External Table" is just a "wrapper" provided by oracle (using data cartridge) to allow user to be able to access the file as a "table". So it can definitely not do something that underlying OS can not do.
    p.s. In fact, oracle does not even allow to edit data in external tables using SQL.Why not just make a second external table (only including the 2 columns you need) and grant select directly on that to the user. I know you say "views only" but there's an exception to every rule ... just because it's called a table doesn't make it so. You could argue an external table is nothing more than a fancy view.
    Worst case, make a view on top of the second external table.
    CREATE TABLE emp_xt_less_information
      first_name VARCHAR2(30),
      last_name  VARCHAR2(30)
    ORGANIZATION EXTERNAL
      TYPE ORACLE_LOADER
      DEFAULT DIRECTORY EXT_DATA_DIR
      ACCESS PARAMETERS
        RECORDS DELIMITED BY NEWLINE
        FIELDS TERMINATED BY ','
        OPTIONALLY ENCLOSED BY '"'   
             emp_id      number,
             first_name  char,
             last_name   char,
             phone       char
      LOCATION ('emp.txt')
    REJECT LIMIT 0
    {code}
    Should do it, but my syntax may be off a touch ....                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Is select from view faster then select from table..???

    Hello Gurus,
    I want to query some data from two tables, both of table have many columns (attributes) and many rows...
    I use several where clauses to retrieve data from those tables..
    witch one is faster, I create a view or I just "select" from those tables???
    Regards.
    Nia...

    riedelme wrote:
    3360 wrote:
    riedelme wrote:
    Selecting through a view almost never helps performance and frequently hurts.Views do not affect performance.
    Views are simply queries and like queries there are fast and slow ones.I disagree.
    First of all, to use a view you are executing a query to get a result set, then accessing the data from that result set - a built-in extra step to perform to get data.First of all that entire explanation of how views work is not correct. The optimizer will rewrite the query to make the view go away if possible.
    SQL> create or replace view v as select * from dual;
    View created.
    SQL> explain plan for select * from dual where dummy = 'X';
    Explained.
    SQL> select * from table(dbms_xplan.display);
    PLAN_TABLE_OUTPUT
    Plan hash value: 272002086
    | Id  | Operation         | Name | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT  |      |     1 |     2 |     2   (0)| 00:00:01 |
    |*  1 |  TABLE ACCESS FULL| DUAL |     1 |     2 |     2   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       1 - filter("DUMMY"='X')
    13 rows selected.
    SQL> explain plan for select * from v where dummy = 'X';
    Explained.
    SQL> select * from table(dbms_xplan.display);
    PLAN_TABLE_OUTPUT
    Plan hash value: 272002086
    | Id  | Operation         | Name | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT  |      |     1 |     2 |     2   (0)| 00:00:01 |
    |*  1 |  TABLE ACCESS FULL| DUAL |     1 |     2 |     2   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       1 - filter("DUMMY"='X')
    13 rows selected.Exactly the same.
    >
    Second, when accessing the data from the view the result sets don't have indexes for fast lookups and efficient joins on later steps.This is also known as just making stuff up and is not how the database works. care to share any references at all for any of this?
    >
    Third, the systems I've seen that use views extensively - I am looking at one now - tend to perform joins on views using the same tables with the same data over and over. This is a design issue and not specifically a problem with views but they lend themselves to this misuse much too easilyCorrect as I said a view is just a query, and just like queries there are good fast views and bad slow views
    >
    I'll concede that the problem is not specifically with views themselves but as I just said they lend themselves to misuse. Tuning views of views and views joined to views is difficultYes, queries can be misused as can almost all SQL functions and functionality.
    As I said - Views are simply queries and like queries there are fast and slow ones.
    Nothing that you have posted that is accurate changes that.

  • Can't select from view even though it appears in ALL_VIEWS

    Oracle's documentation states that all_views "describes the views accessible to the user":
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14237/statviews_2117.htm
    DBA_OBJECTS appears in the ALL_VIEWS, yet I get a "table or view does not exist" error when I try to select from it.
    Any thoughts on why this is happening?
    SQL> SELECT COUNT(1)
      FROM all_views
      WHERE owner = 'SYS'
      AND view_name = 'DBA_OBJECTS'
      COUNT(1)
             1
    1 row selected.
    SQL> SELECT *
      FROM sys.dba_objects
    SELECT *
      FROM sys.dba_objects
    Error at line 2
    ORA-00942: table or view does not exist

    That's not standard behaviour:
    DBA >create user u1 identified by u1;
    Utente creato.
    DBA >grant connect to u1;
    Concessione riuscita.
    DBA >conn u1/u1
    Connesso.
    DBA >select count(0) from all_views;
      COUNT(0)
           856
    DBA >select view_name from all_views
      2  where view_name like 'DBA%'
      3  or view_name like 'V$%';
    VIEW_NAME
    DBA_PROCEDURES
    DBA_PUBLISHED_COLUMNS
    V$OBJECT_USAGE
    DBA >select 'select count(*) from '||owner||'.'||view_name||';'
      2  from all_views
      3  where view_name like 'DBA%'
      4  or view_name like 'V$%';
    'SELECTCOUNT(*)FROM'||OWNER||'.'||VIEW_NAME||';'
    select count(*) from SYS.DBA_PROCEDURES;
    select count(*) from SYS.DBA_PUBLISHED_COLUMNS;
    select count(*) from SYS.V$OBJECT_USAGE;
    DBA >select count(*) from SYS.DBA_PROCEDURES;
      COUNT(*)
          6793
    DBA >select count(*) from SYS.DBA_PUBLISHED_COLUMNS;
      COUNT(*)
             0
    DBA >select count(*) from SYS.V$OBJECT_USAGE;
      COUNT(*)
             0All the DBA* or V$ visible are also accessible, DBA_OBJECTS is not present in ALL_VIEWS.
    There's something strange on your user's priviledges...
    Max
    [My Italian Oracle blog|http://oracleitalia.wordpress.com/2010/01/02/query-gerarchiche/]

  • Selecting from Views and ORA-0600

    Hi All,
    I am using Oracle 9i and was looking for some guidance on the issue I am seeing.
    I have this huge query in which some dataelements are obtained using sys_connect_by_path while the others are got directly. I have set this huge query set up as a view (GetDataView).
    I am now trying to query from the view. (I am using a stored procedure to get dataelements from the view and output as a xml).
    When I do a 'select * from GetDataView' , the results come back fine. Also, when I query the dataelements which are obtained directly (without sys_connect_by_path), they come back fine as well. However, when I try and get the dataelements which are obtained using
    sys_connect_by_path, I get the error :
    "An error was encountered while performing the requested operation:
    ORA-00600: internal error code, arguments:qkacon:qkaconGetPathOps:1],[,],[,],[,],[
    00600.0000 - "internal error code, arguments: %s,%s,%s,%s,%s,%s,%s,%s".
    I know that this is a known issue with Oracle 9i when using sys_connect_by_path but this huge query executes perfectly when I run it independently.
    It is only when I try to query the view for individual dataelements(which use sys_connect_by_path) that I get this error.
    Can you pls point out what the problem could be here? Also, can you pls suggest any workarounds that I could try.
    Thanks in advance,
    AD
    Query which uses SYS_CONNECT_BY_PATH for certain elements - This is set up as a View
    SELECT --nrtd dataelements (Non Relational Test Data)
    nrtd.ID, nrtd.DevelopmentSite, nrtd.ProjectStatus, nrtd.ProjectType, nrtd.Creator, nrtd.Business_Unit,
    nrtd.Division, nrtd.Strategy,
    --Special Case : First Generic from NewModels if FF, TD, PD, FFC, BD. PromisWaferIdentifier from WaferInformation if New Wafer or New Die
    nmwigen.SAPGenericID,
    nrtd.AssemblySite,
    rwid.FabSite,
    nrtd.packagetype, nrtd.directreleasestrat,
    nrtd.testsite, nrtd.packsite, nrtd.umbrellaproject_id, nrtd.keycustomers, nrtd.ProjectedReleasedate,
    nrtd.perfwwmfgnpcoordinator, nrtd.perfwwmfgoffshoretesteng, nrtd.packagedesignator, nrtd.leadballcount, nrtd.bodysize,
    nrtd.finishcode, nrtd.pkgnumber, nrtd.pkgstatus, nrtd.pborpbfree, nrtd.paddlex, nrtd.PaddleY,
    nrtd.BackGrind, nrtd.LeadFrameType, nrtd.PiecePart, nrtd.assypackoption,
    nrtd.testprocess, nrtd.contactorresreq, nrtd.highrfrequired, nrtd.PeakCurrent, nrtd.AssignedFocusFactory,
    nrtd.MfgReleaseReqStatus , nrtd.NumActuators , nrtd.NumBoards, nrtd.numcontactors,
    nrtd.IsQualPlanRequired, nrtd.QualNumber, nrtd.FailedQualProjectdisposition,
    nrtd.IdentifiedActionFromQualReview,
    --rtgd dataelements (Relational TestGrades Data)
    rtgd.ProductGrade, rtgd.SpeedSuffix, rtgd.PartClass,
    rtgd.MultiGrade, rtgd.EstTotalTestTimeGood, rtgd.EstTotalTestTimeBad,
    rtgd. ActTotalTestTimeGood, rtgd.ActTotalTestTimeBad, rtgd.EstOverAllYield,
    rtgd.EstYieldToGrade, rtgd.ActOverAllYield, rtgd.ActYieldToGrade,
    -- rnmd dataelements (Relational NewModels Data)
    rnmd.ActualFGMaterialNum, rnmd.PackOption, rnmd.IsReleasedMaterial,
    --rtpd dataelements (Relational TestPasses Data)
    rtpd.Contactor, rtpd.Handler, rtpd.TesterConfig, rtpd.NumTestSites,
    rtpd.TestTemp, rtpd.SpecialTest, --rtpd.SpecialTestCommByPassPerGrade,
    rtpd.EstTestTimeGood, rtpd.EstTestTimeBad, rtpd.ActTestTimeGood,
    rtpd.ActTestTimeBad,
    --rwid dataelements (Relational WaferInformation Data)
    rwid.WID, rwid.WaferDesignType, rwid.WaferSize, rwid.FabProcessCode, rwid.FabProcessStatus, rwid.FndryFabPlantCode, rwid.EstTapeOutDate,
    rwid.EstXWidth, rwid.EstGDPW, rwid.EstYLength, rwid.PowerDissipation, rwid.XWidth, rwid.YLength,
    rwid.OMSVendorName, rwid.GDPW, rwid.IsReleaseOnPizzaMask, rwid.FabMfgReleaseReqStatus, rwid.FabMfgReleaseReqComments,
    --rtpid dataelements (Relational TrimProbeInformation Data)
    rtpid.ProbeSite, rtpid.ProbeType, rtpid.DieDesignType, rtpid.probemfgreleasereqstatus,
    rtpid.probemfgreleasereqcomments, rtpid.isvendorpartonwfrordsht,
    --rtpgd dataelements (Relational TrimProbeGrade Data)
    rtpgd.ProbeGrade, rtpgd.EstProbeYield1, rtpgd.EstTotalProbeTimeGood, rtpgd.EstTotalProbeTimeBad,
    rtpgd.ActProbeYield, rtpgd.ActTotalProbeTimeGood, rtpgd.ActTotalProbeTimeBad,
    --rtppd dataelements (Relational TrimProbePasses Data)
    rtppd.TrimProbeSystem, rtppd.NumProbeSites, rtppd.ProbeTempReqd1, rtppd.ProbeTemp
    --Non relational TestData data elements. Alias Table 'nrtd'
    FROM (SELECT npip.id AS ID, npip.developmentsite AS DevelopmentSite, npip.projectstatus AS ProjectStatus,
    npip.ProjectType AS ProjectType, pt.Creator, ss.Business_Unit, ss.Division, npip.strategy_name AS Strategy,
    ffi.assemblysite, ffi.packagetype, ti.directreleasestrat AS directreleasestrat,
    ti.testsite, ti.PackSite, npip.umbrellaproject_id, npip.keycustomers, npip.projectedreleasedate AS ProjectedReleasedate,
    pt.perfwwmfgnpcoordinator AS perfwwmfgnpcoordinator, pt.perfwwmfgoffshoretesteng AS perfwwmfgoffshoretesteng, ffi.packagedesignator,
    ffi.leadballcount, ffi.bodysize, ffi.finishcode AS finishcode, ffi.pkgnumber, ffi.pkgstatus,
    ffi.pborpbfree AS pborpbfree, ffi.paddlex AS paddlex, ffi.paddley AS paddley, ffi.backgrind AS backgrind,
    ffi.LeadFrameType, ffi.PiecePart AS PiecePart, ffi.assypackoption AS assypackoption,
    ti.testprocess AS testprocess, ti.contactorresreq AS contactorresreq,
    ti.highrfrequired AS highrfrequired, ti.PeakCurrent AS PeakCurrent, vp.AssignedFocusFactory,
    vp.MfgReleaseReqStatus AS MfgReleaseReqStatus, vp.NumActuators AS NumActuators, vp.NumBoards AS NumBoards,
    vp.numcontactors AS numcontactors, qi.IsQualPlanRequired, qi.QualNumber, qi.FailedQualProjectdisposition,
    qi.IdentifiedActionFromQualReview
    FROM NPIProjects npip
    LEFT OUTER JOIN ProjectTeam pt ON pt.NPIProjectId = npip.Id
    LEFT OUTER JOIN sapws_strategies ss ON ss.Strategy = npip.strategy_name
    LEFT OUTER JOIN FormFactorInformation ffi ON ffi.NPIProjectId = npip.Id
    LEFT OUTER JOIN TestInformation ti ON ti.FormFactorInformationId = ffi.Id
    LEFT OUTER JOIN ValidationPlans vp ON vp.FormFactorInformationId = ffi.Id
    LEFT OUTER JOIN QualInformation qi ON qi.FormFactorInformationId = ffi.Id) nrtd,
    -- Relational data elements.
    --TestGrades DataElements. Alias Table 'rtgd'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(ProductGrade,';'),';')) ProductGrade,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| SpeedSuffix,';'),';')) SpeedSuffix,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| PartClass,';'),';')) PartClass,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| MultiGrade,';'),';')) MultiGrade,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| EstTotalTestTimeGood,';'),';')) EstTotalTestTimeGood,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| EstTotalTestTimeBad,';'),';')) EstTotalTestTimeBad,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| ActTotalTestTimeGood,';'),';')) ActTotalTestTimeGood,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| ActTotalTestTimeBad,';'),';')) ActTotalTestTimeBad,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| EstOverAllYield,';'),';')) EstOverAllYield,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| EstYieldToGrade,';'),';')) EstYieldToGrade,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| ActualOverAllYield,';'),';')) ActOverAllYield,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| ActualYieldToGrade,';'),';')) ActYieldToGrade
    FROM (SELECT npip.id AS NPIProjectID, tg.ProductGrade AS ProductGrade,
    tg.SpeedSuffix AS SpeedSuffix, tg.PartClass AS PartClass, tg.MultiGrade AS MultiGrade,
    tg.EstTotalTestTimeGood AS EstTotalTestTimeGood, tg.EstTotalTestTimeBad AS EstTotalTestTimeBad,
    tg.ActTotalTestTimeGood AS ActTotalTestTimeGood, tg.ActTotalTestTimeBad AS ActTotalTestTimeBad,
    tg.EstOverAllYield AS EstOverAllYield, tg.EstYieldToGrade AS EstYieldToGrade, tg.ActualOverAllYield AS ActualOverAllYield,
    tg.ActualYieldToGrade AS ActualYieldToGrade,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN FormFactorInformation ffi ON ffi.NPIProjectId = npip.Id
    LEFT OUTER JOIN TestGrades tg ON tg.FormFactorInformationId = ffi.Id)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID) rtgd,
    -- NewModels DataElements. Alias Table 'rnmd'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(ActualFGMaterialNum,';'),';')) ActualFGMaterialNum,
    (LTRIM(sys_connect_by_path(PackOption,';'),';')) PackOption,
    (LTRIM(sys_connect_by_path(IsReleasedMaterial,';'),';')) IsReleasedMaterial
    FROM (SELECT npip.id AS NPIProjectID,
    nm.ActualFGMaterialNum AS ActualFGMaterialNum,
    nm.PackOption AS PackOption, nm.IsReleasedMaterial AS IsReleasedMaterial,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN FormFactorInformation ffi ON ffi.NPIProjectId = npip.Id
    LEFT OUTER JOIN TestGrades tg ON tg.FormFactorInformationId = ffi.Id
    LEFT OUTER JOIN NewModels nm ON nm.TestGradesID = tg.Id)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID) rnmd,
    --SAPGenericID from NewModels Table for FF, TD, BD, PD and PromisWaferIdentifier from WaferInformation Table for New Wafer and New Die
    (SELECT npip.id AS NPIProjectID, decode(npip.projecttype, 'New Wafer', wi.PromisWaferIdentifier, 'New Die', wi.PromisWaferIdentifier, nm.SAPGenericID)SAPGenericID --nm.SAPGenericID
    FROM NPIProjects npip LEFT OUTER JOIN FormFactorInformation ffi ON ffi.NPIProjectId = npip.Id
    LEFT OUTER JOIN WaferInformation wi ON wi.NPIProjectId = npip.Id
    LEFT OUTER JOIN (Select FormFactorInformationID, min(ID)ID from TestGrades GROUP BY FormFactorInformationID) tg ON (tg.FormFactorInformationId = ffi.Id)
    LEFT OUTER JOIN (Select TestGradesID, min(SAPGenericID)SAPGenericID from NewModels GROUP BY TestGradesID) nm ON (nm.TestGradesID = tg.ID)) nmwigen,
    -- Relational TestPasses data. Alias Table 'rtpd'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| Contactor,';'),';')) Contactor,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| Handler,';'),';')) Handler,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| TesterConfig,';'),';')) TesterConfig,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| NumTestSites,';'),';')) NumTestSites,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| TestTemp,';'),';')) TestTemp,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| SpecialTest,';'),';')) SpecialTest,
    --(LTRIM(sys_connect_by_path(ProductGrade || '-'|| SpecialTestComments,';'),';')) SpecialTestCommByPassPerGrade,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| EstTestTimeGood,';'),';')) EstTestTimeGood,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| EstTestTimeBad,';'),';')) EstTestTimeBad,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| ActTestTimeGood,';'),';')) ActTestTimeGood,
    (LTRIM(sys_connect_by_path(ProductGrade || '-'|| ActTestTimeBad,';'),';')) ActTestTimeBad
    FROM (SELECT npip.id AS NPIProjectID, tg.ProductGrade AS ProductGrade, tp.contactor AS Contactor,
    tp.Handler AS Handler, tp.TesterConfig AS TesterConfig, tp.NumTestSites AS NumTestSites,
    tp.testtemp AS TestTemp, tp.SpecialTest AS SpecialTest, --tp.SpecialtestComment AS SpecialTestComments,
    tp.EstTestTimeGood AS EstTestTimeGood, tp.EstTestTimeBad AS EstTestTimeBad,
    tp.ActTestTimeGood AS ActTestTimeGood, tp.ActTestTimeBad AS ActTestTimeBad,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN FormFactorInformation ffi ON ffi.NPIProjectId = npip.Id
    LEFT OUTER JOIN TestGrades tg ON tg.FormFactorInformationId = ffi.Id
    LEFT OUTER JOIN TestPasses tp ON tp.TestGradesID = tg.Id)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID)rtpd,
    -- Relational WaferInformation data Alias Table 'rwid'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(WID,';'),';')) WID,
    (LTRIM(sys_connect_by_path(FabSite,';'),';')) FabSite,
    (LTRIM(sys_connect_by_path(WaferDesignType,';'),';')) WaferDesignType,
    (LTRIM(sys_connect_by_path(WaferSize,';'),';')) WaferSize,
    (LTRIM(sys_connect_by_path(FabProcessCode,';'),';')) FabProcessCode,
    (LTRIM(sys_connect_by_path(FabProcessStatus,';'),';')) FabProcessStatus,
    (LTRIM(sys_connect_by_path(FndryFabPlantCode,';'),';')) FndryFabPlantCode,
    (LTRIM(sys_connect_by_path(EstTapeOutDate,';'),';')) EstTapeOutDate,
    (LTRIM(sys_connect_by_path(EstXWidth,';'),';')) EstXWidth,
    (LTRIM(sys_connect_by_path(EstGDPW,';'),';')) EstGDPW,
    (LTRIM(sys_connect_by_path(EstYLength,';'),';')) EstYLength,
    (LTRIM(sys_connect_by_path(PowerDissipation,';'),';')) PowerDissipation,
    (LTRIM(sys_connect_by_path(XWidth,';'),';')) XWidth,
    (LTRIM(sys_connect_by_path(YLength,';'),';')) YLength,
    (LTRIM(sys_connect_by_path(OMSVendorName,';'),';')) OMSVendorName,
    (LTRIM(sys_connect_by_path(GDPW,';'),';')) GDPW,
    (LTRIM(sys_connect_by_path(IsReleaseOnPizzaMask,';'),';')) IsReleaseOnPizzaMask,
    (LTRIM(sys_connect_by_path(FabMfgReleaseReqStatus,';'),';')) FabMfgReleaseReqStatus,
    (LTRIM(sys_connect_by_path(FabMfgReleaseReqComments,';'),';')) FabMfgReleaseReqComments
    FROM (SELECT npip.id AS NPIProjectID, wi.WID AS WID, decode(npip.ProjectType, 'New Wafer', wi.FabSite, 'New Die', wi.FabSite, di.FabSite) AS FabSite, wi.WaferDesignType AS WaferDesignType,
    wi.WaferSize AS WaferSize, wi.FabProcessCode AS FabProcessCode, wi.FabProcessStatus AS FabProcessStatus,
    wi.FndryFabPlantCode AS FndryFabPlantCode, wi.EstTapeOutDate AS EstTapeOutDate, wi.EstXWidth AS EstXWidth,
    wi.ESTGDPW AS EstGDPW, wi.EstYLength AS EstYLength, wi.PowerDissipation AS PowerDissipation,
    wi.XWidth AS XWidth, wi.YLength AS YLength,
    wi.OMSVendorName AS OMSVendorName, wi.GDPW AS GDPW, wi.IsReleaseOnPizzaMask AS IsReleaseOnPizzaMask,
    wi.FabMfgReleaseReqStatus AS FabMfgReleaseReqStatus, wi.FabMfgReleaseReqComments AS FabMfgReleaseReqComments,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN DieInformation di ON di.NPIProjectId = npip.Id
    LEFT OUTER JOIN TrimProbeInformation tpi ON tpi.Id = di.TrimProbeInformation_id
    LEFT OUTER JOIN WaferInformation wi ON wi.WID = tpi.WaferInformation_id)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID)rwid,
    -- relational TrimProbeInformation Dataelements . Alias Table 'rtpid'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(ProbeSite,';'),';')) ProbeSite,
    (LTRIM(sys_connect_by_path(ProbeType,';'),';')) ProbeType,
    (LTRIM(sys_connect_by_path(DieDesignType,';'),';')) DieDesignType,
    (LTRIM(sys_connect_by_path(probemfgreleasereqstatus,';'),';')) probemfgreleasereqstatus,
    (LTRIM(sys_connect_by_path(probemfgreleasereqcomments,';'),';')) probemfgreleasereqcomments,
    (LTRIM(sys_connect_by_path(isvendorpartonwfrordsht,';'),';')) isvendorpartonwfrordsht
    FROM (SELECT npip.id AS NPIProjectID,tpi.ProbeSite AS ProbeSite, tpi.ProbeType AS ProbeType,
    tpi.DieDesignType AS DieDesignType, tpi.probemfgreleasereqstatus AS probemfgreleasereqstatus,
    tpi.probemfgreleasereqcomments AS probemfgreleasereqcomments,
    tpi.isvendorpartonwfrordsht AS isvendorpartonwfrordsht,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN WaferInformation wi ON wi.NPIProjectId = npip.Id
    LEFT OUTER JOIN TrimProbeInformation tpi ON tpi.waferinformation_id = wi.wid)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID)rtpid,
    -- Relational TrimProbeGrades Dataelements . Alias Table 'rtpgd'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(ProbeGrade,';'),';')) ProbeGrade,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| EstProbeYield1,';'),';')) EstProbeYield1,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| EstTotalProbeTimeGood,';'),';')) EstTotalProbeTimeGood,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| EstTotalProbeTimeBad,';'),';')) EstTotalProbeTimeBad,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| ActProbeYield,';'),';')) ActProbeYield,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| ActTotalProbeTimeGood,';'),';')) ActTotalProbeTimeGood,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| ActTotalProbeTimeBad,';'),';')) ActTotalProbeTimeBad
    FROM (SELECT npip.id AS NPIProjectID, tpg.ProbeGrade AS ProbeGrade, decode(tpg.EstProbeYield, null, tpg.EstProbeYield, tpg.EstProbeYield1) AS EstProbeYield1,
    tpg.EstTotalProbeTimeGood AS EstTotalProbeTimeGood, tpg.EstTotalProbeTimeBad AS EstTotalProbeTimeBad,
    tpg.ActProbeYield AS ActProbeYield, tpg.ActTotalProbeTimeGood AS ActTotalProbeTimeGood,
    tpg.ActTotalProbeTimeBad AS ActTotalProbeTimeBad,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN DieInformation di ON di.NPIProjectid = npip.id
    LEFT OUTER JOIN TrimProbeInformation tpi ON tpi.Id = di.TrimProbeInformation_id
    LEFT OUTER JOIN TrimProbeGrades tpg ON tpg.TrimProbeInformation_Id = tpi.Id)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID)rtpgd,
    -- Relational TrimProbePasses data. Alias Table 'rtppd'
    (SELECT NPIProjectID,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| TrimProbeSystem,';'),';')) TrimProbeSystem,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| NumProbeSites,';'),';')) NumProbeSites,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| ProbeTempReqd1,';'),';')) ProbeTempReqd1,
    (LTRIM(sys_connect_by_path(ProbeGrade || '-'|| ProbeTemp,';'),';')) ProbeTemp
    FROM (SELECT npip.id AS NPIProjectID, tpg.ProbeGrade AS ProbeGrade,
    tpp.TrimProbeSystem AS TrimProbeSystem, tpp.NumProbeSites AS NumProbeSites,
    decode(tpp.ProbeTempReqd, null, tpp.ProbeTempReqd1,tpp.ProbeTempReqd1) AS ProbeTempReqd1, tpp.ProbeTemp AS ProbeTemp,
    row_number() OVER (PARTITION BY npip.id ORDER BY npip.id) rnum,
    COUNT(*) OVER (PARTITION BY npip.id) tot
    FROM NPIProjects npip LEFT OUTER JOIN DieInformation di ON di.NPIProjectid = npip.id
    LEFT OUTER JOIN TrimProbeInformation tpi ON tpi.Id = di.TrimProbeInformation_id
    LEFT OUTER JOIN TrimProbeGrades tpg ON tpg.TrimProbeInformation_Id = tpi.Id
    LEFT OUTER JOIN TrimProbePasses tpp ON tpp.TrimProbeGrades_Id = tpg.Id)
    WHERE rnum=tot START WITH rnum =1 CONNECT BY PRIOR rnum = rnum-1 AND PRIOR NPIProjectID = NPIProjectID)rtppd
    WHERE nrtd.ID = rtpid.NPIProjectID
    AND rtpid.NPIProjectID = rtgd.NPIProjectID
    AND nrtd.ID = rtpd.NPIProjectID
    AND nrtd.ID = rnmd.NPIProjectID
    AND nrtd.ID = nmwigen.NPIProjectID
    AND rtgd.NPIProjectID = rwid.NPIProjectID
    AND nrtd.ID = rtpgd.NPIProjectID
    AND nrtd.ID = rtppd.NPIProjectID

    Two thoughts.
    1. ORA-00600 = open an SR at metalink
    2. Oracle 9i is in desupport so Oracle is going to suggest that you move this to a currently supported version: Especially if 9i means anything other than 9.2.0.8.
    Your query will likely be put to good use by Oracle showing how E-Business Suite is superior to SAP. <g>

  • ORA-01017: invalid username/password through dblink when select from view

    Hello all,
    I work on 2 databases :
    - One is a 10g (let's call it db_10 )
    - The second one is a 11g (let's call it db_11 )
    I created a view V_PROTOCOLES in schema SCHEMA_1 on db_11.
    The FROM clause of this view call 4 tables :
    - table1 : owner is SCHEMA_1
    - table2 : owner is SCHEMA_2 (schema on db_11 )
    - table3 : owner is SCHEMA_3 (schema on db_10 )
    - table4 : owner is SCHEMA_4 (schema on db_10 )
    When I simply run SELECT * FROM V_PROTOCOLES on db11 with user X, I can have a result.
    The problem occurs when I connect on db10 also with user X. The V_PROTOCOLES view has a public synonym using the dblink DBDOC_LINK (without explicitly specify a user, so it connects with the X user).
    But here I can't run the SELECT * FROM V_PROTOCOLES. I Have the following error :
    ORA-01017: invalid username/password; logon denied
    ORA-02063: preceding line from DBDOC_LINKThe passwords for user X are obviously the same on both 10g and 11g databases.
    Thanks for the help !

    On 10g :
    select password from dba_users where username = 'U872574';
    PASSWORD
    30811840BC618B77On 11g :
    select password from sys.user$ where name='U872574';
    PASSWORD
    30811840BC618B77I dropped and recreated the dblink but the problem always occurs...
    (By the way, curiously when I dropped the dblink I have no invalid objects although it is used in different packages or triggers)

  • Error when selecting from view created by OLAP_TABLE

    Hi all,
    I used OWB 10.2.0.4 to create a MOLAP datawarehouse.
    I created a view with this:
    CREATE OR REPLACE VIEW sales_view AS
    SELECT *
    FROM TABLE(OLAP_TABLE(
    'dw duration session',
    'MEASURE samt AS number(16,0) FROM SALES_SAMT
    DIMENSION cust_code AS varchar2(30) FROM cust
    DIMENSION prod_code AS varchar2(30) FROM prod
    DIMENSION sman_code AS varchar2(30) FROM sman
    DIMENSION time_id AS varchar2(30) FROM time
    DIMENSION orgn_code AS varchar2(30) FROM orgn'));
    and I try to run the following:
    select count(*) from sales_view;
    and I got the following error:
    Error starting at line 1 in command:
    select count(*) from sales_view
    Error report:
    SQL Error: ORA-29400: data cartridge error
    ORA-00600: internal error code, arguments: [xsvaluekeyget: type], [114], [], [], [], [], [], []
    29400. 00000 - "data cartridge error\n%s"
    *Cause:    An error has occurred in a data cartridge external procedure.
    This message will be followed by a second message giving
    more details about the data cartridge error.
    *Action:   See the data cartridge documentation
    for an explanation of the second error message.
    Can somebody give me some idea?
    Many thanks!
    - Andrew

    Brijesh,
    Really appreciate your help!
    With your hint (#2), I found my problems.
    I had 2 problems:
    1) I'm missing the 'Model' clause at the end of my view creation (in bold )
    2) I shouldn't do a count on all rows (e.g. I get result if I select with parameters)
    Here's my working view:
    CREATE OR REPLACE VIEW SALES_VIEW2
    AS
    SELECT * FROM TABLE(OLAP_TABLE(
    'DW DURATION SESSION',
    MEASURE SAMT FROM SALES_SAMT1
    DIMENSION PROD_CODE FROM PROD
    DIMENSION SMAN_CODE FROM SMAN
    DIMENSION TIME_CODE FROM TIME
    DIMENSION CUST_CODE FROM CUST
    DIMENSION ORGN_CODE FROM ORGN
    MODEL
    DIMENSION BY(PROD_CODE, CUST_CODE, SMAN_CODE, TIME_CODE, ORGN_CODE)
    MEASURES(SAMT)
    RULES UPDATE SEQUENTIAL ORDER();
    -----

  • Select from (too many) tables

    Hi all,
    I'm a proud Oracle Apex developer. We have developed an Interactive Report that is generated from many joined tables in a remote system. I've read that to improve performances we can do the following:
    1) Create a temporary table on our system that stores the app_user id and the colmun as a result of the query
    2) Create a procedure that does:
    declare
    param1:= :PXX_item
    param2:= :PXY_item.
    param3:= :V('APP_USER')
    insert into <our_table>
    (select param3, <query from remore system>)
    commit;
    3) Rediresct to a query page where IR reads from this temp table
    On "Exit" button there's a procedure that purge table data of that user (delete from temp where user=V('app_user'), so the temp table is only filled with necessary data.
    Do you see any inconvenience? Application will be used from about 500 users, about 50 concurrent users at a time.
    Thank you!

    1) We don't have a control on source syste, we can only perform query on itI was referring to a materialized view on the system where Apex is installed, not on the source database.
    2) There are many tables involvedI don't understand why this is a problem. Too much data I can see, but too many tables... not so much.
    3) Data has to be in real time, with no delayThis would a problem for MV or collections. The collections would store the data as of the initial query. Any IRs using the collection after the fact would be using stale data. If you absolutely have to have the data as of right now every time, then the full query must run on the remote system every time. Tuning that query is the only option to make it faster.
    4) There are many transactions on the source tables (they are the core of the source system) and so MV could not be refreshed so fastProbably could be with fast refresh enabled, but not necessarily practical to do so. As I indicated in 3, you have painted yourself into a corner here. You have indicated a need for a real-time query and that eliminates a number of possibilities for query-once use-many performance solutions.

  • Select from local (tmp) Table in Function - Table not found

    Hi,
    I want to create a cursor which selects from a Table which does not exist in database.
    I create this table as local table (how is it called? nested table?).
    Not shown in the code but I want to fill this local table later.
    After filled my cursor is going to use this filled table.
    When try to run I get the error Table or View does not exist at the "FROM TempTab_var T1;" of my cursor.
    This is my simplified code:
    CREATE OR REPLACE FUNCTION PC_RL_MTA_PMT
    RETURN PC_RL_MTA_TYPE_PMT
    IS
    result_out PC_RL_MTA_TYPE_PMT;
      TYPE TempTab_record_type IS RECORD
        (ID int);
      TYPE TempTab_type IS TABLE OF TempTab_record_type
              INDEX BY BINARY_INTEGER;
      TempTab_var TempTab_type;
      CURSOR TempCursor3_var IS
        SELECT    ID AS ID_var
        FROM    TempTab_var T1;
    BEGIN
    RETURN result_out;
    END PC_RL_MTA_PMT;
    Any Ideas whats wrong?
    Thanks very much in advance.

    And a further example from my library of examples, just to help you out...
    SQL> CREATE OR REPLACE TYPE num_descript AS OBJECT(num number, descript varchar2(30))
      2  /
    Type created.
    SQL> CREATE OR REPLACE TYPE tbl_num_descript AS TABLE OF num_descript
      2  /
    Type created.
    SQL> CREATE OR REPLACE PACKAGE reftest AS
      2    FUNCTION pipedata(p_choice number) RETURN tbl_num_descript PIPELINED;
      3  END;
      4  /
    Package created.
    SQL> CREATE OR REPLACE PACKAGE BODY reftest AS
      2    FUNCTION pipedata(p_choice number) RETURN tbl_num_descript PIPELINED IS
      3      v_obj num_descript := num_descript(NULL,NULL);
      4      v_rc  sys_refcursor;
      5    BEGIN
      6      IF p_choice = 1 THEN
      7        OPEN v_rc FOR SELECT empno as num, ename as descript FROM emp;
      8      ELSIF p_choice = 2 THEN
      9        OPEN v_rc FOR SELECT deptno as num, dname as descript FROM dept;
    10      END IF;
    11      LOOP
    12        FETCH v_rc INTO v_obj.num, v_obj.descript;
    13        EXIT WHEN v_rc%NOTFOUND;
    14        PIPE ROW(v_obj);
    15      END LOOP;
    16      CLOSE v_rc;
    17      RETURN;
    18    END;
    19  END;
    20  /
    Package body created.
    SQL> select * from table(reftest.pipedata(1));
           NUM DESCRIPT
          7369 SMITH
          7499 ALLEN
          7521 WARD
          7566 JONES
          7654 MARTIN
          7698 BLAKE
          7782 CLARK
          7788 SCOTT
          7839 KING
          7844 TURNER
          7876 ADAMS
          7900 JAMES
          7902 FORD
          7934 MILLER
    14 rows selected.
    SQL> select * from table(reftest.pipedata(2));
           NUM DESCRIPT
            10 ACCOUNTING
            20 RESEARCH
            30 SALES
            40 OPERATIONS

  • Problems managing select * from views

    Here a nice sample..
    I have a registered schema and a database with 8000 records.
    Create view first_search_view as
    select extractvalue(XML_CONTENT,'/word/@class') class,
    extractValue(xml_content, '/word/*/lemma/text()') lemma,
    extractValue(xml_content, '/word/*/adverb/form/w/text()') adverb_form,
    extractValue(xml_content, '/word/*/derivation/prebasuf/w/text()') derprebasuf,
    extractValue(xml_content, '/word/*/sense/comword/prebasuf/w/text()') comprebasuf,
    extract(xml_content, '/word/*/sense/collocation/pattern/w/text()').getstringval() colpattern,
    extract(xml_content, '/word/*/idiomExpr/pattern/w/text()') idiompattern,
    extract(xml_content, '/word/*/sense/model/realisation/modpattern/w/text()').getstringval() modpattern,
    extract(xml_content, '/word/*/sense/*/definition/w/text()').getstringval() definition,
    extract(xml_content, '/word/*/sense/description/characteristic/quality/w/text()').getstringval() descquality
    from xml_words
    all ok and infact
    SQL> desc first_search_view;
    Name Null? Type
    CLASS VARCHAR2(4000 CHAR)
    LEMMA VARCHAR2(4000)
    ADVERB_FORM VARCHAR2(4000)
    DERPREBASUF VARCHAR2(4000)
    COMPREBASUF VARCHAR2(4000)
    COLPATTERN VARCHAR2(4000)
    IDIOMPATTERN SYS.XMLTYPE
    MODPATTERN VARCHAR2(4000)
    DEFINITION VARCHAR2(4000)
    DESCQUALITY VARCHAR2(4000)
    But then, when I try to run just:
    Create table first_search as
    select *
    from first_search_view
    The answer is
    ERROR at line 3:
    ORA-19010: Cannot insert XML fragments
    I remove the XMLtype field... I think that it is probably the problem.
    Create table first_search as
    select lemma, adverb_form, DERPREBASUF, COMPREBASUF, COLPATTERN, MODPATTERN, DEFINITION, DESCQUALITY
    from first_search_view
    from first_search_view
    ERROR at line 3:
    ORA-19025: EXTRACTVALUE returns value of only one node
    but if I run the select....
    select lemma, adverb_form, DERPREBASUF, COMPREBASUF, COLPATTERN, MODPATTERN, DEFINITION, DESCQUALITY
    from first_search_view
    It is executed!!!
    There is something wrong.... Really I cannot understand the reason of this.
    Anyone could calrify what could be wrong?
    Stefano

    Stefano, since you did not post the latest xml instance, i have taken the one posted in your previous thread .
    So becuase of which i have to change the XPATH for "idiompattern" column to get some data.
    I too had the same problem as you have posted. But when i added a GetStringVal() method to the expression, it converts it to varchar data type and you are able to create the table. Also you can do GetClobVal if the string has chance to exceed 4000 characters. Later you can convert this to XMLTYPE when ever required.
    declare
      l_xml_data CLOB :=
      '<word class="adjective" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://words.xsd">
      <adjective id="de.a.warm.1">
      <lemma>warm</lemma>
      <morphology>
      <rawData>warm - wärmer - wärmst-</rawData>
      </morphology>
      <sense>
      <adjectiveSubsense>
      <definition>
      <rawData>Warm bedeutet, dass etwas eine relativ hohe Temperatur hat, aber nicht heiß ist.</rawData>
      </definition>
      <translation>
      <rawData>caldo</rawData>
      </translation>
      <example>
      <rawData>Angenehm warme Sommertemperaturen zwischen 24 und 26 Grad werden in der kommenden Woche erwartet. Es ist nicht übermäßig heiß, aber trotzdem warmes Badewetter.</rawData>
      </example>
      </adjectiveSubsense>
      <adjectiveSubsense>
      <definition>
      <rawData>Warm verwendet man für Essen, das gekocht und noch warm (1) ist.</rawData>
      </definition>
      <translation>
      <rawData>caldo</rawData>
      </translation>
      <example>
      <rawData>Das Essen steht auf dem Tisch! Würdest du bitte zu Tisch kommen, solange das Essen noch warm ist!~Ich komm ja gleich, ich muss nur noch schnell das Kapitel fertig lesen!</rawData>
      </example>
      </adjectiveSubsense>
      <insertElement target="field">de.a.warm.1.f1</insertElement>
      <collocation>
      <pattern>
      <rawData>jemdm. ist warm</rawData>
      </pattern>
      <translation>
      <rawData>qualcuno ha caldo</rawData>
      </translation>
      <example>
      <rawData>#Mir #ist #warm. Ich werde meinen Pullover ausziehen!</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>etw. ist angenehm warm</rawData>
      </pattern>
      <translation>
      <rawData>qualcosa è bello caldo</rawData>
      </translation>
      <example>
      <rawData>Der Tee ist nicht mehr zu heiß. #Er #ist #angenehm #warm und gerade richtig zum Trinken.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>es ist warm</rawData>
      </pattern>
      <translation>
      <rawData>fa caldo</rawData>
      </translation>
      <example>
      <rawData>Kaum scheint nach dem Sommergewitter wieder die Sonne, #ist #es sofort wieder #warm.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>ein warmes Bad nehmen</rawData>
      </pattern>
      <translation>
      <rawData>farsi un bagno caldo</rawData>
      </translation>
      <example>
      <rawData>Ich bin völlig durchnässt und erfroren nach Hause gekommen. Dann #habe ich #ein #warmes #Bad #genommen, um mich wieder aufzuwärmen.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warm essen</rawData>
      </pattern>
      <translation>
      <rawData>fare un pasto caldo</rawData>
      </translation>
      <example>
      <rawData>In diesem Restaurant ist die Küche bis 23 Uhr geöffnet und man kann #warm #essen.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>etw. warm stellen</rawData>
      </pattern>
      <translation>
      <rawData>mettere in caldo qualcosa</rawData>
      </translation>
      <example>
      <rawData>Herr Tieser hat sich zum Abendessen verspätet und seine Familie hat mit dem Essen nicht auf ihn gewartet. Sie #haben ihm #das #Risotto jedoch #warm #gestellt.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warmes Wasser</rawData>
      </pattern>
      <translation>
      <rawData>acqua calda</rawData>
      </translation>
      <example>
      <rawData>Die Hausverwaltung weist die Parteien darauf hin, dass wegen Reparaturarbeiten morgen zwischen 9 und 12 Uhr #das #warme #Wasser abgestellt wird.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warme Tage, warme Luft, ein warmes Klima, ein warmer Winter, ein warmer Sommer ...</rawData>
      </pattern>
      <translation>
      <rawData>giornate calde, aria calda, un clima caldo, un inverno caldo, un''esate calda ...</rawData>
      </translation>
      <example>
      <rawData>Ich habe seit drei Tagen Kopfschmerzen. Vermutlich liegt das am Föhn und #dieser #warmen #Luft, die ich nicht vertrage.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>eine warme Mahlzeit, enie warme Speise, ein warmes Essen ...</rawData>
      </pattern>
      <translation>
      <rawData>un pasto caldo, un piatto caldo, un pasto caldo ...</rawData>
      </translation>
      <example>
      <rawData>Nachdem ich in den letzten Tagen immer nur Salat gegessen habe, freue ich mich heute wieder darauf, #eine #warme #Speise zu genießen.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warme und kalte Küche</rawData>
      </pattern>
      <translation>
      <rawData>piatti caldi e freddi</rawData>
      </translation>
      <example>
      <rawData>Die Cafeteria der Uni bietet durchgehend #warme #Küche an.</rawData>
      </example>
      </collocation>
      </sense>
      <sense>
      <adjectiveSubsense>
      <definition>
      <rawData>Warm bedeutet, dass etwas so ist, dass es vor Kälte schützt.</rawData>
      </definition>
      <translation>
      <rawData>caldo</rawData>
      </translation>
      <example>
      <rawData>Die Schuhverkäuferin preist die neue Ware an: Die gefütterten Winterschuhe sind sehr warm. Sie werden nie wieder kalte Zehen bekommen!</rawData>
      </example>
      </adjectiveSubsense>
      <insertElement target="field">de.a.warm.1.f2</insertElement>
      <collocation>
      <pattern>
      <rawData>etw. hält warm</rawData>
      </pattern>
      <translation>
      <rawData>qualcosa tiene caldo</rawData>
      </translation>
      <example>
      <rawData>Die selbst gestrickten Socken sind zwar kratzig, aber #sie #halten ausgesprochen #warm!</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>sich warm anziehen</rawData>
      </pattern>
      <translation>
      <rawData>mettersi indumenti caldi~coprirsi bene</rawData>
      </translation>
      <example>
      <rawData>#Zieh #dich #warm an, wenn du bei dem Sturm hinausgehst, sonst verkühlst du dich noch!</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>sich warm zudecken</rawData>
      </pattern>
      <translation>
      <rawData>coprirsi bene</rawData>
      </translation>
      <example>
      <rawData>Nach der Gutenachtgeschichte macht Vati das Licht aus, #deckt #mich #warm #zu und wünscht mir süße Träume.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warm angezogen sein</rawData>
      </pattern>
      <translation>
      <rawData>indossare vestiti caldi, essere coperto bene</rawData>
      </translation>
      <example>
      <rawData>Bei diesen arktischen Temperaturen ist es wichtig, dass man #warm #angezogen #ist, wenn man das Haus verlässt.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warm eingepackt sein</rawData>
      </pattern>
      <translation>
      <rawData>essere imbacuccato, essere coperto bene</rawData>
      </translation>
      <example>
      <rawData>Die Kinder spielen auf dem Kinderspielplatz. Sie #sind wegen des kalten Wetters sehr #warm #eingepackt und haben Mütze, Schal und Handschuhe an.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warme Kleidung</rawData>
      </pattern>
      <translation>
      <rawData>indumenti caldi</rawData>
      </translation>
      <example>
      <rawData>Ab Jänner ist die #warme Winterkleidung bereits im Ausverkauf und die Frühlingsmode erscheint in den Schaufenstern.</rawData>
      </example>
      </collocation>
      </sense>
      <sense>
      <adjectiveSubsense>
      <definition>
      <rawData>Warm bedeutet freundlich und dass es von Herzen kommt.</rawData>
      </definition>
      <translation>
      <rawData>caldo~caloroso</rawData>
      </translation>
      <example>
      <rawData>Frau Hanse ist eine warme Frau. Sie interessiert sich immer ehrlich für das Wohlbefinden ihrer Nachbarn und ihr Mitgefühl kommt von Herzen.</rawData>
      </example>
      </adjectiveSubsense>
      <insertElement target="field">de.a.warm.1.f3</insertElement>
      <collocation>
      <pattern>
      <rawData>ein warmes Herz</rawData>
      </pattern>
      <translation>
      <rawData>un cuore caldo</rawData>
      </translation>
      <example>
      <rawData>Auf Anne kann man immer zählen. Sie hat #ein #warmes #Herz, hört einem immer zu und ist bei jedem Spass dabei. Sie ist eine gute Freundin.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warme Worte</rawData>
      </pattern>
      <translation>
      <rawData>parole calorose</rawData>
      </translation>
      <example>
      <rawData>#Die #warmen, verständnisvollen #Worte taten meiner Seele gut und munterten mich wieder auf.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>ein warmer Händedruck</rawData>
      </pattern>
      <translation>
      <rawData>una calorosa stretta di mano</rawData>
      </translation>
      <example>
      <rawData>#Mit #einem #warmen #Händedruck verabschiedeten sich die beiden Freunde herzlich voneinander.</rawData>
      </example>
      </collocation>
      </sense>
      <sense>
      <adjectiveSubsense>
      <definition>
      <rawData>Warm verwendet man für Farben und Licht, die kräftig sind und warm (1a) wirken und die eine angenehme Antmosphäre verbreiten.</rawData>
      </definition>
      <translation>
      <rawData>caldo</rawData>
      </translation>
      <example>
      <rawData>Die Farbpalette wird in kalte und warme Farben eingeteilt. Rot und orange sind zum Beispiel warme Farben.</rawData>
      </example>
      </adjectiveSubsense>
      <insertElement target="field">de.a.warm.1.f4</insertElement>
      <collocation>
      <pattern>
      <rawData>etw. spendet warmes Licht</rawData>
      </pattern>
      <translation>
      <rawData>qalcosa emette una luce calda</rawData>
      </translation>
      <example>
      <rawData>#Die #flackernde #Kerze #spendet #warmes #Licht und taucht den Raum in eine behagliche Atmosphäre.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>warme Farben</rawData>
      </pattern>
      <translation>
      <rawData>colori caldi</rawData>
      </translation>
      <example>
      <rawData>Der Innenarchitekt empfiehlt dem jungen Ehepaar, #warme #Farben für das Kinderzimmer zu wählen, da sie ein Bedürfnis nach Harmonie wecken.</rawData>
      </example>
      </collocation>
      <collocation>
      <pattern>
      <rawData>ein warmes Braun, ein warmes Rot ...</rawData>
      </pattern>
      <translation>
      <rawData>un marrone caldo, un rosso caldo ...</rawData>
      </translation>
      <example>
      <rawData>Der Sonnenuntergang war sehr romantisch. #Das #warme #Rot der Sonne hat sich im Meer gespiegelt. Schließlich ist sie wie ein großer Ball am Horizont verschwunden.</rawData>
      </example>
      </collocation>
      </sense>
      <sense>
      <adjectiveSubsense>
      <definition>
      <rawData>Warm bedeutet, dass die Kosten für die Heizung bei der Miete schon dabei ist.</rawData>
      </definition>
      <translation>
      <rawData>riscaldamento incluso</rawData>
      </translation>
      <example>
      <rawData>Roland erkundigt sich beim Vermieter über die Mietkosten. Dieser erklärt ihm, dass die Wohnung 800 Euro im Monat warm kostet.</rawData>
      </example>
      </adjectiveSubsense>
      <insertElement target="field">de.a.warm.1.f5</insertElement>
      <collocation>
      <pattern>
      <rawData>das Zimmer, die Wohnung ... kostet x Euro warm</rawData>
      </pattern>
      <translation>
      <rawData>la camera, l''appartamento ... costa x euro riscaldamento incluso</rawData>
      </translation>
      <example>
      <rawData>Ich habe ein neues Zimmer gemietet. Die Kosten für die Heizung sind schon inklusive. Es kostet also 300 Euro warm.</rawData>
      </example>
      </collocation>
      </sense>
      <derivation>
      <prebasuf>
      <rawData>auf_wärm_en</rawData>
      </prebasuf>
      <translation>
      <rawData>(ri)scaldare</rawData>
      </translation>
      </derivation>
      <derivation>
      <prebasuf>
      <rawData>die Er_wärm_ung</rawData>
      </prebasuf>
      <translation>
      <rawData>il riscaldamento</rawData>
      </translation>
      </derivation>
      <derivation>
      <prebasuf>
      <rawData>er_wärm_en</rawData>
      </prebasuf>
      <translation>
      <rawData>(ri)scaldare, appassionare</rawData>
      </translation>
      </derivation>
      <derivation>
      <prebasuf>
      <rawData>vor_wärm_en</rawData>
      </prebasuf>
      <translation>
      <rawData>preriscaldare</rawData>
      </translation>
      </derivation>
      <derivation>
      <prebasuf>
      <rawData>die Wärme</rawData>
      </prebasuf>
      <translation>
      <rawData>il caldo, il calore</rawData>
      </translation>
      </derivation>
      <derivation>
      <prebasuf>
      <rawData>wärmen</rawData>
      </prebasuf>
      <translation>
      <rawData>(ri)scaldare</rawData>
      </translation>
      </derivation>
      <idiomExpr>
      <pattern>
      <rawData>sich warm machen</rawData>
      </pattern>
      <explanationDE>
      <rawData>vor dem Sport oder vor einem Wettbewerb Gymnastik machen, um die Muskeln aufzulockern</rawData>
      </explanationDE>
      <explanationIT>
      <rawData>fare ginnastica per scigliere i muscoli prima di una gara sportiva</rawData>
      </explanationIT>
      <translation>
      <rawData>riscaldarsi, fare riscaldamento</rawData>
      </translation>
      <example>
      <rawData>In einer halben Stunde beginnt der Wettkampf. Davor muss ich #mich noch #warm #machen.</rawData>
      </example>
      </idiomExpr>
      <idiomExpr>
      <pattern>
      <rawData>sich warm reden</rawData>
      </pattern>
      <explanationDE>
      <rawData>beim Reden seine Befangenheit, Zurückhaltung verlieren</rawData>
      </explanationDE>
      <explanationIT>
      <rawData>vincere la timidezza e la riservatezza e iniziare a parlare con scorrevolezza</rawData>
      </explanationIT>
      <translation>
      <rawData>sciogliersi, sciogliere la lingua</rawData>
      </translation>
      <example>
      <rawData>Mein Vortrag war sehr gut. Nach nur fünf Minuten #hatte ich #mich #warm #geredet und dann habe ich über eine halbe Stunde fließend geredet.</rawData>
      </example>
      </idiomExpr>
      <idiomExpr>
      <pattern>
      <rawData>mit jemdm./etw. (nicht) warm werden</rawData>
      </pattern>
      <comment>
      <rawData>umgangssprachlich</rawData>
      </comment>
      <explanationDE>
      <rawData>mit jemdm./etw. (nicht) vertraut werden und (nicht) sympathisch finden</rawData>
      </explanationDE>
      <explanationIT>
      <rawData>(non) acquisire familiarità con qualcuno/qualcosa</rawData>
      </explanationIT>
      <translation>
      <rawData>(non) entrare in confidenza con qualcuno/(non) prendere confidenza con qualcosa</rawData>
      </translation>
      <example>
      <rawData>Zu Claudia habe ich noch immer kein herzliches Verhältnis gefunden. Ich #werde einfach #nicht #warm #mit #ihr.</rawData>
      </example>
      </idiomExpr>
      </adjective>
      </word>';
    begin
      insert into xml_table values(1, xmltype(l_xml_data));
    end;
    Create or replace view first_search_view as
    select extractvalue(xml_data,'/word/@class') class,
      extractValue(xml_data, '/word/*/lemma/text()') lemma,
      extractValue(xml_data, '/word/*/adverb/form/w/text()') adverb_form,
      extractValue(xml_data, '/word/*/derivation/prebasuf/w/text()') derprebasuf,
      extractValue(xml_data, '/word/*/sense/comword/prebasuf/w/text()') comprebasuf,
      extract(xml_data, '/word/*/sense/collocation/pattern/w/text()').getstringval() colpattern,
    extract(xml_data, '/word/*/idiomExpr/pattern').GetClobVal() idiompattern,
      extract(xml_data, '/word/*/sense/model/realisation/modpattern/w/text()').getstringval() modpattern,
      extract(xml_data, '/word/*/sense/*/definition/w/text()').getstringval() definition,
      extract(xml_data, '/word/*/sense/description/characteristic/quality/w/text()').getstringval() descquality
    from xml_table
    create table test_xml_table
    as
    select * from first_Search_view
    SQL> desc first_search_View
    Name                                                  Null?    Type
    CLASS                                                          VARCHAR2(4000)
    LEMMA                                                          VARCHAR2(4000)
    ADVERB_FORM                                                    VARCHAR2(4000)
    DERPREBASUF                                                    VARCHAR2(4000)
    COMPREBASUF                                                    VARCHAR2(4000)
    COLPATTERN                                                     VARCHAR2(4000)
    IDIOMPATTERN                                                   CLOB
    MODPATTERN                                                     VARCHAR2(4000)
    DEFINITION                                                     VARCHAR2(4000)
    DESCQUALITY                                                    VARCHAR2(4000)
    SQL> desc test_xml_table
    Name                                                  Null?    Type
    CLASS                                                          VARCHAR2(4000)
    LEMMA                                                          VARCHAR2(4000)
    ADVERB_FORM                                                    VARCHAR2(4000)
    DERPREBASUF                                                    VARCHAR2(4000)
    COMPREBASUF                                                    VARCHAR2(4000)
    COLPATTERN                                                     VARCHAR2(4000)
    IDIOMPATTERN                                                   CLOB
    MODPATTERN                                                     VARCHAR2(4000)
    DEFINITION                                                     VARCHAR2(4000)
    DESCQUALITY                                                    VARCHAR2(4000)
    SQL> set linesize 200
    SQL> column class format a20
    SQL> column idiompattern format a70
    SQL>
    SQL> select class,  idiompattern from test_xml_table
      2  /
    CLASS                IDIOMPATTERN
    adjective            <pattern>
                           <rawData>sich warm machen</rawData>
                         </pattern>
                         <pattern>
                           <rawData>sich warm reden</rawData>
                         </pattern>
                         <pattern>
                           <rawData>mit jemdm./etw. (nicht) warm werden</rawData>
                         </pattern>
    SQL>

  • SQLite - select * from view

    Hello All,
    I'm completely new to this forum. I've got some pretty big tables and have created views to hold some predefined data in them.
    Now sqlite application I've used (Lita, SQLiteAdmin) does not see these views. Only from Firefox SQLiteManager add-on or the command line,  I can do a select * from my_view;
    Now when I try to query my view from Air, I receive the error #3115 table : my_view does not exist? Is there a litmitation in Air to be able to query ONLY tables?
    Thanks
    Jan

    There is no limitation against getting at view data using a select.  Here is an overly simple example using a synchronous connection:
    var conn:SQLConnection = new SQLConnection();
    conn.open(File.applicationStorageDirectory.resolvePath("test.db"));
    var sql:SQLStatement = new SQLStatement();
    sql.sqlConnection = conn;
    sql.text = "CREATE TABLE IF NOT EXISTS employees (id Integer, name String);";
    sql.execute();
    sql.text = "INSERT INTO employees VALUES (1, 'Sam');";
    sql.execute();
    sql.text = "INSERT INTO employees VALUES (2, 'Bob');";
    sql.execute();
    sql.text = "CREATE VIEW IF NOT EXISTS emp_view AS SELECT name FROM employees WHERE name LIKE 'B%';";
    sql.execute();
    sql.text = "SELECT * FROM emp_view;";
    sql.execute();
    trace(ObjectUtil.toString(sql.getResult().data));
    Which outputs:
    (Array)#0
      [0] (Object)#1
        name = "Bob"

Maybe you are looking for

  • How do I know I have antivirus in my mac?

    Hi, I purchased a refurbished laptop a year ago, and i'm not sure this laptop has any antivirus program. This is my first time use of mac and it's quite confusing. How do I find any antivirus program in my mac? If I don't have it, then which antiviru

  • Time Capsule and Linksys Buffalo NAS

    I am struggling with my new TC and looking for some pointers. What I want to be able to do is have setup my network they way it used to be before my linksys router crapped out... only now with TC I want the added time machine backup capability. what

  • WITH clause in reports

    Just a quick question about Reports 10g, does it support queries using the WITH clause? i.e. WITH alias as (subquery) SELECT col1, col2... FROM aliasI can't find anything on the documentation on the OTN site. Reports 9iR2 croaks with this unfortunate

  • BPC 10.0 - Equity Pickup?

    Dear All, In BPC 10.0, there is a new feature called Equity Pick-up. What is it used for? I can google about this. But, I would like to hear(authentic) from you - professionals, on the practical usage of it. Thank you! Regards, Peri

  • ADF validation popup problem

    Dear all, I have three text box and i validate with custom adf validation. when all validation fail, one error popup window appear and show the all error message on there. I want to remove popup window. can i ? With Regards, Wai Phyo