Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: SQL Exception with Oracle Thin JDBC drivers

Re: SQL Exception with Oracle Thin JDBC drivers

From: <kbee_at_my-dejanews.com>
Date: 1998/09/21
Message-ID: <6u6l3b$168$1@nnrp1.dejanews.com>#1/1

In article <35e2a6ee.97189451_at_news>,
  roba_at_ita.cph.dk (R. Maitland Baxter) wrote:
> hi,
> i think i can help with at least one of your errors. About a week
> ago I was having a similar problem getting "No more data to read from
> socket", very frustrating. I got in contact with someone at Oracle
> support (not the easiest thing in the world to do). What I had
> discovered was that the Oracle "keep alive" connection check signal
> kills the JDBC connection every time. There should be a file called
> sqlnet.ora somewhere on the Oracle server. It has a line
> SQLNET_EXPIRE_TIME = X where X is a value in minutes. I'd be willing
> to bet that you recieve that SQL exception exactly every X minutes.
> There are 3 possible solutions, I'll list them in order of least to
> most desirable (in my opinion).'
>
> 1) Remove, the SQLNET_EXPIRE_TIME = X from your .ora file. If this is
> acceptable to your DBA, it will correct the problem.
>
> 2) Where you catch the SQLException, check if the message is "no more
> data", if so just reconnect and try the query again. Ugly but it
> works.
>
> 3) This is a known bug for Oracle. It is fixed in the 8.0.4.0.6
> version of the JDBC thin driver. Unfortunately the latest available on
> their website is 8.0.4.0.5. I have used the new version and it works
> great (at least on NT). If you promise not to ask me where I got it, I
> can send you the zip file for the latest driver. I was told it is a
> production version but for some reason is not yet publically
> available. Regardless, I would bet that you will be able to get it
> form Oracle in the next couple of weeks.
>
> hope this helps!
> ____________________________________
> "That was good . . . but not great." - Homer J. Simpson
>
>

I have gotten the 8.0.4.0.6 upgrade and now I receive a different error, shown below. Any insight?

This occurs when initializing a callable statement, just after establishing the database connections. The error occurs with JDK 1.1.3 on HP-UX 10.20. Below the stack trace is the code which calls OracleCallableStatement#registerOutParameter.

Thanks for any suggestions,
Ken Bannister

xena:/xena_home/epidaem$ java.sql.SQLException: Internal error: NLS Conversion ratio 0 is
invalid

        at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:378)
        at oracle.jdbc.dbaccess.DBType.setFieldsForBinds(DBType.java:28)
        at oracle.jdbc.dbaccess.DBType.<init>(DBType.java:171)
        at oracle.jdbc.driver.OracleCallableStatement.registerOutParameter
(OracleCallableStatement.java:123)

        at oracle.jdbc.driver.OracleCallableStatement.registerOutParameter (OracleCallableStatement.java:54)

  at com.hsdc.epi.EPIDaemon.createReceivedMessageQuery(EPIDaemon.java:133) at com.hsdc.epi.EPIDaemon.<init>(EPIDaemon.java:96) at com.hsdc.epi.EPIDaemonServer.startServer(EPIDaemonServer.java:86) at com.hsdc.epi.EPIDaemonServer.main(EPIDaemonServer.java:58)

     private void createReceivedMessageQuery()
        throws java.sql.SQLException
     {
        receivedMessageQuery = daemonConnection.prepareCall(
            "{?= call dbms_pipe.receive_message(?, ?)}");
        receivedMessageQuery.registerOutParameter(1, java.sql.Types.INTEGER);
     }


-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum Received on Mon Sep 21 1998 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US