How to use "sys.XMLTYPE.getClobVal( )"?

Hi all
Can any one explain me
SELECT * FROM (
SELECT
A.CID CID,
A.USERID USERID,
A.SCORE SCORE,
A.RESULT RESULT,
A.ANNOTATION ANNO,
SYS.XMLTYPE.GETCLOBVAL(A.XML) TRANSACTIONINFO,
SYS.XMLTYPE.GETCLOBVAL(B.ATTRIB) CUSTOMERINFO,
ROW_NUMBER() OVER (ORDER BY B.FRAUD_ID DESC) RN
FROM
GENERALFRAUDLOG A LEFT JOIN FRAUDCUSTOMERS B
ON
A.CID=B.CID
WHERE A.FRAUDID=674003)
WHERE RN=1
How we can use this query exactly in Oracle Html Db
Thanks&Regards
Suresh

wt suresh wt do u want cud u com my wsI think your vowel keys on your keyboard are a bit stuck. Time for a new keyboard perhaps?
cud u com my wsAnd that part of it just sounds perverted. :o\

Similar Messages

  • ORA-21700 error using sys.xmlType in Oracle 9.2

    I'm working on an application which uses the XMLType column in some of its database tables. When we started, we were using Oracle 9.0.1, and this test code works (which emulates how we have to, in some occasions, populate the XMLType column).
    However, we installed Oracle 9.2.0.3 on the same machine and created database instances using this version of Oracle. We didn't upgrade the original 9.0.1 installation (which still exists side-by-side). When we run this code, we get the following exception...
    java.sql.SQLException: ORA-21700: object does not exist or is marked for delete
    ORA-06512: at "SYS.XMLTYPE", line 0
    ORA-06512: at line 1
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:180)
    at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:208)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:543)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1451)
    at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:862)
    at oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:1846)
    at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1771)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2361)
    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:422)
    at com.edh.oracle.TransactionTester.testClob(TransactionTester.java:134)
    at com.edh.oracle.TransactionTester.main(TransactionTester.java:251)
    This exception occurs after we've written the data to a Clob and are attempting to call createXML to update the column.
    Is there anything additional I need to do to get this working in Oracle 9.2 again? Thanks.
    Code is:
    * TransactionTester.java
    * Created on 11 October 2002, 14:08
    package com.edh.oracle;
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.SQLException;
    import java.sql.Statement;
    import java.sql.PreparedStatement;
    import java.sql.ResultSet;
    * @author ehillman
    public class TransactionTester {
    private static String ORACLE_URL = "jdbc:oracle:thin:@wallaby:7012:CT2";
    /** Creates a new instance of TransactionTester */
    public TransactionTester() throws SQLException {
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    private void createTables(Connection conn) throws SQLException {
    String createText = "create table SillyData (XML_VALUE XMLTYPE, XML_STORAGE CLOB)";
    Statement stmt = conn.createStatement();
    stmt.execute(createText);
    System.out.println("Tables created");
    private void dropTables(Connection conn) throws SQLException {
    String dropText = "drop table SillyData ";
    Statement stmt = conn.createStatement();
    stmt.execute(dropText);
    System.out.println("Tables dropped");
    private void testClob() throws SQLException, java.io.FileNotFoundException,
    java.io.IOException {
    System.out.println("testClob - START");
    Connection conn = DriverManager.getConnection(ORACLE_URL,
    "ehillman", "ehillman");
    System.out.println("connection received");
    createTables(conn);
    try {
    System.out.println("Loading MyFn.xml");
    java.io.FileReader inputReader = new java.io.FileReader(
    "C:\\Documents and Settings\\ehillman\\.netbeans\\edh test\\oracle jdbc\\com\\edh\\oracle\\MyFn.xml");
    conn.setAutoCommit(false);
    Statement stmt2 = conn.createStatement();
    stmt2.execute("insert into SillyData (XML_STORAGE) values (EMPTY_CLOB())");
    System.out.println("empty row inserted");
    stmt2 = conn.createStatement();
    ResultSet rs = stmt2.executeQuery("select XML_STORAGE from SillyData for update");
    System.out.println("Empty CLOB retireved");
    rs.next();
    java.sql.Clob clobValue = rs.getClob(1);
    oracle.sql.CLOB oraClob = (oracle.sql.CLOB) clobValue;
    System.out.println("casted");
    java.io.Writer writer = oraClob.getCharacterOutputStream();
    char[] buffer = new char[ oraClob.getChunkSize() ];
    for (int charsRead = inputReader.read(buffer); charsRead > -1; charsRead = inputReader.read(buffer)) {
    writer.write(buffer, 0, charsRead);
    writer.close();
    System.out.println("data written to Clob");
    PreparedStatement pState = conn.prepareStatement(
    "update SillyData set XML_VALUE = sys.XMLType.createXML(?)");
    pState.setClob(1, clobValue);
    int result = pState.executeUpdate();
    System.out.println("executeQuery returned " + result);
    } finally {
    dropTables(conn);
    conn.close();
    System.out.println("connection closed");
    System.out.println("testClob - END");
    * @param args the command line arguments
    public static void main(String[] args) {
    try {
    TransactionTester tst = new TransactionTester();
    tst.testClob();
    } catch (Exception ex) {
    ex.printStackTrace();

    I've found this....
    http://download-west.oracle.com/docs/cd/B10501_01/appdev.920/a96620/xdb05obj.htm#1032058
    Does this mean that, for a table to use an XMLType column, it has to have a single schema definition for every row in the table?
    This won't fit for what we're doing.... that is, our table stores XML data for each row, but they are all different types of XML... they don't have the same structure,they don't use the same schema.
    Please let me know if I'm missing something

  • Any tips for debugging apply handlers? How to use SYS.AnyData

    Well, I'm setting up my first stream.
    I've set up a simple stream just to understand the concepts, but now I need to start the real work.
    I've written an apply handler that takes the LCR, turns pulls values from the sys.AnyData, and uses them in another statement. I have excerpts from it below-- I've not used a SYS.AnyData before, and I'm not sure if I've set the conversion up correctly:
    CREATE OR REPLACE PROCEDURE reg_data_handler(in_any IN SYS.AnyData)
    RETURN SYS.AnyData
    IS
         lcr     SYS.LCR$_ROW_RECORD;
         lcr_anydata SYS.AnyData;
         -- Should I declare like this
    -- or should I make it a Number for
    -- the SYS.AnyData conversion?
         -- TYPE is really a NUMBER(11)
    samp_time nh_rlp_stats.sample_time%TYPE;
    BEGIN
    -- Access the LCR
    rc := in_any.GETOBJECT(lcr);
    -- Get the object command type
    command := lcr.GET_COMMAND_TYPE();
    IF command = 'INSERT' THEN
    -- get the needed data
    lcr_anydata := lcr.GET_VALUE('new','SAMPLE_TIME');
    rc := lcr_anydata.get_number(samp_time);
    Does anyone have any tips on how to do the debugging as painlessly as possible? I've tested as much of the individual units as possible, but in order to test the code that pulls from the LCR, it seems like I'll need to hook it into the steam and hope for useful dbms_output statements. Other ideas?
    Thanks very much.
    Robin T

    Actually, I have read the supplied list a couple of times over. There is a difference between reading and doing, particularly as documentation can be mis-interpreted or miss key items. I supplied the code snippets in case some one could see that I was mis-reading the info.
    My particular concern is with debugging: are there any tips people have learnt to make the process easier? If I just hook the handler into a stream and test it that way, I suspect that it might take some time to shake the kinks out. However, it occurred to me this morning that maybe I can fake out the LCR by constructing one of my own in a wrapper procedure and calling the handler within that. So, I'll see if that speeds up the process.
    Thanks very much for your reply.

  • How to use sys date

    I am trying to write a simple query where datelet > 12/31/2004 and datelet < today's date. datelet is a date field. thanks
    select datelet from bidlet
    where datelet > to_date(12/31/2004,'MM/DD/YYYY') and datelet < (today's date))

    thanks for the reply.I am getting this error msg.
    ORA-01858: a non-numeric character was found where a
    numeric was expected
    select datelet from bidlet where datelet >
    to_date('12/31/2004','MM/DD/YYYY') and datelet <
    trunc(sysdate)missing quotes
    '12/31/2004'

  • How do I access XMLType using JDBC ?

    This thread will address a number of issues related to accessing XMLType tables and columns from Java via JDBC.

    The following code shows examples of accessing XMLType using Java getting an instance of W3C DOM interface org.w3c.dom.Document. It also shows how which DOM implementation is returned by the getDOM() method is dependant on whether or not the OCI driver or Thin Dirver is in used.
    The code also show how to use the createNonSchemaBasedXMLType() method to access a schema based XMlLType via the thin driver...
    public class GetXMLTypeDOM extends BaseApplication
       protected String driverType;
       protected String getDriver() {
         return this.driverType;
       public void doSomething(String[] Args) throws Exception
         OraclePreparedStatement  statement = null;
         this.driverType = this.OCI_DRIVER;
         this.initializeConnection();
         statement = (OraclePreparedStatement) getConnection().prepareStatement("select object_value from PURCHASEORDER_NSB_XMLTYPE where rownum < 2");
         getDocument(statement);
         statement = (OraclePreparedStatement) getConnection().prepareStatement("select object_value from PURCHASEORDER_SB_XMLTYPE where rownum < 2");
         getDocument(statement);
         getConnection().close();
         this.driverType = this.THIN_DRIVER;
         this.initializeConnection();
         statement = (OraclePreparedStatement) getConnection().prepareStatement("select object_value from PURCHASEORDER_NSB_XMLTYPE where rownum < 2");
         getDocument(statement);
         statement = (OraclePreparedStatement) getConnection().prepareStatement("select object_value from PURCHASEORDER_SB_XMLTYPE where rownum < 2");
         getDocument(statement);
         statement = (OraclePreparedStatement) getConnection().prepareStatement("select x.object_value.createNonSchemaBasedXML() from PURCHASEORDER_SB_XMLTYPE x where rownum < 2");
         getDocument(statement);
         getConnection().close();
       private void getDocument(OraclePreparedStatement statement)
         OracleResultSet resultSet = null;
         org.w3c.dom.Document  doc = null;
         XMLType xml = null;
         try {
           resultSet = (OracleResultSet) statement.executeQuery();
           while (resultSet.next())
              xml = (XMLType) resultSet.getObject(1);
              doc = xml.getDOM();
              System.out.println("DOM Implementation is " + doc.getClass().getName());
              xml.close();
           resultSet.close();
           statement.close();
        catch (SQLException sqle) {
            System.out.println("Caught SQL Exception : " + sqle.getMessage());
      public static void main (String[] args)
        try
          GetXMLTypeDOM example = new GetXMLTypeDOM();
          example.doSomething(args);
        catch (Exception e)
          e.printStackTrace();
    }Here's the output from running this class..
    C:\TEMP>
    C:\Oracle\JDeveloper\jdk\bin\javaw.exe -client -classpath C:\xdb\JDeveloper\Classes;C:\Oracle\product\10.2.0\db_1\jdbc\lib\ojdbc14.jar;C:\Oracle\product\10.2.0\db_1\LIB\xmlparserv2.jar;C:\Oracle\product\10.2.0\db_1\RDBMS\jlib\xdb.jar;C:\xdb\JDeveloper\jakarta-slide-webdavclient-bin-2.1\lib\jakarta-slide-webdavlib-2.1.jar;C:\xdb\JDeveloper\jakarta-slide-webdavclient-bin-2.1\lib\commons-httpclient.jar;C:\xdb\JDeveloper\jakarta-slide-webdavclient-bin-2.1\lib\commons-logging.jar;C:\xdb\JDeveloper\jakarta-slide-webdavclient-bin-2.1\lib\jdom-1.0.jar -Dcom.oracle.st.xmldb.pm.ConnectionParameters=C:\\xdb\\jdeveloper\\SimpleExamples\\LocalConnection.xml -Dhttp.proxyHost=www-proxy.us.oracle.com -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts=192.168.0.77|localhost|192.168.1.1|*.oracle.com|*.us.oracle.com -Dhttps.proxyHost=www-proxy.us.oracle.com -Dhttps.proxyPort=80 -Dhttps.nonProxyHosts=192.168.0.77|localhost|192.168.1.1|*.oracle.com|*.us.oracle.com com.oracle.st.xmldb.pm.examples.GetXMLTypeDOM -mx2048M
    ConnectionProvider.establishConnection(): Connecting as SCOTT/TIGER@jdbc:oracle:oci8:@(description=(address=(host=localhost)(protocol=tcp)(port=1521))(connect_data=(service_name=ORA10GR2.xp.mark.drake.oracle.com)(server=DEDICATED)))
    ConnectionProvider.establishConnection(): Database Connection Established
    DOM Implementation is oracle.xdb.dom.XDBDocument
    DOM Implementation is oracle.xdb.dom.XDBDocument
    ConnectionProvider.establishConnection(): Connecting as SCOTT/TIGER@jdbc:oracle:thin:@localhost:1521:ORA10GR2
    ConnectionProvider.establishConnection(): Database Connection Established
    DOM Implementation is oracle.xml.parser.v2.XMLDocument
    Caught SQL Exception : Only LOB or String Storage is supported in Thin XMLType
    DOM Implementation is oracle.xml.parser.v2.XMLDocument
    Process exited with exit code 0.

  • How to find SQL Statement fired using SYS.AUD$ - Database Auditing

    Dear Friends
    I am having Oracle 9i Database and have configured it with database auditing option by setting the following parameter in init.ora file
    AUDIT_TRAIL = "DB"
    I want to audit SELECT, INSERT , UPDATE and DELETE operations on PRACTICE.EMP table for which I did :
    1) Logged in as SYS
    2) SQL> AUDIT SELECT, INSERT, UPDATE, DELETE
    ON PRACTICE.EMP
    BY ACCESS
    WHENEVER SUCCESSFUL;
    Audit Succedded
    Now how should I find out the SQL statement that does the insert, update or delete operation on the EMP table using SYS.AUD$ table
    Thanks

    Hi,
    It's contents can be viewed directly or via the following views:
    * DBA_AUDIT_EXISTS
    * DBA_AUDIT_OBJECT
    * DBA_AUDIT_SESSION
    * DBA_AUDIT_STATEMENT
    * DBA_AUDIT_TRAIL
    * DBA_OBJ_AUDIT_OPTS
    * DBA_PRIV_AUDIT_OPTS
    * DBA_STMT_AUDIT_OPTS
    The audit trail contains a lot of data, but the following are most likely to be of interest:
    * Username : Oracle Username.
    * Terminal : Machine that the user performed the action from.
    * Timestamp : When the action occured.
    * Object Owner : The owner of the object that was interacted with.
    * Object Name : The name of the object that was interacted with.
    * Action Name : The action that occured against the object. (INSERT, UPDATE, DELETE, SELECT, EXECUTE)
    So, take a look at action_name column from DBA_AUDIT_TRAIL view.
    Cheers
    Legatti

  • How to use a proxy; xmltype as a constructor

    How do I set the proxy server that is used by oracle internally, for example, when parsing an xml document that uses a dtd.
    As some background, I have a field in a database that is a varchar2. The content of this field is an xml fragment (actually xhtml).
    My query converts this into an XMLType object by using the XMLType function (as a constructor). To make this into a fragment rooted in a single element, I wrap this in a fresh div.
    So far so good. This all works. :-)
    This content sometimes contains entity references (like "& gt;" or "& nbsp;").
    Oracle could not handle this so I am now includin a DTD DOCTYPE declaration in my XMLType call. I'm using the XHTML 1.0 DTD.
    Here's a simplified version of my query:
    select
    headline,
    XMLType('<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><div class="description">' || outage.description || '</div>')
    as description,
    timestamp
    from
    outage
    where
    o.activation_start <= TRUNC(SYSDATE)
    order by
    timestamp desc

    Matthew,
    Set the OS environment variable for the http proxy server.
    There is a metalink note that explains this.

  • How to use my recovery to re instill my sys?

    hi
    Dear ,
    appreciate your efforts to help me as I faced some problem with my PC and as I dont have enough time to go to the Tochicha TS in our region and I asked our Company IT that I worked for to instill another Operation till I can go to the TS to fix this problem but still now I dont have the time to do that and I cant use the recovery to reset my PC to the first factory set with the original operation sys. that I used .
    So My Question is :how to use my recovery to re instill my sys, however I used another version in my PC ,informing :
    My lap top is:Satellite L655-18T
    Operating system
    Genuine Windows 7 Home Basic 32-bit (pre-installed, Toshiba-HDD recovery)
    and I am using Windows 7 unlimited but not activated yet as I used my Windows 7 Home Basic serial to use it as a temporary solution .
    thank You in advanced .
    Ahmad

    hi Paolo30 ,
    You mean that I burn the HDD recovery on DVD and try to recover my Lap top operator Sys. from CD?
    that is what I got .. confirm me this info if You don't mind and I want You to have a look about this Pic from my recovery folder to determine If I have the source or not .
    thank You in advanced
    &gt;&gt;&gt;http://farm6.static.flickr.com/5094/5510804010_e908cd03c3_b.jpg
    > > >

  • How to data from SYS.XMLType column in database.

    Using BPEL 10.1.3.1
    I have a database adapter to a table in my oracle database that has several columns. One column (named 'xml_content') in the table is the type SYS.XMLTYPE.
    When I invoke the database adapter in BPEL the value always returns the following:
    <xmlContent>oracle.xml.parser.v2.XMLDocument@18eba9f</xmlContent>
    I need help with the steps to actually retrieve the value (either in string format, or xml).
    Nothing seems to document working with SYS.XMLTYPE columns in BPEL.
    Thanks!
    Mike

    Got it working now. I used the 'extract' function in my select statement, but had to add the .getStringValue() fuction. The extract function, just by itself, returns an XMLDocument type. The call for the column in the SQL statement looked like this.
    extract(XML_CONTENT, '/ROOTOBJECT').getStringVal() xml_content
    Thanks so much for your help. Problem solved!

  • Conversion/Type Cast of sys.XMLType to NUMBER and VARCHAR2

    How do we typecast or convert a variable of the type sys.XMLType to NUMBER and VARCHAR2?
    For e.g. I have a variable :-
    v_STATE sys.XMLType
    I want to convert it to either of the type NUMBER or VARCHAR2.

    How do we typecast or convert a variable of the type sys.XMLType to NUMBER and VARCHAR2?
    Your question is too vague to give a relevant answer.
    Typecasting doesn't make sense in this situation, XMLType is an opaque datatype, it's not like converting VARCHAR2 to NUMBER (or vice versa).
    Do you mean serializing the XML document, or extracting atomic node values, or something else ?
    Depending on your requirement, you may want to look for XMLSerialize() or XMLCast() functions.
    And on a side note, don't always expect people to search for your previous threads to find some useful information, such as a db version...

  • How to link a XMLType table to a repository?

    I follow following steps:
    1) register a schema and generate a default table
    2) insert XML documents ( specifing the schema just registered) into the table by using SQL
    But how to let those XML documents show up in the repository so that users can access to them by using HTTP/FTP so that any update done to the table will be reflected in the repository and vice versa.
    I tried many things but no luck.

    Everything looks OK to me. In the folllowing example the createResource() is the equivilant of the WebDAV copy. Do you have multiple database instances running on the server machine. It is possible that the WebDAV connection is connected to another database instance.
    What folder are you copying the data into
    Can you do
    select path from path_view where under_path(res,'/targetFolderForWebDav') = 1
    SQL>
    SQL> var schemaURL varchar2(256)
    SQL> var schemaPath varchar2(256)
    SQL> --
    SQL> begin
      2    :schemaURL := 'http://localhost:8090/CMDEMO/fullname.xsd';
      3    :schemaPath := '/public/testcase.xsd';
      4  end;
      5  /
    PL/SQL procedure successfully completed.
    SQL> call dbms_xmlSchema.deleteSchema(:schemaURL,4)
      2  /
    Call completed.
    SQL> declare
      2    res boolean;
      3    xmlSchema xmlType := xmlType(
      4  '<?xml version="1.0"?>
      5  <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xdb="http://xmlns.oracle.com/xdb">
      6    <xs:element name="fullName" type="xs:string" xdb:defaultTable="FULL_NAME_TABLE"/>
      7  </xs:schema>
      8  ');
      9  begin
    10    if (dbms_xdb.existsResource(:schemaPath)) then
    11      dbms_xdb.deleteResource(:schemaPath);
    12    end if;
    13    res := dbms_xdb.createResource(:schemaPath,xmlSchema);
    14  end;
    15  /
    PL/SQL procedure successfully completed.
    SQL> begin
      2    dbms_xmlschema.registerSchema
      3    (
      4      :schemaURL,
      5      xdbURIType(:schemaPath).getClob(),
      6      TRUE,TRUE,FALSE,TRUE
      7    );
      8  end;
      9  /
    PL/SQL procedure successfully completed.
    SQL> desc FULL_NAME_TABLE
    Name                                                                                Null?    Type
    TABLE of SYS.XMLTYPE(XMLSchema "http://localhost:8090/CMDEMO/fullname.xsd" Element "fullName")
    SQL> --
    SQL> set long 100000 lines 150
    SQL> --
    SQL> select *
      2   from FULL_NAME_TABLE
      3  /
    no rows selected
    Execution Plan
    Plan hash value: 3651065813
    | Id  | Operation         | Name            | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT  |                 |     1 |  2022 |     2   (0)| 00:00:01 |
    |*  1 |  TABLE ACCESS FULL| FULL_NAME_TABLE |     1 |  2022 |     2   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       1 - filter(SYS_CHECKACL("ACLOID","OWNERID",xmltype('<privilege
                  xmlns="http://xmlns.oracle.com/xdb/acl.xsd"
                  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                  xsi:schemaLocation="http://xmlns.oracle.com/xdb/acl.xsd
                  http://xmlns.oracle.com/xdb/acl.xsd DAV:http://xmlns.oracle.com/xdb/dav.xsd">
                  <read-properties/><read-contents/></privilege>'))=1)
    Note
       - dynamic sampling used for this statement
    SQL> declare
      2    res boolean;
      3    docPath varchar2(40) := '/public/testcase.xml';
      4    xmldata xmlType := xmlType(
      5  '<fullName xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      6  xsi:noNamespaceSchemaLocation="http://localhost:8090/CMDEMO/fullname.xsd">
      7  David King
      8  </fullName>');
      9  begin
    10    if (dbms_xdb.existsResource(docPath)) then
    11      dbms_xdb.deleteResource(docpath);
    12    end if;
    13    res := dbms_xdb.createResource(docPath,xmldata);
    14  end;
    15  /
    PL/SQL procedure successfully completed.
    SQL> select *
      2   from FULL_NAME_TABLE
      3  /
    SYS_NC_ROWINFO$
    <fullName xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://localhost:8090/CMDEMO/fullname.xsd">
    David King
    </fullName>
    Execution Plan
    Plan hash value: 3651065813
    | Id  | Operation         | Name            | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT  |                 |     1 |  2022 |     3   (0)| 00:00:01 |
    |*  1 |  TABLE ACCESS FULL| FULL_NAME_TABLE |     1 |  2022 |     3   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       1 - filter(SYS_CHECKACL("ACLOID","OWNERID",xmltype('<privilege
                  xmlns="http://xmlns.oracle.com/xdb/acl.xsd"
                  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                  xsi:schemaLocation="http://xmlns.oracle.com/xdb/acl.xsd
                  http://xmlns.oracle.com/xdb/acl.xsd DAV:http://xmlns.oracle.com/xdb/dav.xsd">
                  <read-properties/><read-contents/></privilege>'))=1)
    Note
       - dynamic sampling used for this statement
    SQL>
    SQL>
    SQL>
    SQL>

  • How do I expose XMLType data in the repository

    Assume the PO schema po.xsd
    [oracle@chambers oracle]$ head po.xsd
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
               xmlns:xdb="http://xmlns.oracle.com/xdb"
               version="1.0"
               xdb:storeVarrayAsTable="true">
      <xs:element name="PurchaseOrder" type="PurchaseOrderType" xdb:defaultTable="PURCHASEORDER"/>
      <xs:complexType name="PurchaseOrderType" xdb:SQLType="PURCHASEORDER_T">
        <xs:sequence>
          <xs:element name="Reference" type="ReferenceType" minOccurs="1" xdb:SQLName="REFERENCE"/>
          <xs:element name="Actions" type="ActionsType" xdb:SQLName="ACTIONS"/>
          <xs:element name="Reject" type="RejectionType" minOccurs="0" xdb:SQLName="REJECTION"/>
    ...I have a document that conforms to the schema purchaseorder.xml
    [oracle@chambers oracle]$ more purchaseorder.xml
    <PurchaseOrder xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.nubridges.com/jchambers/po">
      <Reference>SBELL-2002100912333601PDT</Reference>
      <Actions>
        <Action>
          <User>SVOLLMAN</User>
        </Action>
      </Actions>
      <Reject/>
      <Requestor>Sarah J. Bell</Requestor>
      <User>SBELL</User>
      <CostCenter>S30</CostCenter>
      <ShippingInstructions>
        <name>Sarah J. Bell</name>
        <address>400 Oracle Parkway
    Redwood Shores
    CA
    94065
    USA</address>
    Step 1. Register the schema
      DBMS_XMLSCHEMA.registerSchema(
        SCHEMAURL => 'http://www.nubridges.com/jchambers/po',
        SCHEMADOC => bfilename('ORACLE_USER_HOME', 'po.xsd'),
        CSID      => nls_charset_id('AL32UTF8'));
    Step 2. Verify the registration
    SQL> desc purchaseorder
    Name                                      Null?    Type
    TABLE of SYS.XMLTYPE(XMLSchema "http://www.nubridges.com/jchambers/po" Element "PurchaseOrder") STORAGE Object-relational TYPE "PURCHASEORDER_T"
    Step 3. Insert a valid PO into the database
    insert into purchaseorder values(XMLType(bfilename('ORACLE_USER_HOME', 'purchaseorder.xml'), nls_charset_id('AL32UTF8')));
    Step 4. Verify PO insert ok
    SQL> select * from purchaseorder
      2  ;
    SYS_NC_ROWINFO$
    <PurchaseOrder xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamesNow, I want to be able to expose the purchase order via HTTP/WebDav. In other words, I want to create a repository resource.
    Step 5. Create a folder
    DECLARE
      b BOOLEAN;
    BEGIN
      b := DBMS_XDB.createFolder('/jchambers');
    END;
    Step 6. Create the resource.
    How do I do this using DBMS_XDB.createResource?
    I know I want to use one of these approaches, but how (I need some examples):
    Creates a new resource with the given XMLType data as its contents:
    DBMS_XDB.CREATERESOURCE(
       path    IN  VARCHAR2,
       data    IN  SYS.XMLTYPE)
    RETURN BOOLEAN;Given a REF to an existing XMLType row, creates a resource whose contents point to that row. That row should not already exist inside another resource:
    DBMS_XDB.CREATERESOURCE(
       path     IN  VARCHAR2,
       datarow  IN  REF SYS.XMLTYPE)
    RETURN BOOLEAN;Please advise. Thanks

    Step 6. Create the resource.
    How do I do this using DBMS_XDB.createResource?
    Creates a new resource with the given XMLType data as its contents:
    In this case you do not need to insert the row into the table. When you create the resource XML DB will automatically store the contents of the resource in the table for you...
    Eg
    declare
      res boolean;
    begin
      res :=  dbms_xdb.createResource('/jchambers/purchaseorder.xml',
                                             bfilename('ORACLE_USER_HOME', 'purchaseorder.xml'),  nls_charset_id('AL32UTF8'));
    end;
    /Given a REF to an existing XMLType row, creates a resource whose contents
    point to that row. That row should not already exist inside another resource:
    declare
      res boolean;
      xmlref ref xmltype;
    begin
      select ref(x)
         into xmlref
         from PURCHASEORDER x
        where existsNode(object_value,'/Some/Xpath/That/Identifies/Exactly/One/Row') = 1;
      res :=  dbms_xdb.createResource('/jchambers/purchaseorder.xml',xmlref);
    end;
    /

  • How to use OTT on sdo_georaster

    I want to get image extent from georasters in a OCI implementation so I am trying to generate sdo_georaster definition from OTT (Object Type Translator) but I am getting this error:
    $ more intype.typ
    TYPE SDO_GEORASTER
    $ ott userid=**/** intype=intype.typ outtype=out.typ hfile=out.h initfile=out.c code=c
    O2T-118, ERROR: User-defined type SYS.XMLTYPE was not found in the database
    $ more out.h
    <it is incomplete. only have geometry and point stuff>
    The type "SYS.XMLTYPE" is defined for sure, but maybe I need to be more specific.
    Does anybody have a solution or an alternative?
    Thanks.

    Thanks for the precision Jeffrey. I can't say that I particularly look forward to hand-writing this structures, although like you demonstrated this doesn't seem to be too difficult with OCI.
    OTOH, so far I've been using OCCI, not OCI, which also supports user-defined SQL types (Objects) via its oracle::occi::PObject base class and OTT-generated C++ classes deriving from PObject that represent these user types. How do you hand-write these? And what do you map the XMLType to in this case? I'm not even sure how I can get an XMLType out of a select statement without casting it to a CLOB and the performance hit that entail because I then need to reparse it using my XML parser of choice.
    So in short, can you also assert that OCCI fully supports Oracle Spatial object types?
    I have a clear bias between OCI and OCCI, given the latter's ease of use and elegance compared to OCI, and because I'm writing a C++ app, not a C app.
    Is one required to use the more complex OCI API to develop a Oracle Spatial application?
    Thanks, --DD                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How to Use Schannel for TLS Sockets on Windows?

    I need make a c++ TLS socket server running on Windows XP, and a c# TLS socket client on Windows 7.
    The reason of using Schannel TLS is that it is FIPS 140-2 validated.
    But it is not easy to find some sample code of Schannel.
    By search, I found two c++ TLS samples, but the samples use the secur32.dll, some APIs seem are FIPS non-approved.
    codeproject SSL/TLS client/server for .NET and SSL tunnelling
    http://www.coastrd.com/c-schannel-smtp C++ SSPI Schannel TLS example
    According to 140sp1000.pdf (Microsoft Windows Vista Kernel Mode Security Support Provider Interface (ksecdd.sys) Security Policy Document), following APIs are FIPS non-approved APIs.
    InitializeSecurityContextW
    ImpersonateSecurityContext
    EncryptMessage 
    DecryptMessage
    I am quite confused about two things:
    One is that the FIPS non-approved APIs of ksecdd.sys also are also non-approved in secur32.dll?
    Another question is what's the correct way of using Schannel. Are the samples using Schannel in the correct way, must the APIs InitializeSecurityContextW/EncryptMessage be used?
    I want some sample code about how to use Schannel in native c++ and managed c#.

    I'm not sure what information you are referring to that indicates InitializeSecurityContext() and EncryptMessage() are not FIPS compliant.  InitializeSecurityContext() is required API on the client side.  EncryptMessage() is the required API to
    encrypt data.  Both APIs are important APIs in SSPI.
    In .NET, you would use the SSLStream Class, https://msdn.microsoft.com/en-us/library/system.net.security.sslstream(v=vs.110).aspx .
     MSDN has sample code for both the client and server.
    There used to be an SSPI client + server sample (WebClient & WebServer) on the Windows SDK.   I don't know if it is still there.  If you can't find them, please let me know.
    thanks
    Frank K [MSFT]
    Follow us on Twitter, www.twitter.com/WindowsSDK.
     

  • How to use TCP Checksum Off-load in my network driver

    I am seeking infomation on how to use TCP Checksum Off-load to tell the Solaris 8 stack not to handle it for both receives and transmits (and let our NIC handle this compute-intensive task instead).
    There is mention that Sun GigabitEthernet Adapter cards, Release 1.1 supports Sol-2.6 use of NIC features: TCP checksum offload & byte swapping
    There are limited bits of info in include files. For example
    sys/strick.h indicates use of:
    inetcksum_t's ick_xmit
    stream.h has:
    struct datab's unsigned u16:16; /* used to store hw-calculated cksum
    #define STRUIO_IP 0x04 /* IP checksum stored in db_struioun */
    #define STRUIO_ZC 0x08 /* mblk eligible for zero-copy */
    strsub.h has:
    struct zero_copy_kstat
    Also /include/inet/tcp.h has tcp_sum for outbound.
    Thank you. -Weimin Tchen

    VenK7337,
    Could you show your python code. so we know what your are "writing" to the ethernet port?
    That way we can see what you are receiving.
    Parsing the incoming data (from the TCP-read) depends heavily on the device that sends it, and can not generically be described. LabVIEW has many byte (and even bit) manipulation functions to convert many different data formats to its own build in formats.
    So after the TCP listener is connected, you are constantly reading from the established connection (until it gets broken of course). More advanced example would be the internet toolkit if oyu have it.
    From the read characters (and I hope you designed a protocol with a clear starting character, ending character and maybe even a build in checksum) you parse the data and perform you action, and of course generate a reply. Again the internet toolkit is a good example. It parsed the input as it comes it, based on the HTTP format. Then generates the reply based on the request received.
    These days I would suggest not to use binairy encoded numerics. Try and use XML formatted data. Yes, it causes a lot of overhead. But typically this is not an issue and makes the code a lot more portable and maintainable. Also makes it easier to interface with other languages/platforms.
    Umless of course you are looking at Khz data rates, then XML is not th preferred choice.
    Hope this helps...

Maybe you are looking for

  • Immediate-Mode Rendering

    Hi, i wrote a normal rendering methode but i want to change it to Immediate-Mode Rendering which is in Java3D can anyone help me and tell me how to do that? here is my current rendering function that i want to change:      public void render( Scene s

  • Found original box for Adobe Premiere Pro 2.0

    found original box for Adobe Premiere Pro 2.0 bought back in2009/2010, need to get activation code for it please. PN: 25520367 Faye

  • Javascript on Delete

    Hi, I created a button that runs a procedure (delete data) I attached javascript code to the button. javascript:confirmDelete('Are you sure you want to delete data?'); I added the java script to HTML Header on the page <script language="JavaScript" t

  • Birthdays not appearing on calendar

    Hi! Since yesterday, Facebook birthdays are not appearing on my iPad mini's calendar. Everything is checked as it should be and, of course, I'm connected to Facebook. Internet search has not helped as I cannot find this specific problem.  Any help wo

  • Global - MathScript Node Failed To Compile Error

    I have Labview 2009 SP1 with Mathscript Module. While using 'global' command, I've encountered "MathScript Node Failed To Compile Error" from the first time I tried it.  In Mathscript window: 'Error in line 0:  An internal error occurred while proces