Workaround for using Oracle JDBC extension with WLS pooling

Reading the newsgroup I saw that many of us encountered the problems
with ClassCastException when tried to use Oracle JDBC extension
with WLS pooling. I also had.
In this case BEA recommends to use dangerous
method getVendorConnection() which exposes
the physical connection object to your code.
Yes it's really dangerous because of unsafe usage may breaks
WLS pooled connection(s).
Moreover, this practice will make your JDBC code
unportable (your JDBC code in addition to Oracle dependence
became Weblogic dependent):
void doSmth() {
Connection con = ...;
Connection vCon = ((WLConnection)con).getVendorConnection();
// + mess of usage con in one places and vCon in others
// (where Oracle extensions are needed)
// !Don't forget to don't close vCon!
Sux.
I found the workaround.
Introduction
============
Yes the real cause of ClassCastException is that
in depth of Oracle driver the casting
to class oracle.jdbc.driver.OracleConnection
(not to interface oracle.jdbc.OracleConnection)
is performed.
Someone can say that this is bug or pure desing.
Weblogic pooled connection provide dynamic
implementation for all public interfaces
which real physical (wrapped) connection object implements.
Great feature!
But I guess that all interface methods implemented
by simple call-delegation to physical (wrapped) connection object.
In case of oracle.jdbc.OracleConnection interface
this approach doesn't work for at least one its method:
public OracleConnection unwrap()
WLS pooled connection shoudn't implement this method by
delegation to physical connection object BUT should
return physical connection object itself!
// Wrong implementation of unwrap()
// delegation is used
public OracleConnection unwrap() {
return physicalConnection.unwrap();
// Right implementation of unwrap()
// physical connection returned
public OracleConnection unwrap() {
return physicalConnection;
Workaround
==========
1. Develop your own OracleConnection wrapper class:
import oracle.jdbc.OracleConnection;
import weblogic.jdbc.extensions.WLConnection;
public class MyOracleConnectionImpl implements OracleConnection {
private OracleConnection con;
public MyOracleConnectionImpl(OracleConnection connection)
throws SQLException
this.con = connection;
public OracleConnection unwrap() {
return (OracleConnection)
((WLConnection)con).getVendorConnection();
/* Implement all other methods by delegation to con object */
2. Don't get Connections directly from DataSource --
develop your own simple (may be static) utility
class which retrives Connections from dataSource
and returns them wrapped into your MyOracleConnectionImpl
to your code from some method:
puclic abstract class MyConnectionSource {
public static Connection getConnection() {
Connection con = // get it from DataSource
return new MyOracleConnectionImpl((OracleConnection)con);
3. Add attribute RemoveInfectedConnectionsEnabled="false"
to definition of your JDBCConnectionPool within config.xml
You may do it because of you `safely` use vendorConnection --
you don't expose it to application code.
4. Enjoy the Oracle JDBC extensions in your code!
Example:
Connection con = MyConnectionSource.getConnection;
ArrayDescriptor add =
ArrayDescriptor.createDescriptor("your_type", con);
Hope it helps to someone.
Best regards,
Eugene Voytitsky

Hello Eugene Voytitsky,
Thanks Eugene Voytitsky for your idea
I have tried the solution suggested by You, but it did not work.
It still throws ClassCastException.
I am sorry for posting the whole code of two classes below.
I did this to give you more clarity.
I am also indicating the place where the exception was thrown..
Please let me know if I am doing something wrong.
OracleConnection Wrapper class
package ejbTesting;
// sql imports
import java.sql.CallableStatement;
import java.sql.Connection;
import java.sql.DatabaseMetaData;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.Statement;
// util imports
import java.util.Map;
import java.util.Properties;
// imports from Oracle Driver Classes
import oracle.jdbc.OracleConnection;
import oracle.jdbc.OracleOCIFailover;
import oracle.jdbc.OracleSavepoint;
// import from Weblogic extensions
import weblogic.jdbc.extensions.WLConnection;
public class WeblogicConnectionWrapper implements OracleConnection
     // oracle connection object
     private OracleConnection connection;
     public WeblogicConnectionWrapper (OracleConnection orclConnection)
          try
               this.connection = orclConnection;
          catch(Exception unexpected )
               unexpected.printStackTrace();
     public OracleConnection unwrap()
          try
          // The datasource returns a weblogic.jdbc.pool.Connection
          // This needs to be type casted to weblogic.jdbc.extensions.WLConnection
          // Only this weblogic.jdbc.extensions.WLConnection CAN BE type casted
          // to OracleConnection
     return (OracleConnection) ((WLConnection) connection).getVendorConnection();
     catch(Exception sqlException )
          sqlException.printStackTrace ();
          return null;
     /* Implement all other methods by delegation to connection object */      
public Connection _getPC()
return connection._getPC();
public void archive(int i, int j, String s)
throws SQLException
connection.archive(i, j, s);
public void assertComplete()
throws SQLException
connection.assertComplete();
public void clearWarnings()
throws SQLException
connection.clearWarnings();
public void close()
throws SQLException
connection.close();
public void commit()
throws SQLException
connection.commit();
public Statement createStatement()
throws SQLException
return connection.createStatement();
public Statement createStatement(int i, int j)
throws SQLException
return connection.createStatement(i, j);
public boolean getAutoClose()
throws SQLException
return connection.getAutoClose();
public boolean getAutoCommit()
throws SQLException
return connection.getAutoCommit();
public CallableStatement getCallWithKey(String s)
throws SQLException
return connection.getCallWithKey(s);
public String getCatalog()
throws SQLException
return connection.getCatalog();
public boolean getCreateStatementAsRefCursor()
return connection.getCreateStatementAsRefCursor();
public int getDefaultExecuteBatch()
return connection.getDefaultExecuteBatch();
public int getDefaultRowPrefetch()
return connection.getDefaultRowPrefetch();
public Object getDescriptor(String s)
return connection.getDescriptor(s);
public boolean getExplicitCachingEnabled()
throws SQLException
return connection.getExplicitCachingEnabled();
public boolean getImplicitCachingEnabled()
throws SQLException
return connection.getImplicitCachingEnabled();
public boolean getIncludeSynonyms()
return connection.getIncludeSynonyms();
public Object getJavaObject(String s)
throws SQLException
return connection.getJavaObject(s);
public DatabaseMetaData getMetaData()
throws SQLException
return connection.getMetaData();
public Properties getProperties()
return connection.getProperties();
public boolean getRemarksReporting()
return connection.getRemarksReporting();
public boolean getRestrictGetTables()
return connection.getRestrictGetTables();
public String getSQLType(Object obj)
throws SQLException
return connection.getSQLType(obj);
public String getSessionTimeZone()
return connection.getSessionTimeZone();
public int getStatementCacheSize()
throws SQLException
return connection.getStatementCacheSize();
public PreparedStatement getStatementWithKey(String s)
throws SQLException
return connection.getStatementWithKey(s);
public int getStmtCacheSize()
return connection.getStmtCacheSize();
public short getStructAttrCsId()
throws SQLException
return connection.getStructAttrCsId();
public boolean getSynchronousMode()
return connection.getSynchronousMode();
public int getTransactionIsolation()
throws SQLException
return connection.getTransactionIsolation();
public Map getTypeMap()
throws SQLException
return connection.getTypeMap();
public String getUserName()
throws SQLException
return connection.getUserName();
public boolean getUsingXAFlag()
return connection.getUsingXAFlag();
public SQLWarning getWarnings()
throws SQLException
return connection.getWarnings();
public boolean getXAErrorFlag()
return connection.getXAErrorFlag();
public boolean isClosed()
throws SQLException
return connection.isClosed();
public boolean isLogicalConnection()
return connection.isLogicalConnection();
public boolean isReadOnly()
throws SQLException
return connection.isReadOnly();
public String nativeSQL(String s)
throws SQLException
return connection.nativeSQL(s);
public Object openJoltConnection(String s, short word0, short word1)
return connection.openJoltConnection(s, word0, word1);
public void oracleReleaseSavepoint(OracleSavepoint oraclesavepoint)
throws SQLException
connection.oracleReleaseSavepoint(oraclesavepoint);
public void oracleRollback(OracleSavepoint oraclesavepoint)
throws SQLException
connection.oracleRollback(oraclesavepoint);
public OracleSavepoint oracleSetSavepoint()
throws SQLException
return connection.oracleSetSavepoint();
public OracleSavepoint oracleSetSavepoint(String s)
throws SQLException
return connection.oracleSetSavepoint(s);
public int pingDatabase(int i)
throws SQLException
return connection.pingDatabase(i);
public CallableStatement prepareCall(String s)
throws SQLException
return connection.prepareCall(s);
public CallableStatement prepareCall(String s, int i, int j)
throws SQLException
return connection.prepareCall(s, i, j);
public CallableStatement prepareCallWithKey(String s)
throws SQLException
return connection.prepareCallWithKey(s);
public PreparedStatement prepareStatement(String s)
throws SQLException
return connection.prepareStatement(s);
public PreparedStatement prepareStatement(String s, int i, int j)
throws SQLException
return connection.prepareStatement(s, i, j);
public PreparedStatement prepareStatementWithKey(String s)
throws SQLException
return connection.prepareStatementWithKey(s);
public void purgeExplicitCache()
throws SQLException
connection.purgeExplicitCache();
public void purgeImplicitCache()
throws SQLException
connection.purgeImplicitCache();
public void putDescriptor(String s, Object obj)
throws SQLException
connection.putDescriptor(s, obj);
public void registerApiDescription(String s, short word0, short word1, String
s1)
connection.registerApiDescription(s, word0, word1, s1);
public void registerSQLType(String s, Class class1)
throws SQLException
connection.registerSQLType(s, class1);
public void registerSQLType(String s, String s1)
throws SQLException
connection.registerSQLType(s, s1);
public void registerTAFCallback(OracleOCIFailover oracleocifailover, Object
obj)
throws SQLException
connection.registerTAFCallback(oracleocifailover, obj);
public void rollback()
throws SQLException
connection.rollback();
public void setAutoClose(boolean flag)
throws SQLException
connection.setAutoClose(flag);
public void setAutoCommit(boolean flag)
throws SQLException
connection.setAutoCommit(flag);
public void setCatalog(String s)
throws SQLException
connection.setCatalog(s);
public void setCreateStatementAsRefCursor(boolean flag)
connection.setCreateStatementAsRefCursor(flag);
public void setDefaultExecuteBatch(int i)
throws SQLException
connection.setDefaultExecuteBatch(i);
public void setDefaultRowPrefetch(int i)
throws SQLException
connection.setDefaultRowPrefetch(i);
public void setExplicitCachingEnabled(boolean flag)
throws SQLException
connection.setExplicitCachingEnabled(flag);
public void setImplicitCachingEnabled(boolean flag)
throws SQLException
connection.setImplicitCachingEnabled(flag);
public void setIncludeSynonyms(boolean flag)
connection.setIncludeSynonyms(flag);
public void setReadOnly(boolean flag)
throws SQLException
connection.setReadOnly(flag);
public void setRemarksReporting(boolean flag)
connection.setRemarksReporting(flag);
public void setRestrictGetTables(boolean flag)
connection.setRestrictGetTables(flag);
public void setSessionTimeZone(String s)
throws SQLException
connection.setSessionTimeZone(s);
public void setStatementCacheSize(int i)
throws SQLException
connection.setStatementCacheSize(i);
public void setStmtCacheSize(int i)
throws SQLException
connection.setStmtCacheSize(i);
public void setStmtCacheSize(int i, boolean flag)
throws SQLException
connection.setStmtCacheSize(i, flag);
public void setSynchronousMode(boolean flag)
connection.setSynchronousMode(flag);
public void setTransactionIsolation(int i)
throws SQLException
connection.setTransactionIsolation(i);
public void setTypeMap(Map map)
throws SQLException
connection.setTypeMap(map);
public void setUsingXAFlag(boolean flag)
connection.setUsingXAFlag(flag);
public void setWrapper(OracleConnection oracleconnection)
connection.setWrapper(oracleconnection);
public void setXAErrorFlag(boolean flag)
connection.setXAErrorFlag(flag);
public void shutdown(int i)
throws SQLException
connection.shutdown(i);
public void startup(String s, int i)
throws SQLException
connection.startup(s, i);
Util class to get Wrapped Connections from
datasource
package ejbTesting;
// j2ee imports
import javax.naming.InitialContext;
import javax.sql.DataSource;
// sql imports
import java.sql.Connection;
// imports from Oracle Driver Classes
import oracle.jdbc.OracleConnection;
* Wrapper class for the DataSource Connection from Weblogic pool
public class DataSourceConnectionWrapper
     // datasource variable
     private static transient DataSource datasource = null;
     private static String dbName = "jdbc/workbench";
* Method that returns the database connection
     public static Connection getConnection()
          try
               // initialsing the datasource object
               initialiseDataSource ();
               // Getting a connection from the datasource
               Connection con = datasource.getConnection( );
               // wrapping it custom wrapper class and
               // returning the connection object
               return new WeblogicConnectionWrapper((OracleConnection)con);
          catch(Exception exception )
               exception.printStackTrace();
               return null;
     private static void initialiseDataSource( ) throws Exception
if ( datasource == null )
try
InitialContext ic = new InitialContext( );
datasource = (DataSource) ic.lookup( dbName );
catch (Exception ne )
throw new Exception( "NamingException while looking up DataSource with
JNDI name" +
dbName + ": \n" + ne.getMessage( ) );
Exception Stack Trace
The line 46 in DataSourceConnectionWrapper
corresponds to
return new WeblogicConnectionWrapper((OracleConnection)con);
Which I feel is logical as the connection which we get from Weblogic
datasource cannot be type casted to OracleConnection
java.lang.ClassCastException: weblogic.jdbc.pool.Connection
at ejbTesting.DataSourceConnectionWrapper.getConnection(DataSourceConnectionWrapper.java:46)

Similar Messages

  • Sql_trace does not work for Java app using Oracle JDBC thin driver

    Hi,
    I'm using Oracle 8.1.7. I enabled sql trace at instance level by setting sql_trace and timed_statistics to true in init.ora. I restarted the db instance. I wrote a stand-alone java application which used Oracle JDBC thin driver(classes12.zip) to make a connection to my db instance, do some select statements, and close the connection. There were no trace files generated in the folder specified by udump_dest variable. However, if I used sqlplus or dba studio, I saw trace files generated. Has anyone got Oracle sql trace work for JDBC calls from java apps.
    Thanks in advance!

    Hi,
    I'm using Oracle 8.1.7. I enabled sql trace at instance level by setting sql_trace and timed_statistics to true in init.ora. I restarted the db instance. I wrote a stand-alone java application which used Oracle JDBC thin driver(classes12.zip) to make a connection to my db instance, do some select statements, and close the connection. There were no trace files generated in the folder specified by udump_dest variable. However, if I used sqlplus or dba studio, I saw trace files generated. Has anyone got Oracle sql trace work for JDBC calls from java apps.
    Thanks in advance!

  • Question for using ORACLE with SOLARIS

    Hi Experts,
    I have worked Oracle with Linux in one of my projects 2yrs back and i was just a developer, used to write SQL Query, Creating Table and Objects.
    Now i got a question from TL which is
    Tell me about consequences for using Oracle with Solaris?
    I am not worked ORACLE with SOLARIS, Can some one give me the answer for this question with
    1. Difference between ORACLE with LINUX and ORACLE with SOLARIS.
    2. Advantages and Disadvantages Between ORACLE with LINUX and ORACLE with SOLARIS.
    Thanks,
    MuraliDharan V

    Hi MuraliDharan V,
    It would had been better if you had searched first;
    Here is one
    Advantage for Linux64-bit Versus Solaris-x86_64 OS in RAC
    And beside that your question is incomplete:
    -What Oracle? Database, etc
    -Which Version? 9i, 10g, etc
    Aside from that a simple search on google might have answered your question as well.
    But I think there is some new trend of dumping questions here before searching.
    Ex Senior DBA

  • Struts and Oracle JDBC extension

    hi all,
    When I try to use the Oracle JDBC extension to take advantage of the Oracle batch update feature, I got an
    exception "org.apache.commons.dbcp.DelegatingPreparedStatement"
    It happens when I try to cast a PrepareStatement to OraclePreparedStatement. (It works fine without the cast)
    Any idea why?
    Here is the code snippet:
    ServletContext context = servlet.getServletContext();
    DataSource ds = (DataSource) context.getAttribute(Action.DATA_SOURCE_KEY);
    try {
    Connection conn = ds.getConnection();
    String sql = "SELECT username FROM users";
    OraclePreparedStatement ps = (OraclePreparedStatement) conn.prepareStatement(sql);
    ResultSet rset = ps.executeQuery();
    } catch ( Exception e ) {
    System.out.println( e.getMessage() );
    struts_config.xml:
    <data-sources>
    <data-source>
    <!-- set-property property="driverClass" value="oracle.jdbc.driver.OracleDriver"/ -->
    <set-property property="driverClass" value="oracle.jdbc.OracleDriver"/>
    <set-property property="url" value="jdbc:oracle:thin:@hostname:1522:db"/>
    <set-property property="maxCount" value="5"/>
    <set-property property="minCount" value="1"/>
    <set-property property="user" value="xxx"/>
    <set-property property="password" value="xxx"/>
    </data-source>
    </data-sources>
    Thanks for any help!

    Hi scsi-boy:
    I have no trouble reading a Timestamp from Oracle...it's trying to write or update one (and unfortunately, I have to do as I said to get it done).
    you shouldn't have to import the oracle sql package
    That's precisely the point -- I am not trying to use any Oracle specific stuff.. It wouldn't be all that difficult for them to do the casting inside of the driver, instead they just add the following comments to their example:
           // Writing data to Lobs:
            // There are no methods to do this with java.sql.Clob/Blob. 
            // For oracle.sql.CLOB there is getAsciiOutputStream() to write via
            // an ascii stream and getCharacterOutputStream() to write via a
             // unicode one, plus putChars() to write a char array and putString()
             // to write a String - both at a given position within the Clob.  For
             // oracle.sql.BLOB there is getBinaryOutputStream() and putBytes(). 
            // There are also oracle.jdbc.driver classes to do similar that
            // take oracle.sql.CLOB/BLOB as appropriate, namely:
            //       OracleBlobOutputStream()
            //       OracleClobOutputStream()
            //       OracleClobWriter()
            // (Note all three classes have corresponding input/reader classes.)
            // Hence to write data to the lobs here it is necessary to cast the
             // Clob and Blob to oracle.sql.CLOB and oracle.sql.BLOB respectively
             // and use one of the methods listed above.  E.g. to append to the
            // clob column:
            ((oracle.sql.CLOB)c_lob).putString( (int)c_lob.length()+1, "\nBye!" );The example can be found at the link shown below (you may have to do a free sign-up to view it):
    http://www.experts-exchange.com/Databases/Oracle/Q_20358143.html
    ;o)
    V.V.

  • Exception "not implemented for class oracle.jdbc.driver.T4CNumberAccessor"

    Hello I'm having some troubles dealing with 'java.sql.Date' I'm working with express edition database and I have three classes(different packages)
    1.Mapper
    2.Objects Class
    3.ConsoleTest
    I need to get an arraylist of objects, some of which contain dates, but when try to do it I get this exception
    "java.sql.SQLException: Invalid column type: getDate not implemented for class oracle.jdbc.driver.T4CNumberAccessor"
    Do you have any idea how I can implement the getDate method for this T4CNumberAccessor
    Here are the methods that I'm using
    1.Mapper
    public ArrayList<Object> getAllTaskAuctions(Connection con)
              ArrayList<Object> l1 = new ArrayList<Object>();
              String SQLString1 = "select * from taskauction natural join tasks";
    PreparedStatement statement=null;
    try
    //=== get taskauctions natural join tasks
    statement = con.prepareStatement(SQLString1);
    ResultSet rs = statement.executeQuery();
    while(rs.next())
    l1.add(new TaskAuction(rs.getInt(1), rs.getInt(2), rs.getInt(3),
    rs.getDate(4), rs.getDate(5), rs.getInt(6)));
    l1.add(new Task(rs.getInt(1), rs.getInt(2), rs.getString(3),
    rs.getString(4), rs.getString(5), rs.getString(6), rs.getInt(7)));
    catch (Exception exc)
    System.out.println("Fail in TaskAuctionMapper - getAllTaskAuctions");
    System.out.println(exc);
    return l1;
    2.ConsoleTest class
    Connection con;
         public Connection getConnection(){
              try{ 
         Class.forName("oracle.jdbc.driver.OracleDriver");
         con = DriverManager.getConnection(
         "jdbc:oracle:thin:@localhost:1521:XE", "Project", "123" );
         //username/password@[/]host[:port][service_name]
         catch (Exception e)
         {   System.out.println("fail in getConnection()");
         System.out.println(e); }
              return con;
         public static void main(String[] args) {
              ConsoleTest ct = new ConsoleTest();
              TaskAuctionMapper tam1 = new TaskAuctionMapper();
    ArrayList<Object> alt1 = tam1.getAllTaskAuctions(ct.getConnection());
    Iterator<Object> itr1 = alt1.iterator();
    while (itr1.hasNext())
    TaskAuction taskauct = (TaskAuction) itr1.next();
    //Problem, exception traced to TaskAuctionMapper
    System.out.println(
              "Task ID: " + taskauct.getTaskid()+ ", "+
              "StartDate: "+ taskauct.getStartdate()+", "+
              "User ID: " + taskauct.getUserid());
         }

    Found the answer, I shouldn't use integers as parameters of column index in the result set, but instead use String to mark the fields :)

  • Oracle JDBC Drivers with Tomcat

    I try to connect to Oracle DB with the JDBC Drivers throught Tomcat JNDI access.
    I've tried with the oracle.jdbc.driver.OracleDriver and I have an UnsupportedOperationException when calling the getConnection() method on ma dataSource ref.
    So I've tried with the oracle.jdbc.pool.OracleConnectionPoolDataSource and I have an java.sql.SQLException:
    Cannot create JDBC driver of class
    'oracle.jdbc.pool.OracleConnectionPoolDataSource' for connect URL
    'jdbc:oracle:thin:@(description=(address=(host=meditws322)(protocol=tcp)(port=1521)
    )(connect_data=(sid=HABILLE)))'
    Please help I'm about to break down

    Thanks for your reply. I use Oracle JDBC driver. The XSQLConfig.xml was changed to have the following setting:
    <connection-manager>
    <factory>oracle.xml.xsql.XSQLOracleDatasourceConnectionManager</factory>
    </connection-manager>
    I'm using Tomcat 4.1.x and Apache Commons DBCP Datasources with org.apache.commons.dbcp.BasicDataSourceFactory. The configuration file does set driverClassName to oracle.jdbc.driver.OracleDriver. All other queries embedded in .xsql files work great, I only have issues with queries containing CURSOR() statements. If I switch back to built-in database connectivity, by changing XSQLConfig.xml and connection parameters in .xsql files everything is working again. When I attempt to use DataSources, I get things like this "oracle.jdbc.driver.OracleResultSetImpl@15780d9" instead of nested XML. The non-nested portion of XML looks fine also, so it is retrieving the data from the database properly. Please let me know if I can provide any additional information that could help in resolving this. Thanks in advance!
    -M-

  • Escape characters using Oracle JDBC

    We use Oracle JDBC driver to do some operations on an Oracle 9i database, and ran into some problems with escape characters. Basically we'd like to escape the _ and % characters.
    The following two example statements both work:
    ResultSet rs = stmt.executeQuery("select * from identifier_protein where upper(IDENTIFIER_ACCNO) like 'NM\\_%' escape '\\' ");
    ResultSet rs = stmt.executeQuery("select * from identifier_protein where upper(IDENTIFIER_ACCNO) like 'NM\\_%' {escape '\\' }");
    However, when we have multiple query terms and the "escape" clause doesn't immediately follows EACH "like" clause, we got errors saying the sql statement does not end properly. One such example is the following:
    ResultSet rs = stmt.executeQuery("select * from identifier_protein where upper(IDENTIFIER_ACCNO) like 'NM\\_%' and creator = 'ABC' {escape '\\'} ");
    If we put an "escape" clause following each "like" clause, then it works.
    My question is, is there a smart way of letting JDBC knows that you want to use an escape character everywhere in the query? We often do very complicated dynamic queries, frequently with table joins and boolean logic and subqueries with tons of query terms. Trying to add the escape clause to each "like" clause is very painful. Any help is highly appreciated. Thanks!
    BL

    I'd use PreparedStatements, if you're not already. Let the JDBC driver escape things properly for you. That's what the setString() and setDate() methods are all about.

  • Problem for using oracle xml parser v2 for 8.1.7

    My first posting was messed up. This is re-posting the same question.
    Problem for using oracle xml parser v2 for 8.1.7
    I have a sylesheet with
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">.
    It works fine if I refer this xsl file in xml file as follows:
    <?xml-stylesheet type="text/xsl" href="http://...../GN.xsl"?>.
    When I use this xsl in pl/sql package, I got
    ORA-20100: Error occurred while processing: XSL-1009: Attribute 'xsl:version' not found in 'xsl:stylesheet'.
    After I changed name space definition to
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> in xsl file, I got
    ORA-20100: Error occurred while processing: XSL-1019: Expected ']' instead of '$'.
    I am using xml parser v2 for 8.1.7
    Can anyone explain why it happens? What is the solution?
    Yi

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Steven Muench ([email protected]):
    Element's dont have text content, they [b]contain text node children.
    So instead of trying to setNodeValue() on the element, construct a Text node and use the appendChild method on the element to append the text node as a child of the element.<HR></BLOCKQUOTE>
    Steve,
    We are also creating an XML DOM from java and are having trouble getting the tags created as we want. When we use XMLText it creates the tag as <tagName/>value rather than <tagName>value</tagName>. We want separate open and close tags. Any ideas?
    Lori

  • Connection Problem using oracle.jdbc.xa.client.OracleXADataSource

    Unable to get a connection from connection pool Realm1tx
    Actually there are 5 connection intialized but no connection is there in active pool.Sometimes when I
    go to weblogic console and refresh the connection comes alive temporarily.Can anyone help me out for
    fixing this problem
    Driver Used:
    oracle.jdbc.xa.client.OracleXADataSource
    Error Message
    Unknown error occurred: XA error: XAER_RMERR : A resource manager error has occured in the transaction
    branch start() failed on resource 'realm1tx' null sql=[SELECT Person$1.id,NULL,Person$1.id,NULL,NULL
    FROM Person Person$1 WHERE (Per
    son$1.securityId = 'admin')] throttle=[-1]
    java.sql.SQLException: XA error: XAER_RMERR : A resource manager error has occured in the transaction
    branch start() failed on resource 'realm1tx' null
    Thanks in advance.
    Ragavendra.

    Which version of oracle thin driver are you using? Oracle 920 thin driver has some issues.
    Thanks,
    Mitesh
    Ragavendra wrote:
    Unable to get a connection from connection pool Realm1tx
    Actually there are 5 connection intialized but no connection is there in active pool.Sometimes when I
    go to weblogic console and refresh the connection comes alive temporarily.Can anyone help me out for
    fixing this problem
    Driver Used:
    oracle.jdbc.xa.client.OracleXADataSource
    Error Message
    Unknown error occurred: XA error: XAER_RMERR : A resource manager error has occured in the transaction
    branch start() failed on resource 'realm1tx' null sql=[SELECT Person$1.id,NULL,Person$1.id,NULL,NULL
    FROM Person Person$1 WHERE (Per
    son$1.securityId = 'admin')] throttle=[-1]
    java.sql.SQLException: XA error: XAER_RMERR : A resource manager error has occured in the transaction
    branch start() failed on resource 'realm1tx' null
    Thanks in advance.
    Ragavendra.

  • Can I use Oracle app server with mysql

    Can I use Oracle app server with mysql. I seem to have the following error when trying to create a datastore. I have mysql.jar in my classpath. Can any one tell me what's wrong.
    Error initializing data-source 'jdbc/topup': DriverManagerDataSource driver 'org.gjt.mm.mysql.Driver' not found

    Yes you can forward requests from your own apache to the iAS. This can be done using mod_proxy. Some hints about how to do this are availlable on this forum.
    mod_oc4j is not a standard apache module, and therefore is not availlable when you download apache. There is no apparent reason to use mod_oc4j on a "regular" webserver (unless you want to build your own iAS). Also there might be some licenseing issues with using mod_oc4j module on a standard apache.
    You can encrypt data that is passed from a random Apache to you iAS.

  • What is the best practice for using the Calendar control with the Dispatcher?

    It seems as if the Dispatcher is restricting access to the Query Builder (/bin/querybuilder.json) as a best practice regarding security.  However, the Calendar relies on this endpoint to build the events for the calendar.  On Author / Publish this works fine but once we place the Dispatcher in front, the Calendar no longer works.  We've noticed the same behavior on the Geometrixx site.
    What is the best practice for using the Calendar control with Dispatcher?
    Thanks in advance.
    Scott

    Not sure what exactly you are asking but Muse handles the different orientations nicely without having to do anything.
    Example: http://www.cariboowoodshop.com/wood-shop.html

  • Advantages and Disadvantages of Using Oracle 7 Client with Oracle 9 Server

    Hello,
    I was wondering what are the advanatges of using Oracle 7 client with Oracle 9 Server versus using Oracle 9 Client with Oracle 9 server.

    Some years ago I used 7.3 Client with 9i DB, and I don't remember of particular problems, but I'm speaking of Sql*Plus only. Are there specific problems ?
    Of course the best thing is to install one 9i Client (did you already do it ?) : if there are same problems, then that's not compatibility issue.
    And what are advantages of using 9 Client with 9 server other than 7 is no longer supported.You're sure you won't have compatibility problems.
    If you have access to Metalink have a look at [url http://metalink.oracle.com/metalink/plsql/ml2_documents.showFrameDocument?p_database_id=NOTE&p_id=207303.1]Note 207303.1

  • Using foreign JMS providers with wls

    does anybody have a clou, where i can find that article, i think it's
              by steve felts on using foreign JMS providers with wls? i think the
              link on dev2dev is broken?
              

    The new article is called "Using Foreign JMS Providers with WLS" and it's
              here:
              http://dev2dev.bea.com/resourcelibrary/whitepapers.jsp?highlight=whitepapers
              greg
              "leopld goess" <[email protected]> wrote in message
              news:[email protected]..
              > does anybody have a clou, where i can find that article, i think it's
              > by steve felts on using foreign JMS providers with wls? i think the
              > link on dev2dev is broken?
              

  • Connecting to OAS using Oracle JDBC Thin

    Hi,
    When I test connect to OAS residing on another host, using ORACLE JDBC THIN Driver and Named host method, I get the following error message :
    "Got back minus one from a read call"
    Any clues why such a message would come?
    Thks
    Sudha

    If you are using the thin driver, sqlnet.ora does not come into play. None of Oracle networking does. That is one of the great things about using the thin driver, no need to have the client installed.
    That error is due to incorrect connection info you are supplying or the machine you are connection from can't ping the machine it is trying to connect to.

  • Is it possible to use Oracle Forms 10g with Oracle 10g Lite Database?

    Hi All,
    We are in process of migrating our forms from 6i to 10g environment.
    We have two kinds of applications, one set run on general Oracle 11g database and the other set of forms run at the client machine using Oracle lite database.
    We dont have any problem with Forms 6i to connect to Lite database as it allows to connect through ODBC:DSN names. When we try to connect to a lite database (10gR3) from Forms 10g through ODBC/DSN, it's not allowing and throwing the below error.
    ORA-03121 : no interface driver connected - function not performed
    Can someone tell me if there is something wrong in our approach? Also advise how to use Oracle Lite database with Forms 10G.
    Sincerely,
    Praveen Manthena

    Hi,
    I have experience with 6i with lite database 10g. There are two version of lite database one is multi language support and other one in english. There lang problem in connectivity with multi language 10g lite database. I done connectivity with single language connectivity of 6i with 10g lite database. You should try this one with forms 10g.
    Regards,
    Naveed Ali

Maybe you are looking for

  • Please help me avoid twisting my head off trying to create a video of iphone screenshots that will play on an iphone

    I'm trying to create some job aid videos for a client. Some of these are going to be how to do things on their iphones. I've used the screencapture facility on my phone to snap a dozen or so screen caps. I've moved them to my PC I've buit a project (

  • Bug on jcaps 5.1.2?????

    Hi, when i try to map obr segment the designer logs this error (ide.log): Jul 28, 2009 10:44:52 AMjava.lang.NullPointerException Jul 28, 2009 10:44:52 AM at com.stc.editor.basicmapper.canvas.jgo.BasicCanvasController.handleDragEnter(BasicCanvasContro

  • Question for corlettk re StudentProcessor code

    Hey Keith, could you help me regarding this [post 23|http://forums.sun.com/thread.jspa?messageID=10719990#10719990] in "Initializing Global (?) Objects" to reiterate: pete wrote: corlettk wrote: If I recall correctly, I posted an implementation of th

  • Photo to use for Album

    The album image seems to be the first photo in the album. Is there a way to select a different picture? My albums are shared from iPhoto and are kept in order by title. I know I can use a title for the cover picture that will make it sort first, but

  • Updating cs6  error   happens more than once

    trying to update cs 6 this error code appears Extension Manager 6.0.4 Update Installation failed. Error Code: U44M1P7 happens more than once