Add it (classes12.zip) to your classpath in front of all other jars, even the JRun jars.
Main Topics
Browse All TopicsHi,
I'm having difficulty with this error. The stack trace is below:
com.mycompany.exception.Do
at com.mycompany.database.DAO
at com.mycompany.web.struts.a
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.A
at org.apache.struts.action.A
at javax.servlet.http.HttpSer
at javax.servlet.http.HttpSer
at jrun.servlet.ServletInvoke
at jrun.servlet.JRunInvokerCh
at jrun.servlet.JRunRequestDi
at jrun.servlet.ServletEngine
at jrun.servlet.http.WebServi
at jrunx.scheduler.ThreadPool
at jrunx.scheduler.WorkerThre
Caused by: java.sql.SQLException: Io exception: Protocol violation
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.driver.OracleS
at oracle.jdbc.driver.OracleP
at oracle.jdbc.driver.OracleP
at jrun.sql.JRunPreparedState
at com.mycompany.database.DAO
... 14 more
javax.servlet.ServletExcep
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.A
at org.apache.struts.action.A
at javax.servlet.http.HttpSer
at javax.servlet.http.HttpSer
at jrun.servlet.ServletInvoke
at jrun.servlet.JRunInvokerCh
at jrun.servlet.JRunRequestDi
at jrun.servlet.ServletEngine
at jrun.servlet.http.WebServi
at jrunx.scheduler.ThreadPool
at jrunx.scheduler.WorkerThre
The error indicates a problem within the com.mycompany.database.DAO
rs = ps.executeQuery();
The ps variable is a PreparedStatement that is set earlier. I have test cases that execute outside of my AS (JRun4), and they consistently return correctly. The problem appears only when I run the search through the web application - using the same exact parameters as my test case. Both are consistent - test case consistently works, JRun consistently fails.
The database table that is being searched resides on an Oracle 10g database, and contains a column defined as a LONG data type. I initially thought that this might be the cause of the problem, but found that I don't have issues with other methods that return the same exact columns using different criteria.
I've checked various resources online, and have not found a solution. Any ideas?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
classes*.jar is generally used with jdk1.2 and 1.3. which version of java u r using? if 1.4 and above use ojdbc14.jar
http://www.oracle.com/tech
I'm still having difficulty, but it's a bit different now (or I missed it previously). I now get the following stack trace:
com.mycompany.exception.Do
at com.mycompany.database.DAO
at com.mycompany.web.struts.a
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.A
at org.apache.struts.action.A
at javax.servlet.http.HttpSer
at javax.servlet.http.HttpSer
at jrun.servlet.ServletInvoke
at jrun.servlet.JRunInvokerCh
at jrun.servlet.JRunRequestDi
at jrun.servlet.ServletEngine
at jrun.servlet.http.WebServi
at jrunx.scheduler.ThreadPool
at jrunx.scheduler.WorkerThre
Caused by: java.sql.SQLException: Io exception: Bigger type length than Maximum
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.driver.OracleS
at oracle.jdbc.driver.OracleS
at oracle.jdbc.driver.OracleR
at oracle.jdbc.driver.OracleR
at com.mycompany.database.DAO
... 14 more
javax.servlet.ServletExcep
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.A
at org.apache.struts.action.A
at javax.servlet.http.HttpSer
at javax.servlet.http.HttpSer
at jrun.servlet.ServletInvoke
at jrun.servlet.JRunInvokerCh
at jrun.servlet.JRunRequestDi
at jrun.servlet.ServletEngine
at jrun.servlet.http.WebServi
at jrunx.scheduler.ThreadPool
at jrunx.scheduler.WorkerThre
The error indicates the root cause is the following line:
rs.getString("commentsview
The commentsview column is defined as a VARCHAR2(1) (yeah, I know - I didn't write that junk). It has values of "Y", "N" and null in the database currently.
When I do a page reload after this initial error, I get the Protocol error:
com.mycompany.exception.Do
at com.mycompany.database.DAO
at com.mycompany.web.struts.a
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.A
at org.apache.struts.action.A
at javax.servlet.http.HttpSer
at javax.servlet.http.HttpSer
at jrun.servlet.ServletInvoke
at jrun.servlet.JRunInvokerCh
at jrun.servlet.JRunRequestDi
at jrun.servlet.ServletEngine
at jrun.servlet.http.WebServi
at jrunx.scheduler.ThreadPool
at jrunx.scheduler.WorkerThre
Caused by: java.sql.SQLException: Protocol violation
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.dbaccess.DBErr
at oracle.jdbc.ttc7.Oall7.rec
at oracle.jdbc.ttc7.TTC7Proto
at oracle.jdbc.ttc7.TTC7Proto
at oracle.jdbc.driver.OracleS
at oracle.jdbc.driver.OracleS
at oracle.jdbc.driver.OracleP
at oracle.jdbc.driver.OracleP
at jrun.sql.JRunPreparedState
at com.mycompany.database.DAO
... 14 more
javax.servlet.ServletExcep
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.R
at org.apache.struts.action.A
at org.apache.struts.action.A
at javax.servlet.http.HttpSer
at javax.servlet.http.HttpSer
at jrun.servlet.ServletInvoke
at jrun.servlet.JRunInvokerCh
at jrun.servlet.JRunRequestDi
at jrun.servlet.ServletEngine
at jrun.servlet.http.WebServi
at jrunx.scheduler.ThreadPool
at jrunx.scheduler.WorkerThre
My best guess is that there is something with how I'm using the Connection object that is causing that problem, but I'm not sure. Here's the skeleton of my code (I pulled out all the ps.setString() and rs.getString() methods, or the post would be too large:
public List getUsersByCriteria(String lastname, String firstname,
String custid, String status, String associatedEntityCode,
String associatedEntityBranch, String associatedEntityType)
throws DomainException {
List l = new ArrayList();
Connection conn = null;
ResultSet rs = null;
PreparedStatement ps = null;
try {
conn = ds.getConnection();
ps = conn.prepareStatement(sql.
... setting prepared statement parameters here ...
rs = ps.executeQuery();
while (rs.next()) {
User u = new User(
rs.getString("address1"),
... bunch of rs.getString()s here ...
);
l.add(u);
}
return l;
} catch (SQLException e) {
LOG.error(e);
throw new DomainException(e);
} finally {
ConnectionManager.closeRes
ConnectionManager.closeSta
ConnectionManager.closeCon
}
}
Business Accounts
Answer for Membership
by: mrigankPosted on 2006-04-05 at 12:20:30ID: 16385342
Check if you are using the correct version of classes***.zip and ojdbc..jar