-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: No operations allowed after statement closed.
PostPosted: Thu Mar 01, 2007 9:00 am 
Newbie

Joined: Thu Mar 01, 2007 8:35 am
Posts: 3
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp

3.0

MySQL Distrib 5.0.24a, for pc-linux-gnu


I am getting the following exception often. It doesnot happen always. Is there a logical mistake in my code (I would post the code excerpt if necessary) that could be causing this problem.

Thanks for posting your replies.
Sharath

2007-03-01 16:34:52,306 [http-8080-Processor74] DEBUG org.hibernate.jdbc.AbstractBatcher - about to open PreparedStatement (open PreparedStatements: 0, globally: 0)
2007-03-01 16:34:52,306 [http-8080-Processor74] DEBUG org.hibernate.SQL - select this_.IDENTITY_ID as IDENTITY1_0_0_, this_.CURRENT_STATE as CURRENT3_0_0_, this_.INAME as INAME0_0_, this_.INUMBER as INUMBER0_0_, this_.FIRST_NAME as FIRST6_0_0_, this_.LAST_NAME as LAST7_0_0_, this_.COMPANY_NAME as COMPANY8_0_0_, this_.COUNTRY as COUNTRY0_0_, this_.PASSWORD as PASSWORD0_0_ from celiberate.CEL_IDENTITY this_ where this_.DISCRIMINATOR='SI' and this_.INAME=?
2007-03-01 16:34:52,306 [http-8080-Processor74] DEBUG org.hibernate.jdbc.AbstractBatcher - preparing statement
2007-03-01 16:34:52,306 [http-8080-Processor74] DEBUG org.hibernate.type.StringType - binding '=equals' to parameter: 1
2007-03-01 16:34:52,337 [http-8080-Processor74] DEBUG org.hibernate.jdbc.AbstractBatcher - about to close PreparedStatement (open PreparedStatements: 1, globally: 1)
2007-03-01 16:34:52,337 [http-8080-Processor74] DEBUG org.hibernate.jdbc.AbstractBatcher - closing statement
2007-03-01 16:34:52,337 [http-8080-Processor74] DEBUG org.hibernate.util.JDBCExceptionReporter - could not execute query [select this_.IDENTITY_ID as IDENTITY1_0_0_, this_.CURRENT_STATE as CURRENT3_0_0_, this_.INAME as INAME0_0_, this_.INUMBER as INUMBER0_0_, this_.FIRST_NAME as FIRST6_0_0_, this_.LAST_NAME as LAST7_0_0_, this_.COMPANY_NAME as COMPANY8_0_0_, this_.COUNTRY as COUNTRY0_0_, this_.PASSWORD as PASSWORD0_0_ from celiberate.CEL_IDENTITY this_ where this_.DISCRIMINATOR='SI' and this_.INAME=?]
com.mysql.jdbc.exceptions.MySQLNonTransientConnectionException: No operations allowed after statement closed.
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:888)
at com.mysql.jdbc.Statement.checkClosed(Statement.java:369)
at com.mysql.jdbc.ServerPreparedStatement.checkClosed(ServerPreparedStatement.java:420)
at com.mysql.jdbc.ServerPreparedStatement.setString(ServerPreparedStatement.java:1852)
at org.apache.commons.dbcp.DelegatingPreparedStatement.setString(DelegatingPreparedStatement.java:131)
at org.apache.commons.dbcp.DelegatingPreparedStatement.setString(DelegatingPreparedStatement.java:131)
at org.hibernate.type.StringType.set(StringType.java:26)
at org.hibernate.type.NullableType.nullSafeSet(NullableType.java:85)
at org.hibernate.type.NullableType.nullSafeSet(NullableType.java:63)
at org.hibernate.loader.Loader.bindPositionalParameters(Loader.java:1514)
at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1576)
at org.hibernate.loader.Loader.doQuery(Loader.java:661)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2145)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029)
at org.hibernate.loader.Loader.list(Loader.java:2024)
at org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:94)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1532)
at org.hibernate.impl.CriteriaImpl.list(CriteriaImpl.java:283)
at com.celiberate.orm2.IdentityDAO2.addIdentity(IdentityDAO2.java:106)
at com.celiberate.services.AttributeService.doPut(AttributeService.java:66)
at com.celiberate.services.DiscoveryService.doPut(DiscoveryService.java:138)
at com.celiberate.app.ProfileResourceManager.executePut(ProfileResourceManager.java:49)
at com.celiberate.app.AbstractResourceManager.executeAction(AbstractResourceManager.java:204)
at com.celiberate.app.AbstractResourceManager.execute(AbstractResourceManager.java:181)
at com.celiberate.app.CATS.handleClientRequest(CATS.java:106)
at com.celiberate.ecp.web.struts.actions.CATSAction.handleRequest(CATSAction.java:98)
at com.celiberate.ecp.web.struts.actions.CATSAction.execute_put(CATSAction.java:50)
at com.celiberate.ecp.web.struts.actions.CeliberateBaseAction.execute(CeliberateBaseAction.java:95)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:419)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194)
at com.celiberate.ecp.web.struts.CeliberateServlet.doPut(CeliberateServlet.java:26)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:712)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at com.celiberate.ecp.HibernateFilter.doFilter(HibernateFilter.java:30)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.valves.FastCommonAccessLogValve.invoke(FastCommonAccessLogValve.java:481)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:526)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:731)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
2007-03-01 16:34:52,353 [http-8080-Processor74] WARN org.hibernate.util.JDBCExceptionReporter - SQL Error: 0, SQLState: 08003
2007-03-01 16:34:52,353 [http-8080-Processor74] ERROR org.hibernate.util.JDBCExceptionReporter - No operations allowed after statement closed.
2007-03-01 16:34:52,353 [http-8080-Processor74] ERROR CATS - Unexpected encountered
org.hibernate.exception.JDBCConnectionException: could not execute query
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:72)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2148)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029)
at org.hibernate.loader.Loader.list(Loader.java:2024)
at org.hibernate.loader.criteria.CriteriaLoader.list(CriteriaLoader.java:94)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1532)
at org.hibernate.impl.CriteriaImpl.list(CriteriaImpl.java:283)
at com.celiberate.orm2.IdentityDAO2.addIdentity(IdentityDAO2.java:106)
at com.celiberate.services.AttributeService.doPut(AttributeService.java:66)
at com.celiberate.services.DiscoveryService.doPut(DiscoveryService.java:138)
at com.celiberate.app.ProfileResourceManager.executePut(ProfileResourceManager.java:49)
at com.celiberate.app.AbstractResourceManager.executeAction(AbstractResourceManager.java:204)
at com.celiberate.app.AbstractResourceManager.execute(AbstractResourceManager.java:181)
at com.celiberate.app.CATS.handleClientRequest(CATS.java:106)
at com.celiberate.ecp.web.struts.actions.CATSAction.handleRequest(CATSAction.java:98)
at com.celiberate.ecp.web.struts.actions.CATSAction.execute_put(CATSAction.java:50)
at com.celiberate.ecp.web.struts.actions.CeliberateBaseAction.execute(CeliberateBaseAction.java:95)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:419)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194)
at com.celiberate.ecp.web.struts.CeliberateServlet.doPut(CeliberateServlet.java:26)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:712)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at com.celiberate.ecp.HibernateFilter.doFilter(HibernateFilter.java:30)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:186)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at org.apache.catalina.valves.FastCommonAccessLogValve.invoke(FastCommonAccessLogValve.java:481)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:526)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:731)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Thread.java:595)
Caused by: com.mysql.jdbc.exceptions.MySQLNonTransientConnectionException: No operations allowed after statement closed.
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:888)
at com.mysql.jdbc.Statement.checkClosed(Statement.java:369)
at com.mysql.jdbc.ServerPreparedStatement.checkClosed(ServerPreparedStatement.java:420)
at com.mysql.jdbc.ServerPreparedStatement.setString(ServerPreparedStatement.java:1852)
at org.apache.commons.dbcp.DelegatingPreparedStatement.setString(DelegatingPreparedStatement.java:131)
at org.apache.commons.dbcp.DelegatingPreparedStatement.setString(DelegatingPreparedStatement.java:131)
at org.hibernate.type.StringType.set(StringType.java:26)
at org.hibernate.type.NullableType.nullSafeSet(NullableType.java:85)
at org.hibernate.type.NullableType.nullSafeSet(NullableType.java:63)
at org.hibernate.loader.Loader.bindPositionalParameters(Loader.java:1514)
at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1576)
at org.hibernate.loader.Loader.doQuery(Loader.java:661)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)
at org.hibernate.loader.Loader.doList(Loader.java:2145)
... 40 more
2007-03-01 16:34:52,353 [http-8080-Processor74] INFO CATS -
Response_No [7]
exception: [could not execute query]
<<<========


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.