XPath and oracle parser

Hi,
I am using Oracle parser to parse my XML file, as i found that it is faster then IBM and sun parser, But i think it does not support XPath, so how can i use XPath and oracle parser, I can also use Sun parser , but dont know if it has XPath support,
So please help me out

I suppose it supports DOM or a saxHandler that can provides you a DOM
tree. For Xpath, may I suggest you my solution : http://www.japisoft.com/jxpath
Regards,
A.brillant

Similar Messages

  • Xpath and oracle business rules

    Hi; are there any examples that demonstrate using XPath in a rule?
    Any comments on whether oracle business rules might be a valid choice for an application that needs to enforce a set of, and varying, constraints on an incoming XML document.
    Thanks for the info.
    -Tim Watson

    The XPath support in the current version of Rules is for asserting portions (or all) of an XML document as facts. The Rules are then written against the elements in the XML that you are interested in.
    I can't say for sure without more details, but Rules would work for enforcing constraints on XML documents.

  • FOP and oracle parser

    Hi
    i developed a web application that takes an xml file which the user specifies and after validating it the application uses FOP to produce a PDF file. But the problem is that by default oc4j uses oracle.xml.parser.v2 parser but FOP need xerces. How can i override the usage of oracle's xml parser.
    Please help because i spent quite some time on this project and this is the problem i almost at the end of the project run it to.
    thanks,
    mate

    I did that allready and stil my NullPointerException printout looks like this:
    java.lang.NullPointerException
         void oracle.xml.jaxp.JXTransformer.reportXSLException(oracle.xml.parser.v2.XSLException)
              JXTransformer.java:762
         void oracle.xml.jaxp.JXTransformer.transform(javax.xml.transform.Source, javax.xml.transform.Result)
              JXTransformer.java:335
         void oracle.xml.jaxp.JXTransformerHandler.endDocument()
              JXTransformerHandler.java:135
         void oracle.xml.parser.v2.NonValidatingParser.parseDocument()
              NonValidatingParser.java:269
         void oracle.xml.parser.v2.XMLParser.parse(org.xml.sax.InputSource)
              XMLParser.java:147
         void oracle.xml.jaxp.JXXMLFilter.parse(org.xml.sax.InputSource)
              JXXMLFilter.java:91
         void org.apache.fop.apps.Driver.render(org.xml.sax.XMLReader, org.xml.sax.InputSource)
              Driver.java:498
         void srcsi.pdf.PDFPrikazAction.renderXML(org.apache.fop.apps.XSLTInputHandler, javax.servlet.http.HttpServletResponse)
              PDFPrikazAction.java:135
         org.apache.struts.action.ActionForward srcsi.pdf.PDFPrikazAction.execute(org.apache.struts.action.ActionMapping, org.apache.struts.action.ActionForm, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
              PDFPrikazAction.java:95
         org.apache.struts.action.ActionForward org.apache.struts.action.RequestProcessor.processActionPerform(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, org.apache.struts.action.Action, org.apache.struts.action.ActionForm, org.apache.struts.action.ActionMapping)
              RequestProcessor.java:484
         void org.apache.struts.action.RequestProcessor.process(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
              RequestProcessor.java:274
         void org.apache.struts.action.ActionServlet.process(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
              ActionServlet.java:1482
         void org.apache.struts.action.ActionServlet.doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
              ActionServlet.java:525
         void javax.servlet.http.HttpServlet.service(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
              HttpServlet.java:760
         void javax.servlet.http.HttpServlet.service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
              HttpServlet.java:853
         void com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.ResourceFilterChain.doFilter(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
              ResourceFilterChain.java:65
         void FilterEncoding.doFilter(javax.servlet.ServletRequest, javax.servlet.ServletResponse, javax.servlet.FilterChain)
              FilterEncoding.java:22
         void com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.invoke(javax.servlet.ServletRequest, javax.servlet.ServletResponse)
              ServletRequestDispatcher.java:560
         void com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.forwardInternal(javax.servlet.ServletRequest, javax.servlet.http.HttpServletResponse)
              ServletRequestDispatcher.java:306
         boolean com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.HttpRequestHandler.processRequest(com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.ApplicationServerThread, com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.EvermindHttpServletRequest, com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.EvermindHttpServletResponse, java.io.InputStream, java.io.OutputStream, boolean)
              HttpRequestHandler.java:767
         void com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.HttpRequestHandler.run(java.lang.Thread)
              HttpRequestHandler.java:259
         void com.evermind[Oracle9iAS (9.0.3.0.0) Containers for J2EE].server.http.HttpRequestHandler.run()
              HttpRequestHandler.java:106
         void EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run()
              PooledExecutor.java:803
         void java.lang.Thread.run()
              Thread.java:484

  • XPATH and the C parser

    Can I use an 'XPATH' expression to find a node using the C parser?
    eg find '/A/B/C'
    The Oracle Java parser supports this.
    Thanks for your help.
    Doug

    Yes, we have Xpath and XSLT support in the parser.

  • Oracle9i: Difference between oraxml and oracle.xml.parser.v2.DOMParser?

    I have parsed the following xml document with the oraxml batch
    and with the sample '..\xdk\demo\java\parser\dom\DOMSample' and
    observed a diffent behavior in Oracle9i:
    <?xml version="1.0" encoding="utf-8" standalone="yes" ?>
    <Document xmlns:n1='urn:example:some-names'
    xmlns:n2='urn:example:some-names'>
    <BadAttrs_XML_1.0 att='1' att='2' />
    <BadAttrs_Namespaces n1:att='1' n2:att='2' />
    <OKAttrs_XML_1.0 att='1' n2:att='2' />
    </Document>
    ----------------------------1.) oraxml
    C:\oracle\ora9011\xdk\demo\java\parser\dom>oraxml -version
    -warning Namespaces2.xml
    Parser version: Oracle XDK Java 9.0.1.0.0 Production
    The input XML file is parsed without errors using partial
    validation mode
    Oraxml does not recognize the two attributes with the same name
    in element 'BadAttrs_XML_1.0' as an error.
    2.) oracle.xml.parser.v2.DOMParser
    C:\oracle\ora9011\xdk\demo\java\parser\dom>java DOMSample
    Namespaces2.xml
    file:Namespaces2.xml<Line 8, Column 38>: XML-0124: (Fata
    l Error) An attribute cannot appear more than once in the same
    start tag.
    oracle.xml.parser.v2.XMLParseException: An attribute cannot
    appear more than once in the same start tag.
    I have modified the DomSample.java. The DomParser just checks for
    well-formed documents and doesn't validate the document anymore.
    (only a comment before
    parser.setValidationMode(DOMParser.DTD_VALIDATION);)
    My question is:
    Is there really a difference between oracle.xml.parser.v2.oraxml
    and oracle.xml.parser.v2.DOMParser or which parameters do I have
    to use to get the same results?
    With Oracle8i, both report an xml error!!
    (Oracle9i, Win2000, JDK1.3)
    Thanx in advance!
    Markus

    It would appear that there is a difference when a loadjava is given a jar vs. the individual class files. When I load the jar, I get the previously described error, but when I load the individual class files (the same class files that the jar contains) the error goes away.
    Why?

  • High parsing with Siebel and Oracle RAC 10gR2

    Hi all,
    I'm working for a company that uses Siebel 8 with a 2 nodes RAC 10gR2. 70GB SGA with assured minimum values for shared pool 16GB, 50GB db buffer cache and the rest distributed among the other pools.
    In the last weeks we are facing a very annoying issue in our production system, at random times we have a very high concurrency peak with contention events like:
    - cursor: pin S wait on X
    - latch: library cache
    and a performance problem as a consequence.
    I have read all the documents on metalink about these types of waiting events and how to troubleshoot it, but I can't get rid of this problem.
    We have dynamic SGA configured, but we haven't had any resizes in the last weeks.
    We didn't have many "version count" for query, we are about <40.
    In the AWR I have noticed that we have very high parsing (in most cases query execute=query parse). We have talked to our Siebel support team to propose them the use of CURSOR_SHARING=FORCE, but they told us that it's unsupported.
    We have increased the parameter session_cached_cursors from 50 to 1000, but in the last days the problem has even got worse.
    I suppose that the solution could be reducing the parse count and elapsed parse time, but without changing the CURSOR_SHARING parameter and not much help from Siebel support, I don't know how to achieve this.
    Does anyone have any idea?

    The only way you can reduce the number of parses is to fix Siebel (in other words - not much you can do).

  • How to relate java and Oracle

    i have to tried to make programs using java and oracle. if i give the values in the 'insert' statement it is getting updated in the original table in oracle but how to take the values from the text fields of java and insert into the tables in oracle. do we have any methods to convert the values into sql type. pl reply.

    Here is a sample of a Java program that uses JDBC and a PreparedStatement. This particular program does a select, but you can also use this for inserts. I'm not 100% this is what you are looking for, but if it isn't just let me know. I'll help if I can.
    Joel
    For inserts, just replace this code:
    ResultSet rs = ps.executeQuery();
    while (rs.next()) {
      System.out.println(rs.getInt(rs.findColumn("CNT")));
    }with this code (and obviously change the Select string to an Insert String):
    int rowcnt = ps.executeUpdate();Here is the whole program:
    import java.sql.*;
    import java.util.*;
    import java.text.*;
    class dbtest {
        public static void main(String args[]) throws SQLException {
            try {
                String timeString = new String("2000-11-01 23:59:59");
                SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd H:m:s");
                java.util.Date date = format.parse(timeString);
                Timestamp timestamp = new Timestamp(date.getTime());
                DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
                Connection conn =
                    DriverManager.getConnection(
                        "jdbc:oracle:thin:@riker:1521:mydb",
                        "myusername",
                        "mypassword");
                String sql =
                    "SELECT COUNT(*) CNT FROM SERVICE_ALARM "
                        + "WHERE TRANS_STREAM_NODE_ID = ? "
                        + "AND SERVICE_ID = ? "
                        + "AND ALARM_ID = ? "
                        + "AND RAISED > TO_DATE(?,'YYYY-MM-DD HH24:MI:SS')";
                PreparedStatement ps = conn.prepareStatement(sql);
                ps.setString(1, "ROW1");
                ps.setInt(2, 1);
                ps.setString(3, "ROW1");
                String myDate =
                    timestamp.toString().substring(0, timestamp.toString().length() - 2);
                System.out.println("myDate=(" + myDate + ")");
                ps.setString(4, myDate);
                ResultSet rs = ps.executeQuery();
                while (rs.next()) {
                    System.out.println(rs.getInt(rs.findColumn("CNT")));
                rs.close();
                ps.close();
            } catch (Exception e) {
                System.out.println("Java Exception caught, error message=" + e.getMessage());
    }

  • XQuery and Oracle XE ...

    Hi all,
    One of the major differences between "DB2 Express-C" and "Oracle XE" seems to be, support for XML and XQuery in particular. If I read this right "Oracle XE" is a purely "relational database" whereas "DB2 Express-C" is a "hybrid". (relational and XML).
    With the aggressive adoption of various XML technologies (XML, XSD, XPath/XSLT, Xquery ...) we could be seeing a whole new category of "XML rich" or "XML enabled" apps. In this environment, I would like to see Oracle take a leadership position and release a small-footprint, free edition with support for XQuery. It would be helpfull for the "innovators" and would certainly help Oracle sell their bigger DB's down, the line.
    Oracle's current position w.r.t "Oracle XE" is certainly baffling. Hopefully someone at Oracle can reply.
    Regards
    /rk

    >
    Your suggestion of trying XQuery commands in sql*plus or isql*plus would make sense if there was fundamental support for XQuery in the targetted instance of "Oracle XE". The "datasheet" on "Oracle XE" has absolutely no mention of XQuery.
    >
    My question was: Are we talking about a documentation bug or is the XQuery feature really missing in the XE edition?
    >
    On the other hand IBM's "DB2 Express-C" is an aggressive, uptodate "hybrid" DB with builtin support for XML (XMLType, XQuery ...) in addition to the proven "relational" model.
    >
    That's nice - now if IBM would finally include basic stuff like MVCC or a SP/Trigger/Application-Language like PL/SQL, DB2 Express-C would really become attractive for developers like me. Until then, I think I'll stick with the limits of XE or consider a switch to SE1 if I get the required funding.
    C.

  • Compare SQL Server and Oracle syntax

    Hello, I am very new to the Oracle DB as I have been working with MS SQL Server for many years. I have a SQL statement that works fine in MSSQL but seems to not work in Oracle. Is this a syntax problem or do I need to look elsewhere?
    DECLARE @as_master_key varchar(26)
    EXEC [dbo].[GET_UNIQUE_MASTER_KEY]
         @as_project_name = N'CMDEMO',
         @as_database_site = N'CMPL',
         @as_user_initials = N'SK',
         @as_table = N'SUBMITTAL_CATEGORY',
         @as_master_key =
         @as_master_key
    OUTPUT SELECT @as_master_key as N'master_key'
    This is what I use in MSSQL and it works fine - but I am porting this application to an Oracle backend and it fails. Any suggestions?
    Thanks in advance to this newbie. :)

    SQL Server and Oracle are two completely different RDBMS'.
    You'd be best not to try and port SQL Server code to Oracle SQL or PL/SQL directly as it will not favour the power of Oracle's features correctly.
    I'm not sure what your code is supposed to be doing (I find SQL Server code awful to read, and never understand the need for "@" before variable names, that just seems to show a lazy parser (or lazy coder who designed the parser)).
    From what I can guess it's going to be something like...
    SQL code...
    create or replace sequence my_master_key;PL/SQL code...
    DECLARE
      as_master_key number;
      as_project_name varchar2(20) := 'CMDEMO';
      as_database_site varchar2(20) := 'CMPL';
      as_user_initials varckar2(5) := 'SK';
      as_table varchar2(30) := 'SUBMITTAL_CATEGORY';
    BEGIN
      select my_master_key.nextval
      into as_master_key
      from dual;
      -- In 11g you could replace this select with just:
      -- as_master_key = my_master_key.nextval;
    END;This get's a unique sequence value into a variable and declares all the other variables. What you want to do with them after that I don't know.

  • OAS 4.0 and Oracle 8i refuse to exec stored proced with more than 20 params

    Hi,
    I'm programming a web application with stored plsql procedures and Oracle Application Server.
    I started using Oracle 8.0.5 and OAS 4.0. It was working fine until I needed to use dynamic plsql and decided to upgrade to Oracle 8i (8.1.7).
    Some of my stored procedures have more than 20 input parameters and didn't supose any problem in the "old" installation, but now when I try to execute
    them via OAS over Oracle 8i it returns an error as if the number of parameters I gave were incorrect.
    Modifying the procedure so it has less than 20 parameters works fine.
    In resume: with the same input form and the same stored procedure with more than 20 input parameters works under Oracle 8.0.5 but fails under 8i.
    Any ideas why the newest version doesn't accept more than 20 parameters?
    Thank you.
    Miquel Salvà
    [email protected]

    Hi Martin.
    So, as far as i understood is the step where data is loaded into database that is taking too long ?
    Wich one of these is your cenario ??
    Cenario 1
    Step 1) Export product data as CSV fike
    Step 2) 3rd party app parses data (some processing is done in CSV file) generating another (or overwritting the original) CSV file
    Step 3) CSV file generated in step 2 is pushed to database using sqlloadr
    Step 4) Some pos-loading transformation is done
    Cenario 2
    Step 1) Export product data as CSV fike
    Step 2) CSV file is loaded into database using SqlLoader
    Step 3) After sqlloader is finish, some post-load processing is done
    Step 4) 3dr party transformation is done
    I think your problem can be in loading that data into database.
    Is the CSV file big?
    you can fasten sqlloader using direct-mode, destination tables can be in nologging mode (faster) and with the right space allocated (avoiding segment alocattion overhead)
    Best Regards
    Rui Madaleno

  • Does the XMLP full or partially support the Xpath and XSLFO syntax?

    Does the XMLP full support the Xpath and FO syntax? or partially? Thanks

    Hi Robin
    OK, so hopefully you are not leading me into a trap here :o)
    There are two parts to this question:
    1. XPATH - we support as much of the XPATH spec as the Oracle XDK supports ie we rely on the XDK for our transformation engine so as long as they support what you are trying to do then we do. There are a few gaps and we have plugged those in the XMLP layer. So the short answer is yes.
    2. XSLFO - we allow you to use XSLFO in your template. The XMLP engine supports much of the standard but there are a few gaps. the next set of docs will layout exactly what we do support in the spec.
    Regards, Tim

  • Xpath in Oracle 9i

    Could you give me lead on how to use xpath to generate DB using the defined XMLs? Could you give me some lead? Or, some websites that I can find info?
    Really appreciate for your help!

    Can you post some sample of what exactly you are trying to do?
    This is one way to use xpath expressions within DB:
    SQL> column text format a30
    SQL> column db format a30
    SQL> column version format a30
    SQL> SELECT d.xpath.extract('/DB/text()') .getStringVal() text,
      2         d.xpath.extract('/DB/@NAME') .getStringVal() db,
      3         d.xpath.extract('/DB/@VERSION') .getStringVal() version
      4  FROM   (SELECT xmltype('<DB NAME="Oracle9i" VERSION="9.2.0.5">We work with Oracle databases</DB>') xpath
      5          FROM   dual) d;
    TEXT                           DB                             VERSION
    We work with Oracle databases  Oracle9i                       9.2.0.5
    SQL> disconnect
    Disconnected from Oracle9i Enterprise Edition Release 9.2.0.5.0 - Production
    With the Partitioning, OLAP and Oracle Data Mining options
    JServer Release 9.2.0.5.0 - Production
    SQL>

  • IRecruitment: Background Checks and Resume Parsing

    Hi all,
    Does anyone have experience with Background Check and Resume Parsing features in iRecruitment? There is not a lot about it in the implementation guide and Metalink.
    Do we have to make an interface for it? I know that HireRight is the approved Oracle vendor for background checks and we need to send them data in XML format through HTTPS or some other method. I want to have some guidelines regarding this from functional point of view.
    Thanks all.

    I've been involved with the implementation of resume parsing and background checking twice. Both times, the HireRight implementation was very simple. Only a couple of profile options and then some network configuration. (there is a bit of work to be done, however, on the deal with HireRight. e.g. which background checks are your recruiters allow to request, etc)
    Resume parsing on the other hand, can be a bit more tricky. The setups on the IRC functional side are also simple, but the configuration of the wallets and other DMZ related items proved to be very time-consuming.

  • PHP 5.1.4 and Oracle 10G XE ?

    I am using PHP 5.1.4 with OCI8.dll module, and Oracle 10G XE. My question is how to Edit and Delete Record in my table using PHP syntax ?.
    Best Regards,
    /Harso Adjie.

    You use SQL syntax not PHP syntax to UPDATE / DELETE the records and run the query in a similar manner to SELECT statements:
    Parse your Oracle statement: oci_parse()
    Execute your Oracle statement: oci_execute()
    (You will need to commit transaction if not using auto-commit) Commit your transaction: oci_commit()
    http://uk.php.net/manual/en/ref.oci8.php

  • XDK for PL/SQL and XML Parser for PL/SQL

    Is there a difference between the terms:
    XDK for PL/SQL
    and
    XML Parser for PL/SQL V2
    or are they the same thing...?
    cheers,

    XDK stands for XML Developer's Kit. There are Oracle XDKs for Java, C, C++, and PL/SQL. These development kits contain building blocks for reading, manipulating, transforming, and viewing XML documents.
    XML Parser is one component of XDK. Other components of XDK are
    XSLT Processor, XSU, XSQL Servlet, XML Class Generator, etc.
    For more information on XDK and its components please refer to:
    http://otn.oracle.com/docs/products/oracle9i/doc_library/release2/appdev.920/a96621/adx01bas.htm#1656
    Regards,
    Anupama
    http://otn.oracle.com/sample_code/content.html

Maybe you are looking for

  • Multi Threaded Insert in Berkeley DB

    Hi, This is my requirement. Have to read 9 million records from Oracle DB. Have to identify KEY and have to instantiate VO object as VALUE Have to insert 9million records (key and value VO's) into Berkeley DB. What is the best way to do this? Perform

  • Is MX 2004 compatible with Windows 7? [was: mx 2004]

    Is dw mx 2004 compatible with windows 7? Thanks. Limps [Subject line edited by moderator for clarity]

  • Internet explorer and bonjour

    Hey i was just wondering i downloaded bonjour for windows. and i have a couple things to ask. 1. I got this thing that said no add ons next to the icon how can i fix that? 2. Even if it says that can i still use Bonjour? Thanks, Aaron

  • Can't cancel my premium subscription

    Whenever I try to got to the setting page to cancel my subscription the page is down for service or I get an http error 500. I want my subscription cancel now.

  • Crystal Report - IIS - ASP - French

    Bonjour, j'ai acheté Crystal Reports XI R2 (version FR), mais je ne trouve aucune doc en FR. Est-il possible d'utiliser Crystal Reports XI R2 sur un serveur IIS (version 6 - Windows 2003)? Si oui, quels sont les plugins à installer ? (exemples) ? I s