DB2 SQL Errors during the database creation
How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!
While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.
Legacy Article
You are viewing an article from our legacy "FastTrack"
publication program, made available for informational purposes. Articles
in this program were published without a requirement for independent
editing or verification and are provided"as is" without
guarantee.
Before using any information from this article, independently verify its
suitability for your situation and project.
Issue
- There are DB2 SQL errors during the database creation in the server startup, causing messages in the log like the following:
2019-09-19 07:38:30.286 ERROR [main][ReleaseManagerOSGiCommands:93] bundle com.liferay.portal.upgrade.impl:3.0.6 (143)[com.liferay.portal.upgrade.internal.release.osgi.commands.ReleaseManagerOSGiCommands(410)] : The activate method has thrown an exception
com.liferay.portal.kernel.upgrade.UpgradeException: Bundle com.liferay.portal.workflow.metrics.service_1.0.3 [928] has invalid content in tables.sql:_create table WorkflowMetricsSLADefinition (_ mvccVersion LONG default 0 not null,_ uuid_ VARCHAR(75) null,_ workflowMetricsSLADefinitionId LONG not null primary key,_ groupId LONG,_ companyId LONG,_ userId LONG,_ userName VARCHAR(75) null,_ createDate DATE null,_ modifiedDate DATE null,_ name STRING null,_ description TEXT null,_ duration LONG,_ calendarKey VARCHAR(75) null,_ processId LONG,_ processVersion VARCHAR(75) null,_ pauseNodeKeys VARCHAR(75) null,_ startNodeKeys VARCHAR(75) null,_ stopNodeKeys VARCHAR(75) null,_ status INTEGER_); [Sanitized]
at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.upgrade(InitialUpgradeExtender.java:179)
[..]
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:350)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:492)
Caused by: com.ibm.db2.jcc.am.SqlSyntaxErrorException: DB2 SQL Error: SQLCODE=-601, SQLSTATE=42710, SQLERRMC=JOSE.WORKFLOWMETRICSSLADEFINITION;TABLE, DRIVER=4.26.14
at com.ibm.db2.jcc.am.b7.a(b7.java:810)
[..]
at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:344)
[..]
at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.upgrade(InitialUpgradeExtender.java:175)
... 122 more
2019-09-19 07:38:33.573 INFO [main][SystemCheckOSGiCommands:54] System check is enabled. You can run a system check with the command "system:check" in Gogo shell.
19-Sep-2019 07:38:34.996 INFO [main] org.apache.catalina.startup.Catalina.start Server startup in [54,546] milliseconds
- Request on browsers can return a blank page with the next error:
An unexpected system error occurred.
java.lang.NullPointerException
Environment
- Liferay Portal and DXP versions with their supported DB2 versions.
Did this article resolve your issue ?