Oracle Thin and IE4

Hi,
I have written an applet using Oracle Thin (classes111.zip and Oracle 7.3.4 and JDK 1.1.4).
I have my Oracle Server and my Web Server on the same machine.
Everything works fine with Netscape 4.7.
But with IE4 I have this message:
java.sql.SQLException: No suitable driver
java.lang.NullPointerException
Can anyone explain me what it means and what I have to do ?
Thanks a lot.
Ing. TOUSSET Olivier
null

Can you try registering the driver explicitly using DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver()). I think that there was some issue with Microsoft's VM that doing Class.forName() doesn't register the driver automatically. But I am not 100% sure.

Similar Messages

  • Porting oracle:thin to weblogic:oracle

    Hi everyone!
    Since pstmt.setAsciiSream or setBinaryStream doesn't seem to work for data larger than 4k while using oracle:thin I inserted Blobs or Clobs usually in the following way:
    Clob myClob = (Clob)resultSet.getObject("text");
    java.io.Writer CLOBout = ((oracle.sql.CLOB)myClob).getCharacterOutputStream();
    CLOBout.write(text);I had to port an application from Resin to Bea and had to switch to the Weblogic-Driver, and of course oracle.sql.CLOB doesn't exist there, so I tried again the 'simple' method using pstmt.setAsciiSream / pstmt.setBinaryStream.
    To my surprise it even worked with data>4k, while it still produced errors using Resin/Oracle:thin. Does anyone know the reason for that? Or does anyone have a working solution to write Clobs/Blobs for both drivers (Reading is no problem)?

    Yes, that would be possible. But I'd like to have the same code run on both Resin with Oracle:thin and Weblogic with the Weblogic driver ;-)
    This could be a solution:
    Clob myClob = (Clob)result.getObject("clob")
    Class[] argtypes = new Class[]{};
    java.lang.reflect.Method myClobMethod = myClob.getDeclaredMethod("getCharacterOutputStream",argtypes)
    // I am not sure if args simply can be null since getCharacterOutputStream doesn't take any parameters
    Object[] args = new Object[]{};
    java.io.Writer CLOBout = myClobMethod.invoke(myobject,args);I can't try until monday though, and (assuming it works) I wonder how performant it will be ;-)

  • Database connection encryption and integrity with ColdFusion and Oracle thin client

    As ColdFusion datasource we are using the Oracle thin client to  connect with the database. So, basically we are using a JDBC URL such as  jdbc:oracle:thin:@... and as Driver Class oracle.jdbc.OracleDriver. This works successfully however we would like to set encryption and  integrity parameters as well. In Java this is done similarly by setting a  Properties object prior to getting a connection as follows:
    Properties prop = new Properties();
    prop.put("oracle.net.encryption_client", "REQUIRED");
    prop.put("oracle.net.encryption_types_client", "( DES40 )");
    prop.put("oracle.net.crypto_checksum_client", "REQUESTED");
    prop.put("oracle.net.crypto_checksum_types_client", "( MD5 )");
    OracleDataSource ods = new OracleDataSource();
    ods.setProperties(prop);
    ods.setURL("jdbc:oracle:thin:@localhost:1521:main");
    Connection conn = ods.getConnection();
    Is there a way that I can pass these parameters to the ColdFusion  datasource. Ideally, I would love to do this centrally in such way that a  change to all the cfquery or cfstoredproc is not needed.
    I also know that in application servers such as Oracle AS there is an  option when creating a datasource which says "Add Properties". In there  you can add such properties. So, I was thinking of maybe creating a  JNDI DS in the app. server and then magically connecting to it but this  may have some impacts on the app.
    Besides this I was also thinking of communicating with the CF  datasource through the CF admin API (cfide.adminapi.administrator) and  also the option of extending the Oracle driver so that when CF connects  with it these params are already set.
    I would love to have your professional opinion and suggestions on this.

    I believe the thin driver actually needs the IP address (not the DNS name). Also, is "java" the name of the Oracle instance to which you are trying to connect?
    Try the following:String driver = "jdbc:oracle:thin";
    String dbIP = "W2RZ1NXG01's IP address";
    String dbPort = "1530";
    String dbSid = "java";
    String dbUser = "Admin";
    String dbPswd = "apassword";
    String cnctStr = driver + ":@" + dbIP + ":" + port + ":" + dbSid;
    try
        Class.forName("oracle.jdbc.driver.OracleDriver");
        con = DriverManager.getConnection( cnctStr, dbUser, dbPswd );
        stmt = con.createStatement();
        stmt.executeUpdate(createString);
        stmt.close();
        con.close();
    catch(SQLException ex)
        System.err.println( "The following SQLException occurred: " + ex );
        System.err.println( "Message: " + ex.getMessage() );

  • Differences between Oracle JDBC Thin and Thick Drivers

    If any body is looking for this information...
    ============================================================
    I have a question concerning the Oracle JDBC thin vs. thick drivers
    and how they might affect operations from an application perspective.
    We're in a Solais 8/Oracle 8.1.7.2 environment. We have several
    applications on several servers connecting to the Oracle database.
    For redundancy, we're looking into setting up TAF (transparent
    application failover). Currently, some of our apps use the Oracle
    <B>JDBC thin</B> drivers to talk to the database, with a connection
    string that like this:
    <B> jdbc:oracle:thin:@host:port:ORACLE_SID </B>
    In a disaster recovery mode, where we would switch the database
    from one server to another, the host name in the above string
    would become invalid. That means we have to shut down our application
    servers and restart them with an updated string.
    Using the Oracle <B>OCI (thick)</B> driver though, allows us to connect
    to a Net8 service instead of a specific server:
    <B> jdbc:oracle:oci8:@NET8_SERVICE_NAME </B>
    Coupled with the FAILOVER=ON option configured in Net8, it is
    then possible to direct a connection from the first server to
    the failover database on another server. This is exactly what
    we would like to do.
    My question is, from an application perspective, how is the Oracle
    thick driver different from the thin driver? If everything
    else is "equal" (i.e. the thick driver is compatible with the
    app servers) would there be something within the the thick/OCI
    driver that could limit functionality vs. the thin driver?
    My understand, which obviously is sketchy, is that the thick
    driver is a superset of the thin driver. If this is the case,
    and for example if all database connections were handled through
    a configuration file with the above OCI connection string, then
    theoretically the thick driver should work.
    ============================================================
    <B>
    In the case with the Oracle, they provide a thin driver that is a 100% Java driver for client-side use without the need of an Oracle installation (maybe that's why we need to input server name and port number of the database server). This is platform indipendent, and has good performance and some features.
    The OCI driver on the other hand is not java, require Oracle installation, platform dependent, performance is faster, and has a complete list of all the features.
    </B>
    ========================================================
    I hope this is what you expect.
    JDBC OCI client-side driver: This is a JDBC Type 2 driver that uses Java native methods to call entrypoints in an underlying C library. That C library, called OCI (Oracle Call Interface), interacts with an Oracle database. <B>The JDBC OCI driver requires an Oracle (7.3.4 or above) client installation (including SQL*Net v2.3 or above) and all other dependent files.</B> The use of native methods makes the JDBC OCI driver platform specific. Oracle supports Solaris, Windows, and many other platforms. This means that the Oracle JDBC OCI driver is not appropriate for Java applets, because it depends on a C library to be preinstalled.
    JDBC Thin client-side driver: This is a JDBC Type 4 driver that uses Java to connect directly to Oracle. It emulates Oracle's SQL*Net Net8 and TTC adapters using its own TCP/IP based Java socket implementation. <B>The JDBC Thin driver does not require Oracle client software to be installed, but does require the server to be configured with a TCP/IP listener. Because it is written entirely in Java, this driver is platform-independent.</B> The JDBC Thin driver can be downloaded into any browser as part of a Java application. (Note that if running in a client browser, that browser must allow the applet to open a Java socket connection back to the server.
    JDBC Thin server-side driver: This is another JDBC Type 4 driver that uses Java to connect directly to Oracle. This driver is used internally by the JServer within the Oracle server. This driver offers the same functionality as the client-side JDBC Thin driver (above), but runs inside an Oracle database and is used to access remote databases. Because it is written entirely in Java, this driver is platform-independent. There is no difference in your code between using the Thin driver from a client application or from inside a server.
    ======================================================
    How does one connect with the JDBC Thin Driver?
    The the JDBC thin driver provides the only way to access Oracle from the Web (applets). It is smaller and faster than the OCI drivers, and doesn't require a pre-installed version of the JDBC drivers.
    import java.sql.*;
    class dbAccess {
    public static void main (String args []) throws SQLException
    DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver());
    Connection conn = DriverManager.getConnection
    ("jdbc:oracle:thin:@qit-uq-cbiw:1526:orcl", "scott", "tiger");
    // @machineName:port:SID, userid, password
    Statement stmt = conn.createStatement();
    ResultSet rset = stmt.executeQuery("select BANNER from SYS.V_$VERSION");
    while (rset.next())
    System.out.println (rset.getString(1)); // Print col 1
    stmt.close();
    How does one connect with the JDBC OCI Driver?
    One must have Net8 (SQL*Net) installed and working before attempting to use one of the OCI drivers.
    import java.sql.*;
    class dbAccess {
    public static void main (String args []) throws SQLException
    try {
    Class.forName ("oracle.jdbc.driver.OracleDriver");
    } catch (ClassNotFoundException e) {
    e.printStackTrace();
    Connection conn = DriverManager.getConnection
    ("jdbc:oracle:oci8:@qit-uq-cbiw_orcl", "scott", "tiger");
    // or oci7 @TNSNames_Entry, userid, password
    Statement stmt = conn.createStatement();
    ResultSet rset = stmt.executeQuery("select BANNER from SYS.V_$VERSION");
    while (rset.next())
    System.out.println (rset.getString(1)); // Print col 1
    stmt.close();
    =================================================================

    Wow, not sure what your question was, but there sure was a lot of information there...
    There really is only one case where failover occurs, and it would not normally be in a disaster recovery situation, where you define disaster recovery as the obliteration of your current server farm, network and concievably the operational support staff. This would require a rebuild of your server, network etc and isn't something done with software.
    Fail over is normally used for high availablity that would take over in case of hardware server failure, or when your support staff wants to do maintenance on the primary server.
    Using the thin and thick driver should have ZERO affect on a failover. Transparent failover will make the secondary server the same IP as the primary, therefore the hostname will still point to the appropriate server. If you are doing this wrong, then you will have to point all your applications to a new IP address. This should be something that you tell your management is UNACCEPTABLE in a fail-over situation, since it is almost sure to fail to fail-over.
    You point out that you are providing the TNSNAME, rather than the HOSTNAME when using the thick driver. That's true within your application, but that name is resolved to either a HOSTNAME, or IP ADDRESS before it is sent to the appropriate Oracle server/instance. It is resolved using either a NAME server (same as DNS server but for Oracle), or by looking at a TNSNAMES file. Since the TNSNAMES files profilerate like rabbits within an organization you don't want a fail over that will make you find and switch all the entries, so you must come up with a fail over that does not require it.
    So, the application should not be concerned with either the hostname, or the IP address changing during fail over. That makes use of the thin or thick client acceptable for fail over.
    Don't know if this will help, but this shows the communication points.
    THIN DRIVER
    client --> dns --> server/port --> SID
    THICK DRIVER
    client --> names server --> dns --> server/port --> SID
    client --> tnsnames     --> dns --> server/port --> SID

  • Oci8 and oracle thin

    I am using developer 3.0 on the NT server machine, with oracle 8
    First of all when i start my computer one error message raise that is "one of your service is not running please check the event log". I saw the event log that service is oraclestartorc1. who can i start this service. the other oraclelistener service is also give error message in starting.
    so next thing is when i click on the connection UI to make a new connection. I click on the oracle oci8 and use localhost = 127.0.0.1 and protocol = TCP and SID = orcl then error message comes that "ocijdbc8 is not in share path" who can i remove this problem also. I also use BEQ protocol to connect but the error message is same. When i use oracle thin driver then it raise message "could not establish the connection with adapter". Who can i remove this also. when i use the jdbc-odbc bridge it success the connection in test. But it does not show in connection. Who can i get driver for oci8, oci7 or for thin. Simply i want to connect my computer local database. my oracle directory is "orant" please help me thanks..
    null

    Jawada,
    Try the following:
    1. Make sure your ORACLE_HOME directory is in your PATH (JDeveloper needs this so it can find the OCI driver's client-side DLL).
    2. Make sure you have an alias set up for your database in your TNSNAMES.ORA file (usually located in ORACLE_HOME\network\admin). I believe previous posts to your other questions provided instructions for this.
    3. Within JDeveloper, select Tools | IDE Options... from the menu. Choose the Environment Tab, and in the Oracle Home section, choose the name of your Oracle Home or choose Default Home from the Select an Oracle Home list. (this isn't really required unless you have multiple Oracle Home's installed on your machine).
    4. When creating your connection within JDeveloper:
    a. Choose Oracle JDBC OCI-8 from the Select a JDBC Driver list.
    b. Choose Existing TNS Names from the Select a Connection Method list.
    c. Choose the alias for your database from the TNS Service list (this list will not appear until you choose Existing TNS Names from the Connection Method list.
    null

  • CachedRowSet problem in Weblogic 6.1 and Oracle thin driver 9.0.1

    Has anyone used the CachedRowSet class successfully? (this classes are
    new and from the JDBC extension pack)
    I am experiencing "Not in a transaction" errors when executing
    cachedrowset.populate(resultset), even though I'm inside a correct
    ut.begin and ut.commit transaction.
    Note I don't have these problems when I don't use the CachedRowSet
    classes.
    If I remove the setFetchSize(50) line, then I receive the ORA-01002:
    fetch out of sequence error, which is discussed in another post on
    this newsgroup.
    I don't have any of these problems at all, if I use the Oracle Thin
    Driver directly (i.e. not using Weblogic 6.1).
    -H
    Example of code:
    stmt = getConnection().createStatement();
    stmt.setFetchSize(50);
    stmt.executeQuery("SELECT * FROM ASSET");
    rs = stmt.getResultSet();
    crs = new CachedRowSet();
    crs.populate(rs);

    Hi Arturo,
    What kind of a problem do you have? Any stacktraces?
    Regards,
    Slava Imeshev
    "Arturo Fernandez" <[email protected]> wrote in message
    news:[email protected]..
    Hi! I have a problem with CLOB column in Oracle 8.1.7. My enviroment
    is:
    Windows 2000, BEA WLS 6.1 and Oracle 8.1.7. I'm trying to use
    'classes12.zip' provided by Oracle. I added 'classes12.zip' to
    CLASSPATH after than 'weblogic.jar' in my startup server script, but
    it fails when trying to retrieve a CLOB data from database. Script
    includes:
    setCLASSPATH=.\classes12_01.zip;.;.\lib\weblogic_sp.jar;.\lib\weblogic.jar;
    >
    But this driver and the code runs sucessfully with the same database
    and weblogic 5.1. I'm interesting in use this driver and this code
    because i'm trying to migrate two applications from WLS 5.1 to WLS 6.1
    I cannot find a solution.
    Can everybody help me, please? It's urgent for me...

  • XAER_RMERR with oracle thin 9.0.1.4 and wls 6.1 sp3

    I am trying to use Oracle Thin 9.0.1.4 Driver in a distributed Transaction and
    while trying to call connection.createStatement() I am getting the
    following error.
    RootCause=[java.sql.SQLException: XA error: XAER_RMERR : A resource
    manager error has occured in the transaction branch start() failed on
    resource 'CoreJDBCPool' null]
    We are using WLS 6.1SP3
    Any help on the issue will be really appreciated
    here's the simple test that causes this error
    <%@ page isErrorPage="false" errorPage="/common/error.jsp" %>
    <%@ page import="javax.sql.DataSource" %>
    <%@ page import="java.sql.Connection" %>
    <%@ page import="java.sql.Statement" %>
    <%@ page import="javax.naming.InitialContext" %>
    <%@ page import="javax.transaction.UserTransaction" %>
    <html>
    <body>
    Testing update
    <p> </p>
    <%
    Statement stmt = null;;
    Connection conn = null;
    UserTransaction ut = null;
    try {
    InitialContext ctx = new InitialContext();
    // TODO: add the JNDI name for the datasource here
    // get the datasource from the app
    DataSource ds = (DataSource)ctx.lookup("jdbc/TrueResolutionDB");
    ut =(UserTransaction) ctx.lookup("java:comp/UserTransaction");
    ut.begin();
    if (ds != null){
    // Get a connection to the database
    conn = ds.getConnection();
    // Get a statement from the connection
    stmt = conn.createStatement();
    // Execute the Update
    int rows = stmt.executeUpdate( "update csr_submission set
    userid='wilaw' where submissionseq=436");
    // Print how many rows were modified
    out.println( rows + " Rows modified" ) ;
    ut.commit();
    } else {
    out.println("datasource is null");
    catch( Exception e ){
    if (ut != null)
    ut.rollback();
    out.println(e.toString()) ;
    e.printStackTrace();
    // Close the statement and the connection
    if (stmt != null)
    stmt.close() ;
    if (conn != null)
    conn.close() ;
    %>

    Hi Bala,
    Here is what I remembered - I saw this error when a part of the network
    connecting weblogic to oracle was misconfigured, so throughput dropped
    from 100Mbit/s to somewhat 64Kbit-sec.
    When weblogic message level was set to warning, it was showing lots
    of pool's connection refreshes. In my case this error was appearing
    after some time. The source of the error is that when a weblogic XA
    resource is inactive for 2 minutes, the server delists it and everything
    goes south. The workaround for this is to have refresh period a bit less
    than 2 minutes, or, better, have an operating network infrastructure :)
    As for the settings you provided - they are not optimal. The better
    configuration would look like this:
    <JDBCConnectionPool
    CapacityIncrement="0" <!-- We don't need it as we have fixed-size
    pool -->
    ConnLeakProfilingEnabled="false" <!-- This setting is needed only if you
    use profiling API. If it's set to true, it's very heavy on IO -->
    DriverName="oracle.jdbc.driver.OracleDriver"
    InitialCapacity="40" <!-- Set it to max so that pool is populated
    upfront -->
    LoginDelaySeconds="1"
    MaxCapacity="40"
    Name="nonXACoreJDBCPool"
    Properties="oracle.jdbc.V8Compatible=true;user=bala;password=bala;dll=ocijdb
    c9;protocol=thin"
    RefreshMinutes="99999" <!-- We don't need refresh -->
    Targets="TrueResolutionServer"
    TestTableName="CSR_Submission"
    URL="jdbc:oracle:thin:@yoshi:1521:hestia"
    <!-- Added -->
    TestConnectionsOnReserve="true" <!-- We need to make sure that we have
    valid connection at reserve -->
    TestTableName="DUAL" <!-- always available and emply oracle table for
    testing -->
    ShrinkingEnabled="false" <!-- This is a fixed size pool -->
    />
    These settings will give you maximum performance from the pool.
    Hope this helps.
    Regards,
    Slava
    "Bala" <[email protected]> wrote in message
    news:[email protected]...
    >
    Hi Slava,
    I was hoping for a response from someone like you - I saw you had similarerrors
    but did not see the solution :-). In any case, here's my connection pooland datasource
    information.
    <JDBCTxDataSource EnableTwoPhaseCommit="true"JNDIName="jdbc/TrueResolutionDB"
    Name="CoreDataSource" PoolName="CorePool" StreamChunkSize="8192"Targets="TrueResolutionServer"
    />
    <JDBCConnectionPool CapacityIncrement="5" ConnLeakProfilingEnabled="true"DriverName="oracle.jdbc.driver.OracleDriver"
    InitialCapacity="10" LoginDelaySeconds="1" MaxCapacity="40"Name="nonXACoreJDBCPool"
    >
    Properties="oracle.jdbc.V8Compatible=true;user=bala;password=bala;dll=ocijdb
    c9;protocol=thin"
    RefreshMinutes="10" Targets="TrueResolutionServer"TestTableName="CSR_Submission"
    URL="jdbc:oracle:thin:@yoshi:1521:hestia" />
    as you can see from the entry below the number of execute threads isreasonable
    >
    <ExecuteQueue Name="default" ThreadCount="15" ThreadPriority="10" />
    "Slava Imeshev" <[email protected]> wrote:
    Hi Bala.
    I remember I had the same problem. Trying to recollect how I fixed it...
    Meanwhile, can you post your connection pool and datasource
    definitions from your config.xml?
    Regards,
    Slava Imeshev
    "Bala" <[email protected]> wrote in message
    news:[email protected]...
    I do have the oracle thin driver in the classpath. the failure thatI see
    is sporadic
    - this makes it worse than a predictable failure. The ThreadCountparameter in
    config.xml is set to 15 and the min and max capacity of the
    ConnectionPool
    is
    set to 25 and 40 respectively (high enough, I would think).
    Is Oracle Thin 9.0.1.4 Driver in the Classpath variable?
    Get Oracle Thin 9.0.1.4 Driver from
    http://otn.oracle.com/software/tech/java/sqlj_jdbc/content.html
    "Bala" <[email protected]> wrote:
    I am trying to use Oracle Thin 9.0.1.4 Driver in a distributed
    Transaction
    and
    while trying to call connection.createStatement() I am getting the
    following error.
    RootCause=[java.sql.SQLException: XA error: XAER_RMERR : A resource
    manager error has occured in the transaction branch start() failedon> >> >>resource 'CoreJDBCPool' null
    We are using WLS 6.1SP3
    Any help on the issue will be really appreciated
    here's the simple test that causes this error
    <%@ page isErrorPage="false" errorPage="/common/error.jsp" %>
    <%@ page import="javax.sql.DataSource" %>
    <%@ page import="java.sql.Connection" %>
    <%@ page import="java.sql.Statement" %>
    <%@ page import="javax.naming.InitialContext" %>
    <%@ page import="javax.transaction.UserTransaction" %>
    <html>
    <body>
    Testing update
    <p> </p>
    <%
    Statement stmt = null;;
    Connection conn = null;
    UserTransaction ut = null;
    try {
    InitialContext ctx = new InitialContext();
    // TODO: add the JNDI name for the datasource here
    // get the datasource from the app
    DataSource ds = (DataSource)ctx.lookup("jdbc/TrueResolutionDB");
    ut =(UserTransaction) ctx.lookup("java:comp/UserTransaction");
    ut.begin();
    if (ds != null){
    // Get a connection to the database
    conn = ds.getConnection();
    // Get a statement from the connection
    stmt = conn.createStatement();
    // Execute the Update
    int rows = stmt.executeUpdate( "update csr_submission set
    userid='wilaw' where submissionseq=436");
    // Print how many rows were modified
    out.println( rows + " Rows modified" ) ;
    ut.commit();
    } else {
    out.println("datasource is null");
    catch( Exception e ){
    if (ut != null)
    ut.rollback();
    out.println(e.toString()) ;
    e.printStackTrace();
    // Close the statement and the connection
    if (stmt != null)
    stmt.close() ;
    if (conn != null)
    conn.close() ;
    %>

  • Dbping errors with Oracle8.1.5 and Oracle thin driver

    I am trying to connect to Oracle 8.1.5.0.0 with Oracle thin driver 8.1.5. However I keep getting error ORA-24327. Any suggestions on how to fix this error?

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Jayanta Ghosh ([email protected]):
    Hi,
    Does XML parser for PL/SQL work with Oracle 8.1.5? Did any one install the
    same and if so what are steps to follow? I ran initjvm.sql to install
    JServer and then tried to load jar files using loadjava, but it's giving
    error. It's working fine with Oracle8.1.6.
    Any idea?
    Thanks,
    Jayanta<HR></BLOCKQUOTE>
    Oracle XML Parser has differents distributions for 8.1.5 and 8.1.6 databases, try the correct version, then runs the oraclexmlsqlload.csh from the lib directory of XSU distribution.
    Best regards, Marcelo.
    null

  • Hung queries, and Oracle thin driver query timeout implementation

    We are seeing occasional instances of stuck threads, where the code is in Oracle thin XA driver code waiting for a socket read for a response from the database. Usually only one thread at a time. The connection never terminates and we have to shut down WebLogic to clear it. The DBAs tell us that all connections to the 11g RAC cluster members from our hosts are idle, with no hung or long-running transactions.
    This happens every few days across two WebLogic 10.3.5 clustered instances in our QA environment, usually not the same time on two servers (one had four incidents, the other had only one, in the last 15 or so days). Sometimes it has resulted in a hung server, as the driver is holding a lock that blocks other threads (today we had numerous threads block in a TX rollback).
    I'm guessing our WebLogic instance somehow is not getting the connection close from the remote host. BTW, there is no firewall between us and the DB. I have not got any strong suspect for the cause (although we are running Linux on a VMWare 4.0 VM, which always worries me).
    Ordinarily I'd either ask the application to set a query timeout, or set the query timeout parameter for the connection pools as a workaround (we are using a MultiDatasource), so the transaction would at least abort and the application can handle it. However, while the Oracle driver does support java.sql.Statement.setQueryTimeout(), some brief investigation on my part leads me to believe the timeout is implemented on the server side and not the client side - so that if it is indeed the case that WebLogic does not see the close on the connection, it also would never see the timeout.
    Two questions:
    1. Is my suspicion about server-side implementation of timeout for Oracle 11g correct?
    2. If so, is there some property I can set for the driver that will implement a socket timeout? Is this "safe"?
    Thanks for any help!
    [ Oracle WebLogic 10.3.5, HotSpot 64 bit JVM 1.6.0_29 on RHEL 5.6 on VMWare; Oracle Thin XA driver bundled with WebLogic; Oracle RAC 11g (three-node cluster)]
    Edited by: SteveElkind on Dec 3, 2012 5:25 AM

    Thanks, Joe.
    My investigations were heading in this direction (e.g., http://docs.oracle.com/cd/B28359_01/java.111/b31224/apxtblsh.htm#CHDBBDDA). However, for WebLogic, is it as simple as adding the following property in the Datasource Connection properties edit box in the WebLogic console?
    oracle.net.READ_TIMEOUT=300000
    or do I have to edit the connection URL?
    I've tried this, and the Datasource restarts OK after the change, but I have no way right now to check whether it actually "works".
    (we have some long-running queries; five minutes seems to be a "safe" limita for now)

  • Method getCustomDatum() and Oracle thin client

    Hello All,
    I am using WL6.1 and an Oracle thin driver. I am using the Oracle Intermedia classes
    for Java in order to retrieve images for jsps and servlets.
    Trying to use the Oracle classes caused class cast exceptions. When using the
    weblogic.jdbc.vendor.oracle.OracleResultSet, I got the error
    "java.sql.SQLException: getCustomDatum is not supported by the Weblogic JDBC Driver".
    I was wondering if anyone else has run into this problem? Any help would be greatly
    appreciated.
    Thanks,
    Rich

    Slava,
    Thank you for your help.
    - Richard
    "Slava Imeshev" <[email protected]> wrote:
    Hi Richard,
    "Richard Dedeyan" <[email protected]> wrote in message
    news:3d2638f5
    Do you mean that I need to get to get a connection directly to thedatabase using
    the Thin driver instead of getting the connection via the pool?Yes, this is the first option. Note that with using thin driver directly
    you loose all advantages of using weblogic JDBC subsystem like
    transactions, connection pooling and caching of prepeared statements.
    I'd go with a stored procedure.
    Regards,
    Slava Imeshev
    Thanks for your help.
    - Richard
    "Slava Imeshev" <[email protected]> wrote:
    Hi Richard,
    This feature is not supported by weblogic because
    oracle Datum is not serializable. In case you have a
    strict requirement, you will need to switch to using
    oracle thin driver directly. You could also consider
    moving processing to stored procedure.
    Regards,
    Slava Imeshev
    "Richard Dedeyan" <[email protected]> wrote in message
    news:3d260294$[email protected]..
    Hello All,
    I am using WL6.1 and an Oracle thin driver. I am using the OracleIntermedia classes
    for Java in order to retrieve images for jsps and servlets.
    Trying to use the Oracle classes caused class cast exceptions. Whenusing the
    weblogic.jdbc.vendor.oracle.OracleResultSet, I got the error
    "java.sql.SQLException: getCustomDatum is not supported by the
    Weblogic
    JDBC Driver".
    I was wondering if anyone else has run into this problem? Any helpwould be greatly
    appreciated.
    Thanks,
    Rich

  • Able to make dirty read using Oracle 9i and JDBC thin driver v 9.2.0

    I've searched this forum and did not see anything to directly answer my question.
    I checked the Oracle JDBC Frequently Asked Questions...
    ditto (perhaps due to the fact that it was last updated: 22 June 2001).
    So here is my question, and thank you in advance for any insight (apologies if I have missed finding an already answered question):
    Section 19-15 of:
    "JDBC Developer’s Guide and Reference"
    (which is for Oracle 9i database)
    downloadable from:
    http://download-east.oracle.com/docs/cd/B10501_01/java.920/a96654.pdf
    is entitled:
    "Transaction Isolation Levels and Access Modes"
    The section seems to indicate that
    if JDBC connection A is setup with:
    setAutoCommit(false)
    setTransactionIsolation(Connection.TRANSACTION_READ_COMMITTED)
    and then used to perform an update on a row (no commit(), rollback(), or close() yet) ...
    then JDBC connection B (setup in the same way) will be prevented from
    making a dirty read of that same row.
    While this behavior (row-level locking) occurs correctly when using MS SQL Server 2000,
    it is not occuring correctly with Oracle 9i and the Oracle Thin JDBC driver version 9.2.0.
    The test case I have shows that with Oracle, connection B is able to make a dirty read
    successfully in this case.
    Am I doing something wrong here ?
    Again, MS SQL Server correctly blocks connection B from making the Read until Connection A
    has been either committed, rolled back, or closed, at which time connection B is able to
    complete the read because the row is now unlocked.
    Is there a switch I must throw here ?
    Again, any help is greatly appreciated.

    Thanks for the response.
    I understand what you are saying...
    that readers don't block writers in Oracle (the same is true in SQL Server 2000).
    However, I don't see how my test case is working correctly with Oracle (the exact same code acting as I'm thinking it should with SQL Server, but I still think it is acting incorrectly with Oracle).
    I have transaction A do this:
    update <table> set <column2>=<value> where <column1>='1'
    then I use Thread.sleep() to make that program hang around for a few minutes.
    Meanwhile I sneak off and start another program which begins transaction B. I have transaction B do this:
    select * from <table> where <column1>='1'
    and the read works immediately (no blocking... just as you have said) however, transaction A is still sleeping, it has not called commit() or rollback() yet.
    So what if transaction A were to call rollback(), the value read by transaction B would be incorrect wouldn't it ?
    Both A and B use setAutoCommit(false) to start their transactions, and then call setTransactionIsolation(Connection.TRANSACTION_READ_COMMITTED).
    Isn't that supposed to guarantee that a reader can only read what is committed ?
    And if a row is in "flux"... in the process of having one or more values changed, then the database cannot say what the value will be ?
    I can almost see what you are saying.
    In letting the reader have what it wants without making it wait, I suppose it could be said that Oracle is holding true to the "only let committed data be read"
    So if that's it, then what if I want the blocking ?
    I want an entire row to be locked until whoever it in the middle of updating, adding, or removing it has finished.
    Do you know if that can be done with Oracle ? And how ?
    Thanks again for helping me.

  • Jdbc connection using oracle thin driver( using jdk1.4 and oracle8 )

    hello ..
    while i was tring to connection using oracle thin driver and jdk1.4 am getting the below error message. i have set the class path for the driver also. am using oracle8 personal edition and jdk1.4.
    [java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
            at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
            at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
            at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:333)
            at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:404)
            at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.ja
    va:468)
            at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:314)
            at java.sql.DriverManager.getConnection(DriverManager.java:512)
            at java.sql.DriverManager.getConnection(DriverManager.java:171)
            at Connexa.main(Connexa.java:18)[/b]
    Press any key to continue...
    my program is....
    import java.sql.*;                                          
    import java.io.*;
    import java.util.*;
    import oracle.jdbc.driver.*;
    // needed for new BFILE class
    import oracle.sql.*;
       public class Connexa {
      public static void main (String args []) throws Exception {
            Statement stmt=null; 
      try{
        // Load the Oracle JDBC driver                            
        //DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    Class.forName("oracle.jdbc.driver.OracleDriver");
        // Connect to the database
        // You can put a database name after the @ sign in the connection URL.
    Connection conn =
    DriverManager.getConnection("jdbc:oracle:thin:@127.0.0.1:1521:orcl","scott","tiger");
        //Connection conn =
        //  DriverManager.getConnection ("jdbc:odbc:datasource", "system", "manager");
        stmt = conn.createStatement ();
    catch (SQLException e)
          e.printStackTrace();

    The code itself is fine; the problem is with one of:
    1) the connection URL
    2) intermediate networking
    3) the database itself
    1) your connection URL is "jdbc:oracle:thin:@127.0.0.1:1521:orcl"
    - is Oracle really running on the default port, 1521
    - is the installation SID really "orcl"
    2) lots of possibilities, but only a couple are likely
    - is TCP/IP configured and running on your host
    - is there a persoanl firewall rpduct running? perhaps it's blocking the connection
    3) Is Oracle running?
    Is the listener running?

  • How to configure oracle thin drivers for SUN APPLICATION SERVER

    hi all,
    I am working with EJB with oracle as back-end. I wants to know how to configure oracle thin drivers for the SUN APPLICATION SERVER. Please explain me breifly.
    Advanced thanks to all the replies.
    with regards,
    /kumaraswamy.n

    Kumaraswamy,
    Did you try searching the Internet? Here are the results of my Internet search:
    http://tinyurl.com/zo4gk
    And one of the first hits in the list was this:
    Deploying to a Sun Java System Application Server
    Good Luck,
    Avi.

  • Any ideas on a MS Jet Access Error on Oracle Thin Driver?

    I am getting the following error when attempting to connect to an Oracle 8i database on a UNIX server from a servlet on an NT server using Jrun:
    Error
    java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] The Microsoft Jet database engine cannot find the input table or query 'EMPLOYEE'. Make sure it exists and that its name is spelled correctly.
    Where could this come from since I am importing the Oracle classes and have the JRun and system classpath set to where classes12.jar is located. There are no ODBC DSN settings for this DB on the server.
    I am using this syntax to get the connection:
    Class.forName("oracle.jdbc.driver.OracleDriver");
    conn = DriverManager.getConnection(
    "jdbc:oracle:thin:@10.20.10.112:1521:databasename",
    "username",
    "password");

    it seems like the connection is being made successfully, otherwise you would get a different error.
    Maybe your SQL has to be case sensitive in relation to the tablename??

  • Error in creating Connection Pool using Oracle Thin Driver

    Hi,
    I am trying to create a connection pool in WS 5.1 with sp #6 using Oracle Thin Driver (oracle.jdbc.driver.OracleDriver) on a Sun box. But I am able to create the pool using weblogic.jdbc.oci.Driver. I get an DBMS Driver exception when I use thin driver. I have LD library path and weblogic class path set correctly. WL shows the following exception :
    weblogic.common.ResourceException: weblogic.common.ResourceException:
    Could not create pool connection. The DBMS driver exception was:
    java.sql.SQLException: Io exception: The Network Adapter could not establish the
    connection
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java)
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java)
    at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java)
    at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java)
    at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java)
    Any help on this is greatly appreciated.
    Thanks,
    Ramu

    Hi Ramu,
    Please post your connection pool setting here. You might have missed some
    port/server info. The driver is unable to connect to the db server here.
    sree
    "Ramu" <[email protected]> wrote in message
    news:3d5bbc3a$[email protected]..
    >
    Yes. I am trying to create a connection pool in weblogic and I have theweblogic
    class path setup correctly. It points to classes111.zip andnls_charset11.zip.
    >
    -Ramu
    "Neo Gigs" <[email protected]> wrote:
    Did you setup the JDBC library classpath correctly?
    For me, e.g. Oracle 7.3.4, the classpath should be:
    export CLASSPATH = /oracle7.3.4/jdbc/lib/classes.zip:%CLASSPATH%
    Noted that the JDBC classpath must be the first classpath element in
    the export
    statement.
    Neo

