bogeblad / infoglue

Infoglue is a enterprise grade Java WCMS
www.infoglue.org
79 stars 67 forks source link

Infoglue 3.3.0 issue on startup (Oracle) #131

Open carlos-alonso opened 10 years ago

carlos-alonso commented 10 years ago

After building the binaries from git we found this error on startup

org.exolab.castor.jdo.PersistenceException: Nested error: java.sql.SQLSyntaxErrorException: ORA-00933: SQL command not properly ended while executing select sn.siteNodeId, sn.name, sn.publishDateTime, sn.expireDateTime, sn.isBranch, sn.isDeleted, sn.parentSiteNodeId, sn.metaInfoContentId, sn.repositoryId, sn.siteNodeTypeDefinitionId, sn.creator, (select count(*) from cmSiteNode sn2 where sn2.parentSiteNodeId = sn.siteNodeId) AS childCount, snv.siteNodeVersionId, snv.sortOrder, snv.isHidden, snv.stateId, snv.isProtected, snv.versionModifier, snv.modifiedDateTime, 0 AS languageId, '' as attributes from cmSiteNode sn, cmSiteNodeVersion snv where snv.siteNodeId = sn.siteNodeId AND snv.siteNodeVersionId = ( select max(siteNodeVersionId) from cmSiteNodeVersion snv3 WHERE snv3.siteNodeId = snv.siteNodeId AND snv3.isActive = ?1 AND snv3.stateId >= ?2 ) order by sn.parentSiteNodeId ASC, snv.sortOrder ASC, sn.name ASC, sn.siteNodeId DESC LIMIT ?3 at org.exolab.castor.jdo.engine.SQLQuery.execute(SQLQuery.java:220) at org.castor.persist.AbstractTransactionContext.query(AbstractTransactionContext.java:613)

Doing some research it has 2 problems for Oracle versions:

I do not know exaclty where to correct the sql and the ddl of the missing table

Carlos

bogeblad commented 10 years ago

Hi Carlos,

The installation must have useShortTableNames=false in cms.properties or deliver.properties. The clause you reference are selected based on this. It should be useShortTableNames=true and all other settings must of course also be Oracle-correct. If you wait a bit more I am just in the process of committing a new addition to version 3 which makes cleaning of content-versions much easier and a new GUI to find heavy contents. I would like to use this new feature when helping you with the task I have of cleaning/analysing. Would that be ok?

Regards Mattias Bogeblad

2014-10-23 13:04 GMT+02:00 carlos-alonso notifications@github.com:

After building the binaries from git we found this error on startup

org.exolab.castor.jdo.PersistenceException: Nested error: java.sql.SQLSyntaxErrorException: ORA-00933: SQL command not properly ended while executing select sn.siteNodeId, sn.name, sn.publishDateTime, sn.expireDateTime, sn.isBranch, sn.isDeleted, sn.parentSiteNodeId, sn.metaInfoContentId, sn.repositoryId, sn.siteNodeTypeDefinitionId, sn.creator, (select count(*) from cmSiteNode sn2 where sn2.parentSiteNodeId = sn.siteNodeId) AS childCount, snv.siteNodeVersionId, snv.sortOrder, snv.isHidden, snv.stateId, snv.isProtected, snv.versionModifier, snv.modifiedDateTime, 0 AS languageId, '' as attributes from cmSiteNode sn, cmSiteNodeVersion snv where snv.siteNodeId = sn.siteNodeId AND snv.siteNodeVersionId = ( select max(siteNodeVersionId) from cmSiteNodeVersion snv3 WHERE snv3.siteNodeId = snv.siteNodeId AND snv3.isActive = ?1 AND snv3.stateId >= ?2 ) order by sn.parentSiteNodeId ASC, snv.sortOrder ASC, sn.name ASC, sn.siteNodeId DESC LIMIT ?3 at org.exolab.castor.jdo.engine.SQLQuery.execute(SQLQuery.java:220) at org.castor.persist.AbstractTransactionContext.query(AbstractTransactionContext.java:613)

Doing some research it has 2 problems for Oracle versions:

  • Oracle does not have the "LIMIT" clause that is MySql.
  • The table "cmSiteNodeVersion" is new (it does not exists on version 3.1)

I do not know exaclty where to correct the sql and the ddl of the missing table

Carlos

— Reply to this email directly or view it on GitHub https://github.com/bogeblad/infoglue/issues/131.

carlos-alonso commented 10 years ago

Ok, it will be nice to have this addition.

Carlos

El 23/10/2014 a las #4, Mattias Bogeblad escribió:

Hi Carlos,

The installation must have useShortTableNames=false in cms.properties or deliver.properties. The clause you reference are selected based on this. It should be useShortTableNames=true and all other settings must of course also be Oracle-correct. If you wait a bit more I am just in the process of committing a new addition to version 3 which makes cleaning of content-versions much easier and a new GUI to find heavy contents. I would like to use this new feature when helping you with the task I have of cleaning/analysing. Would that be ok?

Regards Mattias Bogeblad

2014-10-23 13:04 GMT+02:00 carlos-alonso notifications@github.com:

After building the binaries from git we found this error on startup

org.exolab.castor.jdo.PersistenceException: Nested error: java.sql.SQLSyntaxErrorException: ORA-00933: SQL command not properly ended while executing select sn.siteNodeId, sn.name, sn.publishDateTime, sn.expireDateTime, sn.isBranch, sn.isDeleted, sn.parentSiteNodeId, sn.metaInfoContentId, sn.repositoryId, sn.siteNodeTypeDefinitionId, sn.creator, (select count(*) from cmSiteNode sn2 where sn2.parentSiteNodeId = sn.siteNodeId) AS childCount, snv.siteNodeVersionId, snv.sortOrder, snv.isHidden, snv.stateId, snv.isProtected, snv.versionModifier, snv.modifiedDateTime, 0 AS languageId, '' as attributes from cmSiteNode sn, cmSiteNodeVersion snv where snv.siteNodeId = sn.siteNodeId AND snv.siteNodeVersionId = ( select max(siteNodeVersionId) from cmSiteNodeVersion snv3 WHERE snv3.siteNodeId = snv.siteNodeId AND snv3.isActive = ?1 AND snv3.stateId >= ?2 ) order by sn.parentSiteNodeId ASC, snv.sortOrder ASC, sn.name ASC, sn.siteNodeId DESC LIMIT ?3 at org.exolab.castor.jdo.engine.SQLQuery.execute(SQLQuery.java:220) at

org.castor.persist.AbstractTransactionContext.query(AbstractTransactionContext.java:613)

Doing some research it has 2 problems for Oracle versions:

  • Oracle does not have the "LIMIT" clause that is MySql.
  • The table "cmSiteNodeVersion" is new (it does not exists on version 3.1)

I do not know exaclty where to correct the sql and the ddl of the missing table

Carlos

— Reply to this email directly or view it on GitHub https://github.com/bogeblad/infoglue/issues/131.

— Reply to this email directly or view it on GitHub https://github.com/bogeblad/infoglue/issues/131#issuecomment-60236198.

carlos-alonso commented 10 years ago

And also you were right, I missed to put the useShortTableNames=true