Advantages Of XML Type Views

Hi Every one,
I am pretty new to XML Type views, and just want to ask few questions to every one. May be they do or don't belong here.. but help me out...
1. What are the advantages of XML Type Views?
2. Why should I prefer to use XML Type Views? (Is it only for querying the relational or XML data and result in XML format?)
3. I have a scenario, here I would like to develop a web service which would ultimately call a stored procedure to get relational data. Something like a DAL(Data Access Layer). In this scenario, what are the advantages that I am able to benefit if I use XML Type view with out using the regular stored procedures, which would give relational data(Not in XML format).

1) To define views that output relational data or object relational data in a XML format
2) You give the database more info regarding abouts its XML output / design via XML Schema and or inview defined integers so Oracle is capable to optimize the generation of its XML output
3) Don't over do it. The functionality called Native Database Web Services (NDWS) is already providing this for you natively in Oracle 11g and onwards.
Edited by: Marco Gralike on Jul 14, 2010 9:04 PM

Similar Messages

  • Why can't I view the XML-type in my queries

    I have SQL Developer configured to connect to an Oracle 11g database, using the "thick net". I recently upgraded to version 2.1.1.64.
    I have an issue displaying XML-type results. If I execute a query that returns XML-types, I get the following error: oracle.sql.OPAQUE@e8bd13. Is there a patch, update or tweak I can do to get around this and display the actual results?
    Thanks.

    Can you see the sample schemas and the XMLTYPE in the OE Warehouses table, or does this also issue the same error.? You should be able to see the XML content using SQL Developer 2.1.
    Please note there is also an early adopter for 3.0.
    Sue

  • XML-Type and reference to unavailable DTD causes validation problems

    Hi,
    I'm fairly new to Oracle's XML features. I've created a view that produces XML from a number of tables. The resulting XML is used to be stored on a web site for download by customers (this is a manual process about once a week via a CMS). It contains a reference to a DTD that is available on the web server, too. This XML must also be stored in the Oracle database. The problem is that the Oracle Server is not allowed to access any web site (Oracle server is in inhouse network with no access allowed to the world outside). So I can't store the XML in an XML-type column, as the Oracle server wants to validate the XML against the referenced DTD. There is an option not to validate the XML. But then I get the error when I try to access the XML afterwards. So up to now I use a CLOB column to store the XML, but then I lose all the benefits of an XML-type column. Is there any workaround?
    TIA,
    Stefan

    In 10.2.0.2.0 The following works
    SQL> drop table TEST_XML
      2  /
    Table dropped.
    SQL> create table TEST_XML (
      2     XML_SEQ number(10) not NULL,
      3     XML_DOC XMLType not NULL
      4  )
      5  /
    Table created.
    SQL> drop sequence TEST_XML_SEQ
      2  /
    Sequence dropped.
    SQL> create sequence TEST_XML_SEQ
      2  /
    Sequence created.
    SQL> create or replace view V_EMP_XML as select
      2         -- Processing Instruction
      3         '<?xml version="1.0" encoding="ISO-8859-1"?>' ||
      4         -- DTD reference
      5         '<!DOCTYPE employees SYSTEM "http://myserver/dtd/employees.dtd">' ||
      6         SYS.XMLTYPE.getClobVal(
      7            XMLElement("employees",
      8               (select XMLAgg(
      9                          XMLElement("emp",
    10                             XMLAttributes(
    11                                e.EMPNO as "empno",
    12                                e.DEPTNO as "deptno"
    13                             ),
    14                             XMLElement("ename", e.ENAME),
    15                             XMLElement("job", e.JOB),
    16                             XMLElement("salary", e.SAL),
    17                             XMLElement("hiredate", to_char(e.HIREDATE, 'YYYY-MM-DD'))
    18                          )
    19                       order by e.EMPNO
    20                       )
    21                from   SCOTT.EMP e
    22               )
    23            )
    24         ) as XML_DOC
    25  from   DUAL
    26  /
    View created.
    SQL>
    SQL> insert into TEST_XML
      2  (
      3    XML_SEQ,
      4    XML_DOC
      5  )
      6  select TEST_XML_SEQ.NEXTVAL,
      7         XMLType(v.XML_DOC, NULL, 1, 1)
      8  from   V_EMP_XML v
      9  /
    1 row created.
    SQL> select t.XML_DOC.getClobVal() as RESULT
      2  from   TEST_XML t
      3  where  t.XML_SEQ = 1
      4  /
    RESULT
    <?xml version="1.0" encoding="ISO-8859-1"?><!DOCTYPE employees SYSTEM "http://my
    SQL> select extract(t.XML_DOC, '//emp[@deptno=20]').getClobVal() as RESULT
      2  from   TEST_XML t
      3  where  t.XML_SEQ = 1
      4  /
    ERROR:
    ORA-31011: XML parsing failed
    ORA-19202: Error occurred in XML processing
    LPX-00202: could not open "http://myserver/dtd/employees.dtd" (error 101)
    Error at line 1
    no rows selected
    SQL> alter session set events ='31156 trace name context forever, level 2'
      2  /
    Session altered.
    SQL> select extract(t.XML_DOC, '//emp[@deptno=20]').getClobVal() as RESULT
      2  from   TEST_XML t
      3  where  t.XML_SEQ = 1
      4  /
    RESULT
    <emp empno="7369" deptno="20"><ename>SMITH</ename><job>CLERK</job><salary>800</s
    SQL>

  • ERROR - JBO-25005: Object name  for type View Object is invalid

    Hi All,
    I am getting this error "JBO-25005: Object name for type View Object is invalid" while executing my VO query in Controller code. Can any one please tell me the reason behind this error?
    I am creating a VO dynamically and .xml file of a VO is placed in a proper directly. Please let me know some inputs to resolve this.
    Thanks & Regards,
    -Abm

    I found the below explanation for the error mentioned. Check if your package name, Object names confirm to the standard specified
    JBO-25005: InvalidObjNameException
    Cause: An attempt has been made to associate a business component name with an object for which it is not valid.
    Action: The name should be a valid Java identifier with no spaces or punctuation. Names are of the format myProjectPackage.BusinessPackage.BusinessComponent

  • Suppress XML Structure view

    Hi,
          May  I know the SuppressedWidgetID to hide the XML structure view?
    IsStructureViewShowing=kFalse;
    I need to hide XML Structure view.
    Kindly advise me.
    Regards
    Senthil Kumar V

    Ok lets start from basics
    go to CN41 and enter a project with std PS info profile 000000000000001
    if you click o the DB profile you will have basic setting 000000000000001 etc
    this gives us the project structure
    Now in transaction OPUR create a view for PC hierarchy
    Z00000000001 - whatever description
    select PS hier type 2 - Profit Ctr via set
    I think you have done this
    In this configuration there is a group name - you need to enter the profit centre hierarchy group name from your system
    this group must exist in your system check using transaction KCH3 to display group - if this is not entered correctly you will get the exact error you have got - I have been able to replicate in my system
    Now run CN41 change DB profile project view from 00000000001 to Z0000000001

  • JBO-25002: Definition ...of type View Definition is not found

    Hello,
    I am using JDev 11.1.1.4.0.
    I am having a problem creating read only VO, actually running on integrated weblogic server after creating one. I am getting this exception:
    oracle.jbo.NoDefException: JBO-25002: Definition com.model.viewobject.OrderLineStatusVVO of type View Definition is not found.
         at oracle.jbo.mom.DefinitionManager.findDefinitionObject(DefinitionManager.java:577)
         at oracle.jbo.mom.DefinitionManager.findDefinitionObject(DefinitionManager.java:484)
         at oracle.jbo.mom.DefinitionManager.findDefinitionObject(DefinitionManager.java:466)
    I created this VO using very simple sql statement, "SELECT ORDER_LINE_STATUS FROM ORDER". JDev creates it and the AM has it listed fine. But when running, I get the above exception.
    Many thanks in advance for your help.
    Bones Jones
    Edited by: Bones Jones on May 10, 2012 10:09 AM

    Fixed it somehow, sort of...
    It turned out my OrderLineStatusVVO.xml was not being deployed in the server. The server being integrated weblogic server, I had to dig it up a bit. The other VO xml files were present in the following folder:
    C:\Users\[USERACCOUNT]\AppData\Roaming\JDeveloper\system11.1.1.4.37.59.23\o.j2ee\drs\[MYAPP]\ViewControllerWebApp.war\WEB-INF\Classes\com\model\viewobject
    For some reason OrderLineStatusVVO.xml was not present. So I did what most of the top developers to, copy and paste. After that I am able to run the app.
    Thank you so much for your help!
    Bones Jones

  • Problem while querying a XML type

    I have created a view to access the content of a XML type in 10g.This view works on my PC.But when the same tried on server it gives the following error...
    select * from aw33_view
    ERROR at line 1:
    ORA-04031: unable to allocate 1000 bytes of shared memory ("large pool","unknown object","qmxlu subheap","qmemNextBuf:alloc")
    HELP IS NEEDED urgently...

    Can any1 help me in this prob...

  • How to create an XQuery for an XML type data source

    Hi,
    1.I have data contained in an XML format.
    Hence I have created a physical data source for XML type data.
    2.I have created a logical view to broker data from several disparate physical data sources.I have called this as UnifiedView.
    3.I have created a function called getUnifiedView() to obtain data from all the physical sources
    4.Upto this point, I have not faced any problems.
    5.However when i try writing a simple XQuery for the physical XML datasource such as
    $Sh-data/PublicIdentifiers/MSISDN="1234567"
    I get result as (For example):
    <HSS>
    <MSISDN> 1234567 111111 222222 </MSISDN>
    </HSS>
    Could you please help me getting the where clause output?
    I have attached the schema and XML files used for further information.
    Regards
    Vidya

    Hi mReiche,
    I later on resolved the previously mentioned error and try out the XQuery as suggested by you.
    for $MSISDN in ns0:Sh-data()/PublicIdentifiers/MSISDN
    where $MSISDN="1234567"
    return
    <HSS>
    <MSISDN>{data($MSISDN)}</MSISDN>
    </HSS>
    It works! Thanks.
    Now i am trying to retrieve data from 2 XML documents and an LDAP query.
    I have the following data sources:
    1.LDAP queried by Java Function
    2.HSS xml
    3.Presence xml
    I want to match the telephoneNumber of the LDAP with MSISDN in the HSS.xml.
    Next i want to match the SIP_URI in the HSS.xml with Contact of the Presence.xml
    Given below is the XQuery which i have written to achieve the above:
    for $x0 in ns5:FindDN($str_mailId)
    for $Sh-Data in ns2:Sh-Data()
    where $x0 = $Sh-Data/PublicIdentifiers/MSISDN
    for $presence in ns3:presence()
    where $Sh-Data/Sh-IMS-Data/SCSCFName = $presence/ns4:tuple/ns4:contact
    return
    On executing this XQuery i am getting the following error:
    java.lang.NullPointerException: null
         at weblogic.xml.query.types.XQueryAtomicType.commonSuperTypeOf(XQueryAtomicType.java:150)
         at weblogic.xml.query.types.XQueryType.comparisonTypeOf(XQueryType.java:324)
         at weblogic.xml.query.runtime.compare.GeneralAtomicComparison.compare(GeneralAtomicComparison.java:50)
         at weblogic.xml.query.runtime.compare.ComparisonIterator.fetchNext(ComparisonIterator.java:50)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.logic.BoolEffValue.exec(BoolEffValue.java:51)
         at weblogic.xml.query.runtime.logic.BoolEffValue.fetchNext(BoolEffValue.java:47)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.IfThenElse.fetchNext(IfThenElse.java:79)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.CountMapIterator.fetchNext(CountMapIterator.java:162)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.CountMapIterator.fetchNext(CountMapIterator.java:162)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.sequences.Exists.fetchNext(Exists.java:40)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.IfThenElse.fetchNext(IfThenElse.java:79)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.LetIterator.fetchNext(LetIterator.java:133)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.LetIterator.fetchNext(LetIterator.java:133)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.querycide.QueryAssassin.fetchNext(QueryAssassin.java:54)
         at weblogic.xml.query.iterators.GenericIterator.peekNext(GenericIterator.java:151)
         at weblogic.xml.query.runtime.qname.InsertNamespaces.fetchNext(InsertNamespaces.java:161)
         at weblogic.xml.query.iterators.GenericIterator.next(GenericIterator.java:113)
         at weblogic.xml.query.runtime.core.QueryIterator.fetchNext(QueryIterator.java:127)
         at weblogic.xml.query.iterators.GenericIterator.hasNext(GenericIterator.java:134)
         at weblogic.xml.query.xdbc.util.Serializer.serializeItems(Serializer.java:142)
         at com.bea.ld.server.QueryInvocation.getResult(QueryInvocation.java:461)
         at com.bea.ld.EJBRequestHandler.executeFunction(EJBRequestHandler.java:346)
         at com.bea.ld.ServerBean.executeFunction(ServerBean.java:108)
    Please find attached the XML documents which i am using.
    Could you pls let me know how to resolve this.

  • Reporting Services web service complex xml type report parameters

    Hi,
    I have the following xml type parameter in my request query that I use in reporting services.
    <Parameter Name="accountDetails" Type="XML" xmlns:d4p1="thevalue" xmlns:i="thevalue">
    <DefaultValue>
    <d4p1:AccountDetailDto>
    <d4p1:AccountNumber>12345</d4p1:AccountNumber>
    <d4p1:AccountType>Sales</d4p1:AccountType>
    </d4p1:AccountDetailDto>
    </DefaultValue>
    I want to know how I can assign values to the accountDetails parameter from report parameters, I've tried to call it from the dataset parameter properties but it doesn't return any values. I created Parameters!accountDetails.Value on the dataset parameters
    properties and assigned it the following value: it only returns empty columns
    ="<AccountDetailDto><AccountNumber>"& Parameters!AccountNumber.Value &"</AccountNumber><AccountType>"& Parameters!AccountType.Value &"</AccountType></AccountDetailDto>"
    You're help will be highly appreciated as I've been trying to solve this for a while now

    Hi Alisa,
    Perhaps I should explain my problem clearly...
    This is my query request that I send to the webservice:
    <Query>
    <Method Name="GetPerAccountAssetAllocation" Namespace="http://tempuri.org/">
    <Parameters>
    <Parameter Name="accountDetails" Type="XML" xmlns:d4p1="thevalue" xmlns:i="thevalue">
    <DefaultValue>
    <d4p1:AccountDetailDto>
    <d4p1:AccountNumber>12345</d4p1:AccountNumber>
    <d4p1:AccountType>JSE</d4p1:AccountType>
    </d4p1:AccountDetailDto>
    </DefaultValue>
    </Parameter>
    </Parameters>
    </Method>
    <SoapAction>http://tempuri.org/IPortfolioManagementService/GetPerAccountAssetAllocation</SoapAction>
    <ElementPath IgnoreNamespaces="true">*</ElementPath>
    </Query>
    It works well when I run it just like this, that is without specifying any parameters in the report data dialogue window or on the dataset parameters properties, it returns the values and columns correctly.
    So my problem is, I need to find out how(xml parameter syntax, steps e.t.c)
    I can do to allow users to specify the accountDetails parameter, its quite tricky for me coz its an xml type parameter, Im not sure if I should just specify the AccountNumber and
    ReportType parameters separately:
    I've tried the following without any success:
    1. Under the dataset properties:  I tried not to specify a default value for the accountDetails parameter on the xml query, then I added a parameter called "accountDetails" under the dataset parameters properties, then under parameter
    value I added the following xml value :
    <d4p1:AccountDetailDto>
    <d4p1:AccountNumber>Parameters!AccountNumber.Value</d4p1:AccountNumber>
    <d4p1:AccountType>Parameters!AccountType.Value</d4p1:AccountType>
    </d4p1:AccountDetailDto> 
    (I also added the AccountNumber and AccountType parameters under the report data dialogue window)
    This returns empty columns, is there something I'm missing, or am I doing this incorrectly?

  • Custom action with XML type input and output parameter.

    Hi,
    I want to develop custom action with xml type input and/or output parameter.
    Is there sample code for java side. How is the definition of input and/or output parameter and set/get methods?
    does it need special .jar file to develop custom action like this?
    Thanks.

    Cemil - yes, you can use XML data types.  Use the class
    com.sap.lhcommon.xml.XMLDataType
    for your parameter type.  Here is a snippet from a custom action we use to log XML (instead of just returning the #text node like the default logger does):
    public class XMLLogger extends ActionReflectionBase
        private String source;
        private String eventType;
        private String textMessage;
        private XMLDataType xmlMessage;
        public XMLLogger()
            log = new Logger("UserLog");
            source = DEFAULT_SOURCE;
            eventType = TYPE_INFO;
            textMessage = "";
            xmlMessage = new XMLDataType();
        public XMLDataType getXmlMessage()
            return xmlMessage;
        public void setXmlMessage(XMLDataType xmlMessage)
            this.xmlMessage = xmlMessage;
        public void Invoke(Transaction transaction, ILog ilog)
            StringBuffer sb = new StringBuffer();
            sb.append('[');
            sb.append(source);
            sb.append("] ");
            sb.append(textMessage);
            sb.append(XMLUtils.convertXmlToString(xmlMessage));
    XMLUtils is a helper class we wrote - it's just a bunch of standard Java XML boilerplate code.  The important part you need to know is XMLDataType.getDocument() will return an org.w3c.dom.Document.
    I hope that was enough information to help.
    -tim

  • (updating xml value)adding an element in an xml type column

    Hi all,
    i hava a table that contains an xml-Type column (non schema based)
    i have inserted some data in it
    table:(id,xmlcolumn)
    ex:
    insert into t1 values(1,'<Chapters>
    <Chapter>ch1<Chapter>
    <Chapter>ch2<Chapter>
    </Chapters>')
    i need to add a new Chapter: <Chapter>ch3</Chapter>
    for the result of xml instance in the table to be:
    <Chapters>
    <Chapter>ch1<Chapter>
    <Chapter>ch2<Chapter>
    <Chapter>ch3<Chapter>
    </Chapters>
    plz if any one colud help

    SQL> DECLARE
      2      l_xml      XMLTYPE := XMLTYPE('<Chapters>
      3  <Chapter>ch1</Chapter>
      4  <Chapter>ch2</Chapter>
      5  </Chapters>');
      6      l_xsl      XMLTYPE;
      7      l_new_node VARCHAR2(100) := '<Chapter>ch3</Chapter>';
      8  BEGIN
      9      dbms_output.put_line('Before adding node:');
    10      dbms_output.put_line('----------------------------------------------------------------');
    11      dbms_output.put_line(l_xml.getStringVal());
    12      dbms_output.put_line('----------------------------------------------------------------');
    13      l_xsl := XMLTYPE('<?xml version="1.0"?>' ||
    14                       '<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"' ||
    15                       ' version="1.0"' || ' result-ns=""' || ' indent="no">' ||
    16                       '<xsl:output method="xml" media-type="text/xml" indent="no"/>' ||
    17                       '<xsl:template match="/">' ||
    18                           '<' ||l_xml.getRootElement() || '>' ||
    19                               ' <xsl:for-each select="/' || l_xml.getRootElement() ||'/Chapter">' ||
    20                                   '<xsl:copy-of select="." />' ||
    21                               '</xsl:for-each>' ||
    22                               l_new_node ||
    23                           '</' || l_xml.getRootElement() || '>' ||
    24                       '</xsl:template>' ||
    25                       '</xsl:stylesheet>');
    26      l_xml := l_xml.Transform(l_xsl);
    27      dbms_output.put_line('After adding node:');
    28      dbms_output.put_line('----------------------------------------------------------------');
    29      dbms_output.put_line(l_xml.getStringVal());
    30      dbms_output.put_line('----------------------------------------------------------------');
    31  END;
    32  /
    Before adding node:
    <Chapters>
    <Chapter>ch1</Chapter>
    <Chapter>ch2</Chapter>
    </Chapters>
    After adding node:
    <Chapters>
      <Chapter>ch1</Chapter>
      <Chapter>ch2</Chapter>
      <Chapter>ch3</Chapter>
    </Chapters>
    PL/SQL procedure successfully completed.
    SQL>

  • ORA-19007 when coping a table with an xml type in it to a new schema in the

    ORA-19007 when coping a table with an xml type in it to a new schema in the same database.
    Hi all,
    When I copy a table with an xml type in it to a new schema in the same database I get an ora-19009.
    The setup is as follows I have a schema a with table TABLE_WITH_XMLTYPE where data is:
    CREATE
    TABLE TABLE_WITH_XMLTYPE
    FOLDER_ID NUMBER (10, 0) NOT NULL,
    SEARCH_PROPERTIES XMLTYPE ,
    CONSTRAINT TABLE_WITH_XMLTYPE PK PRIMARY KEY (FOLDERID) USING INDEX
    XMLTYPE COLUMN SEARCH_PROPERTIES XMLSCHEMA
    "http://xxxxxxx.net/FolderProperties.xsd" element "FolderProperties"
    VARRAY SEARCH_PROPERTIES."XMLDATA"."PROPERTIES"."PROPERTY" STORE AS TABLE
    PROPERTY_TABLE
    (PRIMARY KEY (NESTED_TABLE_ID, ARRAY_INDEX)) ORGANIZATION INDEX OVERFLOW
    Both schemas have the following xml schema registered as a local xml schema
    BEGIN
    DBMS_XMLSCHEMA.registerSchema(
    SCHEMAURL => 'http://xxxxxxx.net/FolderProperties.xsd',
    SCHEMADOC =>
    '<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
    xmlns:xdb="http://xmlns.oracle.com/xdb"
    xdb:storeVarrayAsTable="true">
    <xs:element name="FolderProperties"
    type="FolderPropertiesType"
    xdb:defaultTable="FOLDER_SEARCH_PROPERTIES" />
    <xs:complexType name="FolderPropertiesType" xdb:SQLType="FOLDERPROPERTIES_T">
    <xs:sequence>
    <xs:element name="FolderID" type="FolderIDType" minOccurs="1" xdb:SQLName="FOLDER_ID"/>
    <xs:element name="Properties" type="PropertiesType" xdb:SQLName="PROPERTIES"/>
    </xs:sequence>
    </xs:complexType>
    <xs:complexType name="PropertiesType" xdb:SQLType="PROPERTIES_T">
    <xs:sequence>
    <xs:element name="Property" type="PropertyType" maxOccurs="unbounded"
    xdb:SQLName="PROPERTY" xdb:SQLCollType="PROPERTY_V"/>
    </xs:sequence>
    </xs:complexType>
    <xs:complexType name="PropertyType" xdb:SQLType="PROPERTY_T">
    <xs:sequence>
    <xs:element name="DateValue" type="DateType" xdb:SQLName="DATE_VALUE"/>
    <xs:element name="NumValue" type="NumType" xdb:SQLName="NUM_VALUE"/>
    <xs:element name="StringValue" type="StringType" xdb:SQLName="STRING_VALUE"/>
    </xs:sequence>
    <xs:attribute name="Name" xdb:SQLName="NAME" xdb:SQLType="VARCHAR2">
    <xs:simpleType>
    <xs:restriction base="xs:string">
    <xs:minLength value="1"/>
    <xs:maxLength value="255"/>
    </xs:restriction>
    </xs:simpleType>
    </xs:attribute>
    </xs:complexType>
    <xs:simpleType name="FolderIDType">
    <xs:restriction base="xs:integer"/>
    </xs:simpleType>
    <xs:simpleType name="DateType">
    <xs:restriction base="xs:dateTime"/>
    </xs:simpleType>
    <xs:simpleType name="NumType">
    <xs:restriction base="xs:decimal"/>
    </xs:simpleType>
    <xs:simpleType name="StringType">
    <xs:restriction base="xs:string" />
    </xs:simpleType>
    </xs:schema>',
    LOCAL => TRUE,
    GENTYPES => TRUE,
    GENTABLES => FALSE);
    END;
    when I try to do the following insert:
    insert into schemaB.TABLE_WITH_XMLTYPE ( FOLDER_ID, SEARCH_PROPERTIES)
    select FOLDER_ID, SEARCH_PROPERTIES from schemaB.TABLE_WITH_XMLTYPE;
    I’ll get an ora-19007.
    Can some one point me in the right direction how to solve this error.
    Thanks Roelof.

    Who did you create the second table, in other words, how did you COPY the table as you said...
    If you created the second table via a CTAS (create table as select) then you will have created a table that is not the same as the original one. AFAIK I have once created an enhancement request for this after discovering that JDeveloper, for example, creates a "copy" via a CTAS which creates the wrong structure. Double check via package DBMS_METADATA.
    SQL> set long 1000000
    SQL> select DBMS_METADATA('TABLE','TABLE_WITH_XMLTYPE','SchemaA') from dual;
    SQL> select DBMS_METADATA('TABLE','TABLE_WITH_XMLTYPE','SchemaB') from dual;If you have got two different tables, than Mark's solution should help.
    M.
    Edited by: Marco Gralike on Feb 15, 2009 11:16 AM

  • Help  needed  in inserting  into column  of XML type

    i have requirement of inserting data into column of xml type
    eg
    cust product cost
    1 a 3
    1 b 7
    1 c 5
    now required result should
    <PROD-LIST>
    <a>3</a>
    <b>7</b>
    <c>5</c>
    </PROD-LIST>
    Please let me know how to achieve this , i was trying write function , it was working for one values ,but how to do if many values exist .

    Take a deep breath, then retype this putting in all the words and punctuation you missed out the first time until it makes sense.
    Your sample data, for example, could be better formatted using the [pre] and [/pre] tags to preserve formatting and put in a table format. Similarly with your output. Why are two of the numbers floating around freely in your xml but the 3rd isn't?

  • Inserting a row in a schema-based xml type column

    i have problems while inserting a row in a schema-based xml type column
    it reports an error(schema and elemnt do not match)
    although they are matching if anyone can try it
    and if it worked plz send me the example

    SQL> DESC XML_TAB;
    Name Null? Type
    XML XMLTYPE
    SQL> INSERT INTO XML_TAB
    2 VALUES
    3 (xmltype('<request>
    4 <filter>(extshortname=bhagat)</filter>
    5 <attributes>dn</attributes>
    6 <context/>
    7 <scope>subtree</scope>
    8 </request>'));
    1 row created.
    If your problem persists,post ur lines of code..
    Good luck!!!
    Bhagat

  • Binding ADF UI to a complex XML Type – Development Productivity, State Mgmt

    Binding ADF UI to a complex Web Service – Development Productivity, Managing State, Etc.
    For those scenarios when ADF UI has to be bound to a complex XML type, it seems that the direction taken by the ADF development team was to generate data-controls that map to complex XML types.
    The major problem with this approach is the fact that application server does not manage state. For example, If application has to submit a purchase order to a web service then application server has to manage the shopping card state until its ready to be submitted.
    In some previous forum threads it had been suggested that using generated data-controls is a “quick and dirty” solution for accessing web services and that a proper solution is to use generated Java Proxy Interface.
    That implies many manually constructed entity objects, associations and overridden doDML methods, which is far less productive compared to entity objects generated from a database schema.
    Suggestion and a Question for the ADF development team
    From the logical model standpoint, there is no difference in between the XML schema and DB schema. Therefore, it is possible to generate entity objects and associations for XML Types of XML schema the same way it’s done for tables of Database schema. The only difference is serialization of CRUD operations on entity objects.
    One way to handle this is:
    -     Generate Application Module for a complex XML type. This application module should have methods for marshaling to/from corresponding XML type.
    -     Generate entity object for each subtype within the complex XML type. In case of nested subtypes, generate association to a parent type.
    -     Generate data control with actions that are bound to web service operations and code that serializes request message from corresponding AM and de-serializes response message to corresponding AM.
    This way, ADF would offer the same productivity for the SOA development as one its currently offering for the ORM development.
    Until the time when something like this is available, what would be the best approach for binding ADF UI to web services?
    Feedback is greatly appreciated.
    Boro Petrovic
    Edited by: wds12518 on Jan 25, 2010 11:49 AM

    We have similar issues as our big portion of the UI is based on WS. We found that there is no easy way to map entity object structure to complex XML type (one EO can based on one flat type or domain can't be bound to UI directly). Oracle PMs, is there any better solution or future plans to address this issue?

Maybe you are looking for

  • Error in the following code.need help asap

    hi i have written a block which bulk collects into a pl/sql table. Getting an error as shown below. PLz help asap declare type summary_upd_tab is table of summary%rowtype; summary_upd_var summary_upd_tab; begin select min(a.start_time_utc), max(a.end

  • DPS Issue: You do not have a compatible Digital Publishing Plug-in.

    Issue:  I have recently upgraded to inDesign 5.5 specifically to use the new DPS tools. I've download the DP tools (v.1.0) that you are directed to online as well as version 1.1.3 of the folio builder panel. Still, I recieve the following error: You

  • Using the electronic filing feature in federal court safari will not allow me to upload my documents for filing

    I am an attorney and required to efile my documents in the federal court. Up to about 3 weeks ago I was able but now safari won't let me upload my word docs to file them.  I was told that I have to go to the settings option and uncheck where it says

  • Uneven line spacing

    In the document I'm creating there are some paragraphs where the line spacing on the screen and printed page are uneven ... for example, the white space between line 2 and line 3 is wider than the space between any other lines in the same paragraph.

  • Reg :: Concurrent manager is not coming up

    Hi Folks, The CM is not coming up .Below is some points. 1. adcmctl.sh start apps/pwd adcmctl.sh: exiting with status 0 But stil it is dowm 2 .i stopped and started but no use. 3.DB - 10.2.0.2.0 EBS -11.5.10.2 Kindly advice to do some other way to br