ODI not able to detect primary/foreign keys from XML- user lacks privilege or object not found

Hi Guys,
Im trying to load an xml file with two entities address and employee as below. The topology reverse engineering everything works fine. Im even able to view the xml data  in ODI,  but when i try to load the data from these two entities joining by the schema primary keys and foreign keys which odi created on reverse engineering process for xml, im getting the below error.  Im able to load data from one entity, error only occurs when i use the join odi creates internally to identify the xml components employee and address
XML File:
<?xml version="1.0" encoding="UTF-8" ?>
<EMP>
<Empsch>
<Employee>
<EmployeeID>12345</EmployeeID>
<Initials>t</Initials>
<LastName>john</LastName>
<FirstName>doe</FirstName>
</Employee>
<Address>
<WorkPhone>12345</WorkPhone>
<WorkAddress>Test 234</WorkAddress>
</Address>
</Empsch>
</EMP>
Topology:  jdbc:snps:xml?f=C:/Temp/RR/Empsch.xml&s=Empsch&re=EMP&dod=true&nobu=false
Error Message:
-5501 : 42501 : java.sql.SQLException: user lacks privilege or object not found: EMPSCH.EMPSCHPK
java.sql.SQLException: user lacks privilege or object not found: EMPSCH.EMPSCHPK
    at org.hsqldb.jdbc.Util.sqlException(Unknown Source)
    at org.hsqldb.jdbc.JDBCPreparedStatement.<init>(Unknown Source)
    at org.hsqldb.jdbc.JDBCConnection.prepareStatement(Unknown Source)
    at com.sunopsis.jdbc.driver.xml.SnpsXmlConnection.prepareStatement(SnpsXmlConnection.java:1232)
    at sun.reflect.GeneratedMethodAccessor65.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at oracle.odi.core.datasource.dwgobject.support.OnConnectOnDisconnectDataSourceAdapter$OnDisconnectCommandExecutionHandler.invoke(OnConnectOnDisconnectDataSourceAdapter.java:200)
    at $Proxy2.prepareStatement(Unknown Source)
    at oracle.odi.runtime.agent.execution.sql.SQLCommand.doInitializeStatement(SQLCommand.java:83)
    at oracle.odi.runtime.agent.execution.sql.SQLCommand.getStatement(SQLCommand.java:117)
    at oracle.odi.runtime.agent.execution.sql.SQLCommand.getStatement(SQLCommand.java:111)
    at oracle.odi.runtime.agent.execution.sql.SQLDataProvider.readData(SQLDataProvider.java:81)
    at oracle.odi.runtime.agent.execution.sql.SQLDataProvider.readData(SQLDataProvider.java:1)
    at oracle.odi.runtime.agent.execution.DataMovementTaskExecutionHandler.handleTask(DataMovementTaskExecutionHandler.java:70)
    at com.sunopsis.dwg.dbobj.SnpSessTaskSql.processTask(SnpSessTaskSql.java:2913)
    at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2625)
    at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:577)
    at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:468)
    at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:2128)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:366)
    at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:216)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:300)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:292)
    at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:855)
    at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:126)
    at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:82)
    at java.lang.Thread.run(Thread.java:662)
Caused by: org.hsqldb.HsqlException: user lacks privilege or object not found: EMPSCH.EMPSCHPK
    at org.hsqldb.error.Error.error(Unknown Source)
    at org.hsqldb.ExpressionColumn.checkColumnsResolved(Unknown Source)
    at org.hsqldb.QueryExpression.resolve(Unknown Source)
    at org.hsqldb.ParserDQL.compileCursorSpecification(Unknown Source)
    at org.hsqldb.ParserCommand.compilePart(Unknown Source)
    at org.hsqldb.ParserCommand.compileStatement(Unknown Source)
    at org.hsqldb.Session.compileStatement(Unknown Source)
    at org.hsqldb.StatementManager.compile(Unknown Source)
    at org.hsqldb.Session.execute(Unknown Source)
    ... 27 more
Please advice
Thanks
Revanth

Thats obvious from the xml file contents you have given here. In this xml file You have four complex type. Two of them are employee and address. However the employee doesnot have any relation with address as you have not added the relationship. Thats why its failing. Its not the fault of ODI.
Also I would suggest not to use auto generated dtd by ODI as you might face problem in future. For example the address type of XML has 8 attributes and 4 of them are not mandatory. That means each of your xml file may have attributes between 4 to 8.  This is where ODI auto generated DTD fails.
XML Schema complexType Element
Thanks
Bhabani

