Hello, I’m trying to show data of an QOL dataset. Now I’m getting an exception (see below) which’s root cause says “Object 'MyFirstModule.MitarbeiterSnapshot' doesn't contain column 'createddate'”. But in the model for this entity the option “Store ‘createdDate’” is checked and in the database manager shows the column and a query using the field works, too. Can anybody give me a hint? Bye Andreas com.mendix.core.CoreRuntimeException: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.core.CoreRuntimeException: Exception occurred in action '{"request":"InternalOqlTextGetRequest (depth = 0): select s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo as SnapshotNo, min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate, s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name as SkillName, count(*) as Cnt from MyFirstModule.SkillzuordnungSnapshot s group by s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name, s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo ","type":"RetrieveOQLDataTableAction"}', all database changes executed by this action were rolled back at com.mendix.basis.actionmanagement.ActionManagerBase.executeSync(ActionManagerBase.java:155) Caused by: com.mendix.systemwideinterfaces.MendixRuntimeException: com.mendix.core.CoreRuntimeException: Exception occurred in action '{"request":"InternalOqlTextGetRequest (depth = 0): select s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo as SnapshotNo, min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate, s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name as SkillName, count(*) as Cnt from MyFirstModule.SkillzuordnungSnapshot s group by s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name, s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo ","type":"RetrieveOQLDataTableAction"}', all database changes executed by this action were rolled back at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:36) Caused by: com.mendix.core.CoreRuntimeException: Exception occurred in action '{"request":"InternalOqlTextGetRequest (depth = 0): select s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo as SnapshotNo, min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate, s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name as SkillName, count(*) as Cnt from MyFirstModule.SkillzuordnungSnapshot s group by s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name, s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo ","type":"RetrieveOQLDataTableAction"}', all database changes executed by this action were rolled back at com.mendix.basis.actionmanagement.CoreActionHandlerImpl.processErrorState(CoreActionHandlerImpl.scala:150) Caused by: com.mendix.connectionbus.ConnectionBusRuntimeException: An exception has occurred for the following request(s): InternalOqlTextGetRequest (depth = -1): select s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo as SnapshotNo, min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate, s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name as SkillName, count(*) as Cnt from MyFirstModule.SkillzuordnungSnapshot s group by s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name, s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo at com.mendix.connectionbus.RequestAnalyzer.doRequest(RequestAnalyzer.java:63) Caused by: com.mendix.connectionbus.ConnectionBusRuntimeException: Object 'MyFirstModule.MitarbeiterSnapshot' doesn't contain column 'createddate', exception occurred on mapping the following query: SELECT s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot/SnapshotNo AS SnapshotNo, MIN(j1myfirstmodule$mitarbeitersnapshot.createddate) AS SnapshotDate, s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill/Name AS SkillName, COUNT(*) AS Cnt FROM MyFirstModule.SkillzuordnungSnapshot AS s LEFT OUTER JOIN s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot AS j1myfirstmodule$mitarbeitersnapshot LEFT OUTER JOIN s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill AS j2myfirstmodule$skill GROUP BY s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill/Name, s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot/SnapshotNo at com.mendix.connectionbus.retrieve.query.mapping.QueryMapper.getMappedQueries(QueryMapper.java:276) Caused by: com.mendix.connectionbus.ConnectionBusRuntimeException: Object 'MyFirstModule.MitarbeiterSnapshot' doesn't contain column 'createddate' at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.getColumnLocation(SelectColumnsMapper.java:324) at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.handleDoubleLocationSelectColumn(SelectColumnsMapper.java:220) at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.handleLocationSelectColumn(SelectColumnsMapper.java:148) at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.handleColumn(SelectColumnsMapper.java:83) at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.handleAggregateExpr(SelectColumnsMapper.java:694) at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.handleColumn(SelectColumnsMapper.java:85) at com.mendix.connectionbus.retrieve.query.mapping.SelectColumnsMapper.mapSelectColumns(SelectColumnsMapper.java:49) at com.mendix.connectionbus.retrieve.query.mapping.QueryMapper.mapSelectColumns(QueryMapper.java:724) at com.mendix.connectionbus.retrieve.query.mapping.QueryMapper.getMappedQueries(QueryMapper.java:246) at com.mendix.connectionbus.retrieve.query.mapping.QueryMapper.getQueryInstances(QueryMapper.java:145) at com.mendix.connectionbus.retrieve.OqlRequestHandler.doOldQueryHandling(OqlRequestHandler.scala:147) at com.mendix.connectionbus.retrieve.OqlRequestHandler.handleError$1(OqlRequestHandler.scala:81) at com.mendix.connectionbus.retrieve.OqlRequestHandler.handleRequest(OqlRequestHandler.scala:113) at com.mendix.connectionbus.retrieve.DataStoreCaller.processOqlGetRequest(DataStoreCaller.scala:41) at com.mendix.connectionbus.retrieve.DataStoreCaller.$anonfun$getResult$1(DataStoreCaller.scala:35) at com.mendix.connectionbus.retrieve.DataStoreCaller$$Lambda$873.0000000056DB2DD0.apply(Unknown Source) at scala.collection.TraversableLike.$anonfun$flatMap$1(TraversableLike.scala:244) at scala.collection.TraversableLike$$Lambda$554.0000000056A399C0.apply(Unknown Source) at scala.collection.IndexedSeqOptimized.foreach(IndexedSeqOptimized.scala:36) at scala.collection.IndexedSeqOptimized.foreach$(IndexedSeqOptimized.scala:33) at scala.collection.mutable.WrappedArray.foreach(WrappedArray.scala:39) at scala.collection.TraversableLike.flatMap(TraversableLike.scala:244) at scala.collection.TraversableLike.flatMap$(TraversableLike.scala:241) at scala.collection.AbstractTraversable.flatMap(Traversable.scala:108) at com.mendix.connectionbus.retrieve.DataStoreCaller.getResult(DataStoreCaller.scala:35) at com.mendix.connectionbus.retrieve.DataStoreCaller.getResult(DataStoreCaller.scala:33) at com.mendix.connectionbus.retrieve.GetRequestHandler.doRequest(GetRequestHandler.java:66) at com.mendix.connectionbus.RequestAnalyzer.doRequest(RequestAnalyzer.java:49) at com.mendix.connectionbus.ConnectionBusImpl.doRequest(ConnectionBusImpl.java:512) at com.mendix.basis.action.user.RetrieveOQLDataTableAction.executeAction(RetrieveOQLDataTableAction.java:87) at com.mendix.basis.action.user.RetrieveOQLDataTableAction.executeAction(RetrieveOQLDataTableAction.java:18) at com.mendix.systemwideinterfaces.core.UserAction.execute(UserAction.java:46) at com.mendix.basis.actionmanagement.CoreActionHandlerImpl.doCall(CoreActionHandlerImpl.scala:71) at com.mendix.basis.actionmanagement.CoreActionHandlerImpl.call(CoreActionHandlerImpl.scala:49) at com.mendix.core.actionmanagement.CoreAction.call(CoreAction.java:54) at com.mendix.basis.actionmanagement.ActionManagerBase$1.execute(ActionManagerBase.java:146) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:32) at com.mendix.basis.actionmanagement.ActionManagerBase.executeSync(ActionManagerBase.java:151) at com.mendix.basis.component.InternalCoreBase.retrieveOQLDataTable(InternalCoreBase.java:839) at com.mendix.webui.reporting.generation.SeriesDataGenerator.getResultFromOQL(SeriesDataGenerator.java:388) at com.mendix.webui.reporting.generation.SeriesDataGenerator.getSeriesValues(SeriesDataGenerator.java:307) at com.mendix.webui.reporting.generation.SeriesDataGenerator.getSeriesDataList(SeriesDataGenerator.java:84) at com.mendix.webui.reporting.generation.SeriesDataGenerator.getSeriesDataList(SeriesDataGenerator.java:75) at com.mendix.webui.reporting.clientactions.ReportAction.execute(ReportAction.java:62) at com.mendix.webui.requesthandling.ClientRequestHandler.$anonfun$handleRequest$2(ClientRequestHandler.scala:189) at com.mendix.webui.requesthandling.ClientRequestHandler$$Lambda$1990.0000000057649D70.apply(Unknown Source) at com.mendix.webui.requesthandling.helpers.StateHandling.withState(StateHandling.scala:37) at com.mendix.webui.requesthandling.helpers.StateHandling.withState$(StateHandling.scala:30) at com.mendix.webui.requesthandling.ClientRequestHandler.withState(ClientRequestHandler.scala:29) at com.mendix.webui.requesthandling.helpers.StateHandling.withState(StateHandling.scala:27) at com.mendix.webui.requesthandling.helpers.StateHandling.withState$(StateHandling.scala:20) at com.mendix.webui.requesthandling.ClientRequestHandler.withState(ClientRequestHandler.scala:29) at com.mendix.webui.requesthandling.ClientRequestHandler.$anonfun$handleRequest$1(ClientRequestHandler.scala:187) at com.mendix.webui.requesthandling.ClientRequestHandler.$anonfun$handleRequest$1$adapted(ClientRequestHandler.scala:173) at com.mendix.webui.requesthandling.ClientRequestHandler$$Lambda$1989.00000000585B6840.apply(Unknown Source) at com.mendix.webui.requesthandling.helpers.ContextHandling.$anonfun$inContext$3(ContextHandling.scala:41) at com.mendix.webui.requesthandling.helpers.ContextHandling$$Lambda$1748.00000000581C4A70.apply$mcV$sp(Unknown Source) at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23) at com.mendix.basis.actionmanagement.IMonitoredAction$$anon$1.execute(IMonitoredAction.scala:47) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:32) at com.mendix.basis.actionmanagement.IMonitoredAction.monitor(IMonitoredAction.scala:49) at com.mendix.basis.actionmanagement.IMonitoredAction.monitor$(IMonitoredAction.scala:25) at com.mendix.webui.requesthandling.helpers.ContextHandling$ClientMonitoredAction.monitor(ContextHandling.scala:49) at com.mendix.webui.requesthandling.helpers.ContextHandling.inContext(ContextHandling.scala:41) at com.mendix.webui.requesthandling.helpers.ContextHandling.inContext$(ContextHandling.scala:27) at com.mendix.webui.requesthandling.ClientRequestHandler.inContext(ClientRequestHandler.scala:29) at com.mendix.webui.requesthandling.helpers.ContextHandling.inContext(ContextHandling.scala:24) at com.mendix.webui.requesthandling.helpers.ContextHandling.inContext$(ContextHandling.scala:19) at com.mendix.webui.requesthandling.ClientRequestHandler.inContext(ClientRequestHandler.scala:29) at com.mendix.webui.requesthandling.ClientRequestHandler.handleRequest(ClientRequestHandler.scala:173) at com.mendix.webui.requesthandling.ClientRequestHandler.$anonfun$handleAction$1(ClientRequestHandler.scala:144) at com.mendix.webui.requesthandling.ClientRequestHandler$$Lambda$1988.000000005805B3E0.apply(Unknown Source) at com.mendix.webui.requesthandling.helpers.ProfileHandling.profileRequest(ProfileHandling.scala:14) at com.mendix.webui.requesthandling.helpers.ProfileHandling.profileRequest$(ProfileHandling.scala:10) at com.mendix.webui.requesthandling.ClientRequestHandler.profileRequest(ClientRequestHandler.scala:29) at com.mendix.webui.requesthandling.ClientRequestHandler.handleAction(ClientRequestHandler.scala:144) at com.mendix.webui.requesthandling.ClientRequestHandler.processRequest(ClientRequestHandler.scala:107) at com.mendix.externalinterface.connector.RequestHandler.doProcessRequest(RequestHandler.java:40) at com.mendix.external.connector.MxRuntimeConnector$1.execute(MxRuntimeConnector.java:76) at com.mendix.external.connector.MxRuntimeConnector$1.execute(MxRuntimeConnector.java:73) at com.mendix.util.classloading.Runner.doRunUsingClassLoaderOf(Runner.java:32) at com.mendix.external.connector.MxRuntimeConnector.processRequest(MxRuntimeConnector.java:79) at com.mendix.basis.impl.MxRuntimeImpl.processRequest(MxRuntimeImpl.java:967) at com.mendix.m2ee.appcontainer.server.handler.RuntimeHandler.service(RuntimeHandler.java:42) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:867) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:542) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255) at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1588) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:255) at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1345) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:203) at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:480) at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1557) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:201) at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1247) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:144) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:132) at org.eclipse.jetty.server.Server.handle(Server.java:502) at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:364) at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:260) at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:305) at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:118) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:333) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:310) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:168) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:126) at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:366) at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:765) at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:683) at java.base/java.lang.Thread.run(Thread.java:825)
asked
Andreas Bubolz
5 answers
0
Andreas,
This seems like a case issue. The column in Mendix is called createdDate and your OQL has createddate.
Do you get the same error when you changed the second d to a capital?
Mike
answered
Mike Kumpf
0
Hi Mike,
in the stack trace I posted the OQL contains “createdDate” (as it’s forced by the editor, “createddate” results in error).
Deeper (in the causes) it seems to be translated to lowercase. And the database manager shows it lowercase, too.
So I don’t think that this is the problem.
Andreas
answered
Andreas Bubolz
0
Your query is
SELECT s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot/SnapshotNo AS SnapshotNo, MIN(j1myfirstmodule$mitarbeitersnapshot.createddate) AS SnapshotDate, s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill/Name AS SkillName, COUNT(*) AS Cnt FROM MyFirstModule.SkillzuordnungSnapshot AS s LEFT OUTER JOIN s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot AS j1myfirstmodule$mitarbeitersnapshot LEFT OUTER JOIN s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill AS j2myfirstmodule$skill GROUP BY s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill/Name, s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot/SnapshotNo....etc
Try to copy the entire SQL by setting the Console->Advanced→Loglevel to trace to item ConnectionBus_Retrieve, copy paste it to your database manager and see if you succeed in running directly from that point. Usually this will unhide the cause of the error.
answered
Tim v Steenbergen
0
Hi Tim,
thank you for the hint with logging, didn’t know this. But unfortunately that did not help me either.
But I’ve tried simplified queries.
This works:
select min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate from MyFirstModule.SkillzuordnungSnapshot s
But this does not work (same but with group by clause):
select min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate from MyFirstModule.SkillzuordnungSnapshot s group by s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill.Name
Just before the exception the console shows this warning:
Executing query with old implementation due to detected exception in new implementation: Object name 's/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill' doesn't refer to a valid from location., exception occurred on mapping the following query: SELECT MIN(j1myfirstmodule$mitarbeitersnapshot.createddate) AS SnapshotDate FROM MyFirstModule.SkillzuordnungSnapshot AS s LEFT OUTER JOIN s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot AS j1myfirstmodule$mitarbeitersnapshot GROUP BY s/MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill/Name
select
s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo as SnapshotNo,
min(s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.createdDate) as SnapshotDate,
MyFirstModule.Skill.Name as SkillName,
count(*) as Cnt
from MyFirstModule.SkillzuordnungSnapshot s
inner join MyFirstModule.SkillzuordnungSnapshot_Skill/MyFirstModule.Skill
group by
MyFirstModule.Skill.Name,
s/MyFirstModule.SkillzuordnungSnapshot_MitarbeiterSnapshot/MyFirstModule.MitarbeiterSnapshot.SnapshotNo