Not sure where to post this one: our customer got an error that we have not been able to reproduce, and I don’t have access to the server log yet, so I can’t figure out when it happened.
The error says: ‘Failed to lock the data region[2147483646,2147483647] of jobs.DBF’
But the table name is different, not jobs. Numbers also don’t give any clue as to what’s happening, they’re far beyond the real job numbers.
We use a driver to connect Servoy application to a FoxPro backend. Could it be the driver message?
Appreciate any ideas!
Um… Just had the same issue again.
It happens when I execute my query (SELECT a.servcardid FROM servcard a WHERE a.servcardid = a.servcardid AND (a.employeeid = ‘SCOTT DAVIE’ OR a.servcardid IN (SELECT b.servcardid FROM assignment b WHERE b.employeeid = ‘SCOTT DAVIE’)) ORDER BY a.servcardid DESC)
The error message is:
2011-03-07 13:47:45,212 ERROR [http-8080-11] com.servoy.j2db.util.Debug - SELECT a.servcardid FROM servcard a WHERE a.servcardid = a.servcardid AND (a.employeeid = 'SCOTT DAVIE' OR a.servcardid IN (SELECT b.servcardid FROM assignment b WHERE b.employeeid = 'SCOTT DAVIE')) ORDER BY a.servcardid DESC parameters: <null>
java.sql.SQLException: Failed to lock the data region[2147483646,2147483647] of servcard.DBF
at com.hxtt.global.SQLState.SQLException(Unknown Source)
at com.hxtt.concurrent.s.a(Unknown Source)
at com.hxtt.sql.dbf.i.if(Unknown Source)
at com.hxtt.sql.dbf.i.a(Unknown Source)
at com.hxtt.sql.ck.try(Unknown Source)
at com.hxtt.sql.ct.a(Unknown Source)
at com.hxtt.sql.ct.a(Unknown Source)
at com.hxtt.sql.ep.u(Unknown Source)
at com.hxtt.sql.di.a(Unknown Source)
at com.hxtt.sql.di.a(Unknown Source)
at com.hxtt.sql.di.if(Unknown Source)
at com.hxtt.sql.di.a(Unknown Source)
at com.hxtt.sql.di.a(Unknown Source)
at com.hxtt.sql.bp.a(Unknown Source)
at com.hxtt.sql.ah.a(Unknown Source)
at com.hxtt.sql.dk.executeQuery(Unknown Source)
at sun.reflect.GeneratedMethodAccessor129.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.servoy.j2db.persistence.datasource.Zf.invoke(Zf.java:1)
at $Proxy1.executeQuery(Unknown Source)
at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:179)
at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:179)
at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:179)
at com.servoy.j2db.dataprocessing.SQLEngine.performSelect(SQLEngine.java:915)
at com.servoy.j2db.dataprocessing.SQLEngine.performQuery(SQLEngine.java:145)
at com.servoy.j2db.dataprocessing.SQLEngine.performCustomQuery(SQLEngine.java:231)
at com.servoy.j2db.dataprocessing.Zsb.Za(Zsb.java:46)
at com.servoy.j2db.dataprocessing.JSDatabaseManager.js_getDataSetByQuery(JSDatabaseManager.java:216)
at sun.reflect.GeneratedMethodAccessor6561.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:179)
at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:353)
at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3666)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2680)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:166)
at com.servoy.j2db.scripting.Ztb.executeFunction(Ztb.java:196)
at com.servoy.j2db.Zwb.Za(Zwb.java:741)
at com.servoy.j2db.Zwb.Za(Zwb.java:106)
at com.servoy.j2db.Zwb.ZP(Zwb.java:834)
at com.servoy.j2db.Zwb.access$1400(Zwb.java:712)
at com.servoy.j2db.Zzb.run(Zzb.java:4)
at com.servoy.j2db.server.headlessclient.Zd.invokeLater(Zd.java:99)
at com.servoy.j2db.util.Utils.invokeLater(Utils.java:420)
at com.servoy.j2db.Zec.Za(Zec.java:299)
at com.servoy.j2db.Zec.Ze(Zec.java:184)
at com.servoy.j2db.Zec.Za(Zec.java:208)
at com.servoy.j2db.Zec.Za(Zec.java:259)
at com.servoy.j2db.ClientState.clearLoginForm(ClientState.java:222)
at com.servoy.j2db.scripting.JSSecurity.js_login(JSSecurity.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:179)
at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:353)
at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3666)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2680)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:166)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:387)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3127)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:165)
at com.servoy.j2db.scripting.Ztb.executeFunction(Ztb.java:196)
at com.servoy.j2db.Zwb.Za(Zwb.java:741)
at com.servoy.j2db.Zwb.Za(Zwb.java:1223)
at com.servoy.j2db.Zcc.Za(Zcc.java:1)
at com.servoy.j2db.ui.BaseEventExecutor.fireEventCommand(BaseEventExecutor.java:27)
at com.servoy.j2db.ui.BaseEventExecutor.fireEventCommand(BaseEventExecutor.java:18)
at com.servoy.j2db.ui.BaseEventExecutor.fireActionCommand(BaseEventExecutor.java:16)
at com.servoy.j2db.server.headlessclient.dataui.WebEventExecutor.onEvent(WebEventExecutor.java:156)
at com.servoy.j2db.server.headlessclient.dataui.Zzd.onEvent(Zzd.java:7)
at org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:177)
at org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:286)
at org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:119)
at org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92)
at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1250)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:479)
at com.servoy.j2db.server.servlets.Zk.doGet(Zk.java:4)
at org.apache.wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:138)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
at java.lang.Thread.run(Unknown Source)
2011-03-07 13:47:45,212 ERROR [http-8080-11] com.servoy.j2db.util.Debug - Throwable
com.servoy.j2db.dataprocessing.DataException: Failed to lock the data region[2147483646,2147483647] of servcard.DBF
at com.servoy.j2db.dblayer.Zb.Za(Zb.java:189)
at com.servoy.j2db.persistence.Server.translateSQLException(Server.java:663)
at com.servoy.j2db.dataprocessing.SQLEngine.performQuery(SQLEngine.java:933)
at com.servoy.j2db.dataprocessing.SQLEngine.performCustomQuery(SQLEngine.java:231)
at com.servoy.j2db.dataprocessing.Zsb.Za(Zsb.java:46)
at com.servoy.j2db.dataprocessing.JSDatabaseManager.js_getDataSetByQuery(JSDatabaseManager.java:216)
at sun.reflect.GeneratedMethodAccessor6561.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:179)
at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:353)
at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3666)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2680)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:166)
at com.servoy.j2db.scripting.Ztb.executeFunction(Ztb.java:196)
at com.servoy.j2db.Zwb.Za(Zwb.java:741)
at com.servoy.j2db.Zwb.Za(Zwb.java:106)
at com.servoy.j2db.Zwb.ZP(Zwb.java:834)
at com.servoy.j2db.Zwb.access$1400(Zwb.java:712)
at com.servoy.j2db.Zzb.run(Zzb.java:4)
at com.servoy.j2db.server.headlessclient.Zd.invokeLater(Zd.java:99)
at com.servoy.j2db.util.Utils.invokeLater(Utils.java:420)
at com.servoy.j2db.Zec.Za(Zec.java:299)
at com.servoy.j2db.Zec.Ze(Zec.java:184)
at com.servoy.j2db.Zec.Za(Zec.java:208)
at com.servoy.j2db.Zec.Za(Zec.java:259)
at com.servoy.j2db.ClientState.clearLoginForm(ClientState.java:222)
at com.servoy.j2db.scripting.JSSecurity.js_login(JSSecurity.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:179)
at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:353)
at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3666)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2680)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:166)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:387)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3127)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:165)
at com.servoy.j2db.scripting.Ztb.executeFunction(Ztb.java:196)
at com.servoy.j2db.Zwb.Za(Zwb.java:741)
at com.servoy.j2db.Zwb.Za(Zwb.java:1223)
at com.servoy.j2db.Zcc.Za(Zcc.java:1)
at com.servoy.j2db.ui.BaseEventExecutor.fireEventCommand(BaseEventExecutor.java:27)
at com.servoy.j2db.ui.BaseEventExecutor.fireEventCommand(BaseEventExecutor.java:18)
at com.servoy.j2db.ui.BaseEventExecutor.fireActionCommand(BaseEventExecutor.java:16)
at com.servoy.j2db.server.headlessclient.dataui.WebEventExecutor.onEvent(WebEventExecutor.java:156)
at com.servoy.j2db.server.headlessclient.dataui.Zzd.onEvent(Zzd.java:7)
at org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:177)
at org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:286)
at org.apache.wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:119)
at org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:92)
at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1250)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:479)
at com.servoy.j2db.server.servlets.Zk.doGet(Zk.java:4)
at org.apache.wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:138)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:567)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:454)
at java.lang.Thread.run(Unknown Source)
Still cannot figure out what the problem is.
Appreciate your thoughts.
Since you are using a custom query, Servoy is sending this ‘as is’ to the db, there is nothing Servoy can do about it.
Do you always get this error with this query? or just sometimes (like when multiple users are accessing this table)?
Yoy can also try making the query simpeler, something like
SELECT DISTINCT a.servcardid
FROM servcard a
LEFT JOIN assignment b ON a.servcardid = b.servcardid AND b.employeeid = ?
WHERE a.employeeid = ? OR b.servcardid IS NOT NULL
ORDER BY a.servcardid DESC
Is equivalent, I think.
Btw, if the ‘SCOTT DAVIE’ string is not fixed, it is better to use prepared statements (the question marks) to prevent sql injection.
If you always get the error you may file a case with the db vendor (I saw you already tried that), but with some sql (create, insert, select) that reproduces it.
Since you are using a custom query, Servoy is sending this ‘as is’ to the db, there is nothing Servoy can do about it.
Do you always get this error with this query? or just sometimes (like when multiple users are accessing this table)?
Yoy can also try making the query simpeler, something like
SELECT DISTINCT a.servcardid
FROM servcard a
LEFT JOIN assignment b ON a.servcardid = b.servcardid AND b.employeeid = ?
WHERE a.employeeid = ? OR b.servcardid IS NOT NULL
ORDER BY a.servcardid DESC
Is equivalent, I think.
Btw, if the 'SCOTT DAVIE' string is not fixed, it is better to use prepared statements (the question marks) to prevent sql injection.
If you always get the error you may file a case with the db vendor (I saw you already tried that), but with some sql (create, insert, select) that reproduces it.
Rob
Hi Rob,
Thanks for your suggestions.
Our problem is that we can’t reproduce the error. It happens very rarely but has come up a few times already…