org.hibernate.StaleStateException

Batch update returned unexpected row count from update [1]; actual row count: 0; expected: 1

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web202

  • via Unknown by Jerome Velociter,
  • via Unknown by Unknown author,
  • Stack trace

    • org.hibernate.StaleStateException: Batch update returned unexpected row count from update [1]; actual row count: 0; expected: 1 at org.hibernate.jdbc.Expectations$BasicExpectation.checkBatched(Expectations.java:85)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.jdbc.Expectations$BasicExpectation.verifyOutcome(Expectations.java:70)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.jdbc.BatchingBatcher.checkRowCounts(BatchingBatcher.java:90)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.jdbc.BatchingBatcher.doExecuteBatch(BatchingBatcher.java:70)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:268)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:268)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:185)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:321)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:51)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1216)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:383)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:133)[hibernate-core-3.6.7.Final.jar:3.6.7.Final] at com.xpn.xwiki.store.XWikiHibernateBaseStore.endTransaction(XWikiHibernateBaseStore.java:881)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.store.XWikiHibernateBaseStore.endTransaction(XWikiHibernateBaseStore.java:852)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.store.XWikiHibernateStore.saveXWikiDoc(XWikiHibernateStore.java:680)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.store.XWikiCacheStore.saveXWikiDoc(XWikiCacheStore.java:174)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.store.XWikiCacheStore.saveXWikiDoc(XWikiCacheStore.java:167)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.XWiki.saveDocument(XWiki.java:1406)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.api.Document.saveDocument(Document.java:2017)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.api.Document.save(Document.java:1928)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.api.Document.save(Document.java:1922)[xwiki-platform-legacy-oldcore-3.2.jar:na] at net.winesquare.internal.cellar.DefaultCellar.renameWine(DefaultCellar.java:455)[winesquare-extension-cellar-1.0-SNAPSHOT.jar:na] at net.winesquare.internal.cellar.CellarScriptService.renameWine(CellarScriptService.java:222)[winesquare-extension-cellar-1.0-SNAPSHOT.jar:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.6.0_26] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)[na:1.6.0_26] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)[na:1.6.0_26] at java.lang.reflect.Method.invoke(Method.java:597)[na:1.6.0_26] at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:395)[velocity-1.7.jar:1.7] at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:384)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:173)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:280)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTReference.value(ASTReference.java:567)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTExpression.value(ASTExpression.java:71)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTSetDirective.render(ASTSetDirective.java:142)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTElseIfStatement.render(ASTElseIfStatement.java:92)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:106)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:342)[velocity-1.7.jar:1.7] at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:186)[xwiki-commons-velocity-3.2.jar:na] at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:152)[xwiki-commons-velocity-3.2.jar:na] at org.xwiki.rendering.internal.macro.velocity.VelocityMacro.evaluateString(VelocityMacro.java:124)[xwiki-platform-rendering-macro-velocity-3.2.jar:na] at org.xwiki.rendering.internal.macro.velocity.VelocityMacro.evaluateString(VelocityMacro.java:50)[xwiki-platform-rendering-macro-velocity-3.2.jar:na] at org.xwiki.rendering.macro.script.AbstractScriptMacro.evaluateBlock(AbstractScriptMacro.java:306)[xwiki-platform-rendering-macro-script-3.2.jar:na] at org.xwiki.rendering.macro.script.AbstractScriptMacro.execute(AbstractScriptMacro.java:202)[xwiki-platform-rendering-macro-script-3.2.jar:na] at org.xwiki.rendering.macro.script.AbstractScriptMacro.execute(AbstractScriptMacro.java:59)[xwiki-platform-rendering-macro-script-3.2.jar:na] at org.xwiki.rendering.internal.transformation.macro.MacroTransformation.transformOnce(MacroTransformation.java:196)[xwiki-rendering-transformation-macro-3.2.jar:na] at org.xwiki.rendering.internal.transformation.macro.MacroTransformation.transform(MacroTransformation.java:141)[xwiki-rendering-transformation-macro-3.2.jar:na] at org.xwiki.rendering.internal.transformation.DefaultTransformationManager.performTransformations(DefaultTransformationManager.java:81)[xwiki-rendering-api-3.2.jar:na] at org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentDisplayer.java:253)[xwiki-platform-display-3.2.jar:na] at org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentDisplayer.java:125)[xwiki-platform-display-3.2.jar:na] at org.xwiki.display.internal.DocumentContentDisplayer.display(DocumentContentDisplayer.java:55)[xwiki-platform-display-3.2.jar:na] at org.xwiki.display.internal.DefaultDocumentDisplayer.display(DefaultDocumentDisplayer.java:80)[xwiki-platform-display-3.2.jar:na] at org.xwiki.display.internal.DefaultDocumentDisplayer.display(DefaultDocumentDisplayer.java:38)[xwiki-platform-display-3.2.jar:na] at com.xpn.xwiki.internal.sheet.SheetDocumentDisplayer.display(SheetDocumentDisplayer.java:113)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.internal.sheet.SheetDocumentDisplayer.display(SheetDocumentDisplayer.java:57)[xwiki-platform-legacy-oldcore-3.2.jar:na] at org.xwiki.display.internal.ConfiguredDocumentDisplayer.display(ConfiguredDocumentDisplayer.java:67)[xwiki-platform-display-3.2.jar:na] at org.xwiki.display.internal.ConfiguredDocumentDisplayer.display(ConfiguredDocumentDisplayer.java:41)[xwiki-platform-display-3.2.jar:na] at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:827)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:806)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.doc.XWikiDocument.getRenderedContent(XWikiDocument.java:837)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.api.Document.getRenderedContent(Document.java:585)[xwiki-platform-legacy-oldcore-3.2.jar:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.6.0_26] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)[na:1.6.0_26] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)[na:1.6.0_26] at java.lang.reflect.Method.invoke(Method.java:597)[na:1.6.0_26] at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:395)[velocity-1.7.jar:1.7] at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:384)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:173)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:280)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:369)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:342)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:106)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:342)[velocity-1.7.jar:1.7] at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:186)[xwiki-commons-velocity-3.2.jar:na] at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:152)[xwiki-commons-velocity-3.2.jar:na] at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:117)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1816)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.XWiki.parseTemplate(XWiki.java:1753)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.api.XWiki.parseTemplate(XWiki.java:841)[xwiki-platform-legacy-oldcore-3.2.jar:na] at sun.reflect.GeneratedMethodAccessor182.invoke(Unknown Source)[na:na] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)[na:1.6.0_26] at java.lang.reflect.Method.invoke(Method.java:597)[na:1.6.0_26] at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:395)[velocity-1.7.jar:1.7] at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:384)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:173)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTReference.execute(ASTReference.java:280)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:369)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.directive.VelocimacroProxy.render(VelocimacroProxy.java:216)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:311)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.directive.RuntimeMacro.render(RuntimeMacro.java:230)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTDirective.render(ASTDirective.java:207)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTBlock.render(ASTBlock.java:72)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:342)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.ASTIfStatement.render(ASTIfStatement.java:106)[velocity-1.7.jar:1.7] at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:342)[velocity-1.7.jar:1.7] at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:186)[xwiki-commons-velocity-3.2.jar:na] at org.xwiki.velocity.internal.DefaultVelocityEngine.evaluate(DefaultVelocityEngine.java:152)[xwiki-commons-velocity-3.2.jar:na] at com.xpn.xwiki.render.XWikiVelocityRenderer.evaluate(XWikiVelocityRenderer.java:117)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.XWiki.evaluateTemplate(XWiki.java:1816)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.web.Utils.parseTemplate(Utils.java:154)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:238)[xwiki-platform-legacy-oldcore-3.2.jar:na] at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:116)[xwiki-platform-legacy-oldcore-3.2.jar:na] at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)[struts-1.2.9.jar:1.2.9] at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)[struts-1.2.9.jar:1.2.9] at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)[struts-1.2.9.jar:1.2.9] at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)[struts-1.2.9.jar:1.2.9] at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)[servlet-api-2.5-20081211.jar:na] at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)[servlet-api-2.5-20081211.jar:na] at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1166)[jetty-6.1.21.jar:6.1.21] at com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:128)[xwiki-platform-legacy-oldcore-3.2.jar:na] at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)[jetty-6.1.21.jar:6.1.21] at org.xwiki.wysiwyg.server.filter.ConversionFilter.doFilter(ConversionFilter.java:144)[xwiki-platform-wysiwyg-server-3.2.jar:na] at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)[jetty-6.1.21.jar:6.1.21] at com.xpn.xwiki.plugin.webdav.XWikiDavFilter.doFilter(XWikiDavFilter.java:68)[xwiki-platform-webdav-server-3.2.jar:na] at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)[jetty-6.1.21.jar:6.1.21] at org.xwiki.container.servlet.filters.internal.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:217)[xwiki-platform-container-servlet-3.2.jar:na] at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)[jetty-6.1.21.jar:6.1.21] at org.xwiki.container.servlet.filters.internal.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:109)[xwiki-platform-container-servlet-3.2.jar:na] at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.Server.handle(Server.java:326)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:536)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:930)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:747)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)[jetty-6.1.21.jar:6.1.21] at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:405)[jetty-6.1.21.jar:6.1.21] at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)[jetty-6.1.21.jar:6.1.21] at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)[jetty-util-6.1.21.jar:6.1.21]

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    mauritiusmauritius
    Once,
    Unknown visitor
    Unknown visitor2 times, last one
    Unknown visitor
    Unknown visitorOnce,
    mortalman7mortalman7
    Once,
    Unknown visitor
    Unknown visitorOnce,
    74 more bugmates