[Coldbox 4.3.0] [Coldfusion 10] 'table' is not BASE TABLE

64 views
Skip to first unread message

echo

unread,
Nov 13, 2017, 8:08:30 PM11/13/17
to ColdBox Platform
Hello,

I have been working on a cold box project using Lucee server. Now we transfer to Coldfusion 10. When I goes to the index.cfm The error is 'table' is not BASE TABLE. In mysql database setting, this 'table' is in view section(read-only), which is created based on the some of the tables in the table section. I wonder how to deal with this error.

Thanks a lot for your help.

Icy LI

Ancient Programmer

unread,
Nov 14, 2017, 12:30:08 AM11/14/17
to ColdBox Platform
Could you post the error details?

echo

unread,
Nov 14, 2017, 1:42:32 AM11/14/17
to ColdBox Platform
The error stack is as followed, thank you.

The web site you are accessing has experienced an unexpected error.
Please contact the website administrator. 


The following information is meant for the website developer for debugging purposes.
Error Occurred While Processing Request

Error in executing the DDL.

'jldp_latest.programmesjldp' is not BASE TABLE
 
Resources:

Browser  Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36
Remote Address  172.31.10.156
Referrer  
Date/Time  14-Nov-17 02:37 PM
Stack Trace
 

org.hibernate.JDBCException: Error during DDL export
	at org.hibernate.tool.hbm2ddl.SchemaUpdate.execute(SchemaUpdate.java:209)
	at coldfusion.orm.hibernate.HibernateConfiguration.exportSchema(HibernateConfiguration.java:455)
	at coldfusion.orm.hibernate.HibernateConfiguration.exportSchema(HibernateConfiguration.java:413)
	at coldfusion.orm.hibernate.HibernateConfiguration.initHibernateConfiguration(HibernateConfiguration.java:226)
	at coldfusion.orm.hibernate.HibernateConfiguration.<init>(HibernateConfiguration.java:183)
	at coldfusion.orm.hibernate.ConfigurationManager.initConfiguration(ConfigurationManager.java:67)
	at coldfusion.orm.hibernate.HibernateProvider.InitializeORMForApplication(HibernateProvider.java:184)
	at coldfusion.orm.hibernate.HibernateProvider.beforeApplicationStart(HibernateProvider.java:80)
	at coldfusion.filter.ApplicationFilter.fireBeforeAppStartEvent(ApplicationFilter.java:575)
	at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:306)
	at coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:48)
	at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:40)
	at coldfusion.filter.PathFilter.invoke(PathFilter.java:112)
	at coldfusion.filter.LicenseFilter.invoke(LicenseFilter.java:30)
	at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:94)
	at coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:28)
	at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
	at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:58)
	at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
	at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:22)
	at coldfusion.filter.CachingFilter.invoke(CachingFilter.java:62)
	at coldfusion.CfmServlet.service(CfmServlet.java:219)
	at coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:89)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
	at coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringServletFilter.java:42)
	at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:46)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:218)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110)
	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
	at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:962)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:466)
	at org.apache.coyote.ajp.AjpProcessor.process(AjpProcessor.java:197)
	at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637)
	at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.lang.Thread.run(Thread.java:722)
Caused by: java.sql.SQLException: 'jldp_latest.programmesjldp' is not BASE TABLE
	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1062)
	at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4187)
	at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4119)
	at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2570)
	at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2731)
	at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2793)
	at com.mysql.jdbc.StatementImpl.executeUpdate(StatementImpl.java:1795)
	at com.mysql.jdbc.StatementImpl.executeUpdate(StatementImpl.java:1709)
	at coldfusion.server.j2ee.sql.JRunStatement.executeUpdate(JRunStatement.java:193)
	at org.hibernate.tool.hbm2ddl.SchemaUpdate.execute(SchemaUpdate.java:204)
	... 43 more

Ancient Programmer