Similar Messages

  • Detect the fields which are primary/foreign keys for each schema's tables

    Hello everybody,
    I'd like to know if it's possible to select a field in one of the dictionary tables to identify the fields of a table which are PK or FK in this one. I'd like to do this to generate the fields that I need to put in a technical design.
    Actually I have this (if it can help you to understand what I'd like to do) :
    select table_name "Table name",
    column_name "Physical field name",
    case when data_type = 'NUMBER' then data_type || '(' || NVL(data_precision,0) || ',' || NVL(data_scale,0) || ')'
    when data_type = 'VARCHAR2' then data_type || '(' || data_length || ')'
    else data_type
    end "Datatype",
    case when nullable = 'Y' then 'FALSE'
    when nullable = 'N' then 'TRUE'
    end "Not null",
    /* Here I'd like to retrieve TRUE or FALSE if the field to display is a primary key or not and the same for foreign keys*/
    from all_tab_columns
    where table_name in (select table_name
    from all_tables
    where table_name like '%project_name%'
    and table_name not like '%TMP%');
    Thanks a lot for your help,
    Florent

    Please investigate all_constraints and all_cons_colums.
    http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14237/toc.htm

  • Missing primary foreign key in grandchild table

    I have a model with a two inheritance generations.
    https://www.dropbox.com/s/4rghqcmxx24bgvt/pf_logical.png
    When I engineer all entities everything is fine. The child tables get their primary foreign keys:
    https://www.dropbox.com/s/t4v5bexxwdrn5y1/pf_engineered.png
    But when I do not engineer the child generation the grandchildren have no primary foreign keys anymore.
    https://www.dropbox.com/s/ofl436sm8dua3w8/pf_missing.png
    I have expected, that the grandchildren get a primary foreign key to the grandfather. But that is not the case. How can I tell the modeler to engineer such a foreign key?

    Hi,
    thanks for reporting the problem. I logged a bug for that.
    Philip

  • Query Builder recognizing primary/foreign key

    Is there a way to have Query Builder recogninze the primary/foreign keys of the tables when they are selected? Right now it looks like you have to manually join the tables together by selected the column(s) to join.
    Thanks

    You can define a query key[1] 'planId' on InvestmentOption for the PLAN_OID column. That'll let you write an expression like the one below which does not produce a join. The nice part about the query key is that it does not require you to add attributes to your object in order to query o them.
    Expression plan = new ExpressionBuilder();
    Expression where = plan.get("planId").equal(somePlanId);--Shaun
    [1] http://www.oracle.com/technology/products/ias/toplink/doc/10131/main/_html/descfg010.htm#sthref3039

  • Create a foreign key from a field that is part of a mulitple primary key

    Hi,
    i had a table named T_A, with a double primary key : (A,B)
    Then i created a table named T_B with a field : C.
    I want this field T_B.C to take only values that already exist in field T_A.A.
    So i tried to create a foreign key on my field T_B.C, pointing on the field T_A.A : an error message appeared "not possible to create a foreign key on a field that is not a primary key".
    How can i solve this....? If U have any idea, please mail me !!
    THANX very much.

    Add column A as foreign key into the table T_BHow?
    (was the question from the original poster. Adding a column to table T_B that happen to have same name as the corresponding column in table T_A would not allow you to add the foreign key).
    SQL> create table t_a (a number, b number, primary key(a, b)) ;
    Table created.
    SQL> create table t_b(a number, c number, constraint foreign key references t_a(a)) ;
    create table t_b(a number, c number, constraint foreign key references t_a(a))
    ERROR at line 1:
    ORA-02270: no matching unique or primary key for this column-list
    SQL>

  • I have tried to update IOS 5.1 in my Iphone 4 and unfortunately I got an error message and phone is stucked at restore point. It is not coming back to normal mode and is not able to detect my phone in iTunes. Please help me how to recover my Iphone IOS

    I have tried to update IOS 5.1 in my Iphone 4 and unfortunately I got an error message and phone is stucked at restore point. It is not coming back to normal mode and is not able to detect my phone in iTunes. Please help me how to recover my Iphone IOS, unfortunately I don't have my iphone backup too.

    we have a same problem

  • Java aplication not able to detect card reader sometimes

    Hi
    We have a Java application (jre1.6.0_05.) which runs as window service under "Local System". It tries to detect card reader after every one minute. Normally it is working fine. However on some machines (which can be Windows XP, 2003 Server etc) some times it is not able to detect Card Reader, while other applications (which are not Java based) are able to detect. Sometimes service restart helps in solving the issue, but it reoccurs again after few hours/days.
    Below is the exception we get:
    javax.smartcardio.CardException: list() failed
    at sun.security.smartcardio.PCSCTerminals.list(PCSCTerminals.java:109)
    at javax.smartcardio.CardTerminals.list(CardTerminals.java:55)
    Below is the code we are using to get list of terminals:
    TerminalFactory factory = TerminalFactory.getDefault();
    try {
    terminals = factory.terminals().list();
    } catch (CardException e) {
    e.printStackTrace();
    }Any idea what might be causing this random problem?

    Hi,
    According to the source for OpenJDK 6 (b19) the only way to get the exception you posted was with a PCSCException being thrown with the root exception wrapped in the new exception.
    // from PCSCTerminals.list(State state)
    try {
        // do some stuff to get the reader list
    } catch (PCSCException e) {
        throw new CardException("list() failed", e);
    }If this was not the case in the version you have, you will definitely see the root cause with the new JDK.
    Cheers,
    Shane

  • My iPhone's bluetooth is not able to detect another iPhone iOS 7.0.6. (latest)

    my iPhone's bluetooth is not able to detect another iPhone iOS 7.0.6. (latest)

    Speakers, keyboards, headsets, pulse monitors, pebble watches, cars with hands free systems, etc.
    Are both phones signed into itunes under the same user?
    are you trying to transfer purchased music to someone else in violation of itunes terms of service?

  • Just purchased a new mac mini 3GHz Intel Core i7, with 16GB ram version 10.10.1. With it i purchased a new wireless keyboard. All of a sudden I was not able to use the #1 key. I thought I had a defected newly purchased keyboard. I pulled out my older

    Just purchased a new mac mini 3GHz Intel Core i7, with 16GB ram version 10.10.1. With it i purchased a new wireless keyboard. All of a sudden I was not able to use the #1 key. I thought I had a defected newly purchased keyboard. I pulled out my older wireless keyboard, and the same thing happened. It must not be the keyboard if it happened to two different keyboards. I have a habit of restarting my computer, when things don't work, I find it helps, and sure enough, everything works. Today, it happened again. Does anyone know what is causing this to happen?

    Try resetting the SMC and PRAM
    Intel-based Macs: Resetting the System Management Controller (SMC)
    About NVRAM and PRAM
    Try reinstalling Yosemite with out losing stuff. See:
    OS X Yosemite: Reinstall OS X

  • HT201263 While updating Iphone 4 to latest on phone itself it got frozed and now apple sign is coming up after every 10-15 secs , even itunes is not able to detect phone, please help

    While updating Iphone 4 to latest on phone itself it got frozed and now apple sign is coming up after every 10-15 secs , even itunes is not able to detect phone, please help

    See Here  >  http://support.apple.com/kb/HT1808
    You may need to try this More than Once...
    Be sure to Follow ALL the Steps...
    But... if the Device has been Modified... this will Not necessarily work.

  • I updated itunes for my 64 bit system to 11.1.4. I was not able to detect my cd drive.  I removed itunes, apple software update, apple mobile device support, bonjour and apple applications support. After a few attempts it now recognizes my cd drive but no

    I updated itunes for my 64 bit system to 11.1.4. I was not able to detect my cd drive.  I removed itunes, apple software update, apple mobile device support, bonjour and apple applications support. After a few attempts it now recognizes my cd drive but not by ipod.  Any suggestions? Thanks.

    I updated itunes for my 64 bit system to 11.1.4. I was not able to detect my cd drive.  I removed itunes, apple software update, apple mobile device support, bonjour and apple applications support. After a few attempts it now recognizes my cd drive but not by ipod.  Any suggestions? Thanks.

  • Is it possible to create foreign key from composite key in other table.

    SQL> desc PRODUCT_CONFIG_OPTION;
    Name Null? Type
    CONFIG_ITEM_ID NOT NULL VARCHAR2(20) --composite primary key
    CONFIG_OPTION_ID NOT NULL VARCHAR2(20) --composite primary key
    CONFIG_OPTION_NAME VARCHAR2(100)
    DESCRIPTION VARCHAR2(255)
    SEQUENCE_NUM NUMBER(18)
    LAST_UPDATED_STAMP TIMESTAMP(6)
    LAST_UPDATED_TX_STAMP TIMESTAMP(6)
    CREATED_STAMP TIMESTAMP(6)
    CREATED_TX_STAMP TIMESTAMP(6)
    SQL> DESC PRODUCT_CONFIG_ITEM;
    Name Null? Type
    CONFIG_ITEM_ID NOT NULL VARCHAR2(20)
    CONFIG_ITEM_TYPE_ID VARCHAR2(20)
    CONFIG_ITEM_NAME VARCHAR2(100)
    DESCRIPTION VARCHAR2(255)
    LONG_DESCRIPTION CLOB
    IMAGE_URL VARCHAR2(255)
    LAST_UPDATED_STAMP TIMESTAMP(6)
    LAST_UPDATED_TX_STAMP TIMESTAMP(6)
    CREATED_STAMP TIMESTAMP(6)
    CREATED_TX_STAMP TIMESTAMP(6)
    SQL> desc product;
    Name Null? Type
    PRODUCT_ID NOT NULL VARCHAR2(20)
    PRODUCT_TYPE_ID VARCHAR2(20)
    PRIMARY_PRODUCT_CATEGORY_ID VARCHAR2(20)
    MANUFACTURER_PARTY_ID VARCHAR2(20)
    FACILITY_ID VARCHAR2(20)
    INTRODUCTION_DATE TIMESTAMP(6)
    SUPPORT_DISCONTINUATION_DATE TIMESTAMP(6)
    SALES_DISCONTINUATION_DATE TIMESTAMP(6)
    SALES_DISC_WHEN_NOT_AVAIL CHAR(1)
    INTERNAL_NAME VARCHAR2(255)
    BRAND_NAME VARCHAR2(100)
    COMMENTS VARCHAR2(255)
    =========
    CREATE TABLE PROD_CONFIG_PROD_CONFIG_OPTION (
    PRODUCT_ID VARCHAR2(20),
    CONFIG_ITEM_ID VARCHAR2(20),
    CONFIG_OPTION_ID VARCHAR2(20),
    PAGE_NUM_TO NUMBER(18),
    ALTERNATE_PAGE_NUM_TO1 NUMBER(18),
    ALTERNATE_PAGE_NUM_TO2 NUMBER(18),
    ALTERNATE_PAGE_NUM_TO3 NUMBER(18),
    LAST_UPDATED_STAMP TIMESTAMP(6),
    LAST_UPDATED_TX_STAMP TIMESTAMP(6),
    CREATED_STAMP TIMESTAMP(6),
    CREATED_TX_STAMP TIMESTAMP(6),
    CONSTRAINT PK_PROD_CAT_CONFIG_MOD PRIMARY KEY (PRODUCT_ID),
    CONSTRAINT FK_PRODUCT_ID FOREIGN KEY (PRODUCT_ID) REFERENCES PRODUCT(PRODUCT_ID),
    CONSTRAINT FK_CONFIG_ITEM_ID FOREIGN KEY (CONFIG_ITEM_ID) REFERENCES PRODUCT_CONFIG_ITEM(CONFIG_ITEM_ID),
    CONSTRAINT FK_CONFIG_OPTION_ID FOREIGN KEY (CONFIG_OPTION_ID) REFERENCES PRODUCT_CONFIG_OPTION(CONFIG_OPTION_ID) )
    TABLESPACE DATA_SMALL
    i try to create this table if i omit 3rd foreign key constraint then table successfully created.but including trd foreign key constraint it return error "ORA-02270: no matching unique or primary key for this column-list"
    i checked everything is it possible to create foreign key from composite key in other table.

    And
    CONSTRAINT FK_CONFIG_OPTION_ID FOREIGN KEY (CONFIG_ITEM_ID,CONFIG_OPTION_ID) REFERENCES PRODUCT_CONFIG_OPTION(CONFIG_ITEM_ID,CONFIG_OPTION_ID)
    ?

  • How to remove foreign key from table?

    i want a query from which i will remove foreign key from the table. plz help me in it. the table is created as follows:
    CREATE TABLE cw06_course
         (coursecode NUMBER(4) CONSTRAINT coursecode_pk PRIMARY KEY,
         department NUMBER(4) CONSTRAINT course_department_nn NOT NULL,
         coursename VARCHAR2(25),
         courseleasder NUMBER(4),
         CONSTRAINT course_department_fk FOREIGN KEY (department) REFERENCES cw06_department(deptno));

    parent keys not foundWell, while the constraint was not available (dropped), someone took the opportunity and inserted rows into your child table that do not have a corresponding value in your parent table.
    Why was the constraint dropped in first place? why did you give someone the opportunity to insert constraint violating value into the table?
    You must either:
    1). remove the child rows not found in parent
    2). create parent rows fr missing child rows.
    3). enable novalidate the constraint so existing values can remain without parent but future rows must confirm.

  • HT2731 Created Apple ID. But Not able to verify. Verification mail is sent on Apple ID and do not know how to check mails in mail box .

    Created Apple ID. But Not able to verify. Verification mail is sent on Apple ID and do not know how to check mails in mail box .

    The verification email will have been sent to the email account that you put as the primary email address on the account - log into that email account as you usually do and you should have an email from Apple.

  • Remote Object - not able to get the returned value from java method

         Hi ,
    I am developing one sample flex aplication that connects to the java code and displays the returned value from the
    java method in flex client. Here I am able to invoke the java method but not able to collect the returned value.
    lastResult is giving null .  I am able to see the sysout messages in server console.
    I am using flex 3.2 and blazeds server  and java 1.5
    Here is the code what I have written.
    <?xml version="1.0" encoding="utf-8"?><mx:WindowedApplication  xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" backgroundColor="#FFFFFF" initialize="initApp()">
     <mx:Script><![CDATA[
    import mx.controls.Alert; 
    import mx.binding.utils.ChangeWatcher; 
    import mx.rpc.events.ResultEvent; 
    import mx.messaging.*; 
    import mx.messaging.channels.* 
    public function initApp():void { 
         var cs:ChannelSet = new ChannelSet(); 
         var customChannel:Channel = new AMFChannel("my-amf", "http://localhost:8400/blazeds/messagebroker/amf");     cs.addChannel(customChannel);
         remoteObj.channelSet = cs;
    public function writeToConsole():void {      remoteObj.writeToConsole(
    "hello from Flash client");
          var returnedVal:String = remoteObj.setName().lastResult;     Alert.show(returnedVal);
    //[Bindable] 
    // private var returnedVal:String; 
    ]]>
    </mx:Script>
    <mx:RemoteObject id="remoteObj" destination="sro" /> 
    <mx:Form width="437" height="281">
     <mx:FormItem>  
    </mx:FormItem>  
    <mx:Button label="Write To Server Console" click="writeToConsole()"/>
     </mx:Form>
     </mx:WindowedApplication>
    Java code
    public  
         public SimpleRemoteObject(){  
              super();     }
      class SimpleRemoteObject { 
         public void writeToConsole(String msg) {          System.out.println("SimpleRemoteObject.write: " + msg);     }
         public String setName(){          System.
    out.println("Name changed in Java"); 
              return "Name changed in Java";
    And I have configured destination in  remote-config.xml
    <destination id="sro">
       <properties>    
        <source>SimpleRemoteObject</source>
        <scope>application</scope>
       </properties>
      </destination>
    Please help me .

    You are not able to get the returned value because if you see the Remote object help you will realise you have to use result="resultfn()" and fault = "faultfn()"
    In this you define what you wish to do.
    More importantly in the remote object you need to define which method you wish to call using the method class like this
    <mx:RemoteObject id="remoteObj" destination="sro" result="r1" fault="f1"  >
         <Method name="javaMethodName" result="r2" fault="f2"/>
    <mx:RemoteObject>
    r2 is the function where you get the result back from java and can use it to send the alert.

Maybe you are looking for

  • Flash Player fails to load on start-up

    I recently upgraded to Flash Player 11.2.202.235 for my Win 7 64 bit system and have had nothing but problems since.  I can install Flash Player and it works fine, until I shut down or restart my system.  Once the system restarts, it is as if Flash P

  • Handle forward & backward TAB

    In the focusLost() event of a component, I need to find if focus has to be set to the next component or to the previous component. Basically identify if TAB or SHIFT+TAB was pressed. How can this be done within the focusLost() event of the component.

  • Deleting messages on iPhone won't delete on .Mac

    I have an issue where if I delete an email on my iPhone and then log in to .Mac mail, I still see the message there. Further inspection shows that the message is in the .Mac trash AND in the inbox - almost like the message was copied rather than move

  • List of the datasources (ECC 6)

    Hi, I just would get the list of all the datasources from the Business content (for ECC 6). I would put them in an Excel sheet (technical name + description). Is there a table in SE16 with all the datasources? Or does it exist a documentation with di

  • HT4400 Rich text email

    How I can write rich text email in my new IPad?? Anybody can help me?