Maybe you are looking for

  • ACS 5.3 View Database Backup hanging

    In ACS 5.3 .0.40 the backup of the view database stopped working. There seems that a backup stucked in progress. Incremental backup is configured, I cannot edit the configuration in "Monitoring Configuration -> Data management -> Removal and Backup"

  • How to reduce illustrator CS4 file size

    Hi, How to reduce illustrator CS4 file size, the file size is alots bigger compare to art work done in indesign?

  • Adobe reader 11 ne répond plus !

    Lorsque je me déplace dans un fichier pdf adobe reader 11 ne répond plus. Tandis qu'avec adobe reader 9 je n'ai pas de problème. Es-ce que les futures versions d'adobe reader vont être compatible avec adobe reader 9? À noter, mon système est windows

  • Linux: flash 10.2 and crystalhd dropping frames @1080p

    I'm testing through the adobe stage demo video page the performance of the new plugin using a CrystalHD minipci-e card under linux. It works somewhat ok @ 720p, as I can see 25fps in the video info window and no dropped frames. CPU usage is 20% in a

  • BI dashboard failure

    Hi, I just installed BI EE, and logged in as Administrator. The dashboard returned failure after searching for a miniute. See the message below. ==============BEGINNING of MESSAGE========================= Odbc driver returned an error (SQLExecDirectW