unread,
Nov 14, 2017, 2:21:54 AM11/14/17
to ColdBox Platform
My experience in ORM is novice. I believe the Data Definition Language (DDL) was generated by ORM. You probably could find a clue by examining the generated DDL from log files; and then fix your ColdFusion ORM code accordingly. If you have Fusion Reactor, you could find the error details under JDBC.

echo

unread,
Nov 14, 2017, 2:41:22 AM11/14/17
to ColdBox Platform
Yes, I have been looking through the orm stuff. And some said just turn off ddl function. I am confused whether it works on lucee but fail on cold fusion 10.

I am not sure how to find the ddl log. I am trying to install fusion reactor and see what's going one. Thank you so much.

Jon Clausen

unread,
Nov 14, 2017, 7:21:09 AM11/14/17
to col...@googlegroups.com

A few notes:

 

  1. Do a search for `BASE TABLE` in your code.  It appears that you have a “table” component attribute in one of your ORM entities that references that.  If that component is a superclass, that shouldn’t have its own table, then make sure you mark it as `persistent=”false”` and set `mappedSuperclass=”true”` in the component attributes.   If I remember correctly, the ORM implementation in ACF10 would assume a component as persistent with only the table attribute specified.
  2. If not the above, then you likely or you likely have an incorrectly mapped relationship, search for a reference to `BASE TABLE`, again.
  3. Coldfusion 10 is now end-of-life, and is no longer supported by Adobe and will not be supported in Coldbox 5.   The ORM implementation for Lucee is a closer equivalent to ACF 11 and 2016.  If absolutely have to deploy your new application to ACF10, then I would suggest developing locally on ACF10 via CommandBox :  `server set app.cfengine=adobe@10`

Jon

--
--
You received this message because you are subscribed to the Google Groups "ColdBox Platform" group.
For News, visit http://blog.coldbox.org
For Documentation, visit http://wiki.coldbox.org
For Bug Reports, visit https://ortussolutions.atlassian.net/browse/COLDBOX
---
You received this message because you are subscribed to the Google Groups "ColdBox Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to coldbox+u...@googlegroups.com.
To post to this group, send email to col...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/coldbox/60df5c6d-63b6-45ba-9e43-6a1f88d818e9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

echo

unread,
Nov 14, 2017, 11:36:54 PM11/14/17
to ColdBox Platform
Thanks a lot for your reply and the addition suggestion. It is really helpful.
It seems there is no "base table" in my code.I tried to write a simple version with one view and one table. And I am developing this on cf10 using cb 4.3.
I think the possible issue might be some inconsistency between the view table attributes and my ormentity.cfc. 

On Tuesday, 14 November 2017 20:21:09 UTC+8, JClausen wrote:

A few notes:

 

    1. Do a search for `BASE TABLE` in your code.  It appears that you have a “table” component attribute in one of your ORM entities that references that.  If that component is a superclass, that shouldn’t have its own table, then make sure you mark it as `persistent=”false”` and set `mappedSuperclass=”true”` in the component attributes.   If I remember correctly, the ORM implementation in ACF10 would assume a component as persistent with only the table attribute specified.
    2. If not the above, then you likely or you likely have an incorrectly mapped relationship, search for a reference to `BASE TABLE`, again.
    1. Coldfusion 10 is now end-of-life, and is no longer supported by Adobe and will not be supported in Coldbox 5.   The ORM implementation for Lucee is a closer equivalent to ACF 11 and 2016.  If absolutely have to deploy your new application to ACF10, then I would suggest developing locally on ACF10 via CommandBox :  `server set app.cfeng...@10`

    Ancient Programmer

    unread,
    Nov 15, 2017, 11:19:20 AM11/15/17
    to ColdBox Platform

    echo

    unread,
    Nov 21, 2017, 8:03:22 PM11/21/17
    to ColdBox Platform
    I have found the reason is most likely because the view tables I created does not have a primary key. However, it seems the norm component requires one.
    Reply all
    Reply to author
    Forward
    0 new messages