Won't Fix
Pinned fields
Click on the next to a field label to start pinning.
Details
Assignee
SE SupportSE SupportReporter
Sergio AlonsoSergio AlonsoFix Priority
3Bug Type
Database UpgradeComponents
Priority
Medium
Details
Details
Assignee
SE Support
SE SupportReporter
Sergio Alonso
Sergio AlonsoFix Priority
3
Bug Type
Database Upgrade
Components
Priority
Zendesk Support
Zendesk Support
Zendesk Support
Created March 28, 2018 at 5:35 AM
Updated June 26, 2023 at 1:54 AM
Resolved May 15, 2018 at 3:38 PM
Preconditions:
Database upgrading from 6.2 to 7.0
Some content recorded using a clob structure with a size >= 4000 bytes
RDBMS Oracle using a ojdbc7.jar driver library.
Important: There may be other RDBMS in a similar issue.
Steps to reproduce:
Launch an upgrade process from 6.2 to 7.0 using Liferay upgrade client.
Upgrade process ends without any errors.
Some entities generate errors during upgrade because of data retrieval is truncated.
Example:
Caused by: com.liferay.portal.kernel.xml.DocumentException: Error on line 66 of document : XML document structures must start and end within the same entity. Nested exception: XML document structures must start and end within the same entity. at com.liferay.portal.xml.SAXReaderImpl.read(SAXReaderImpl.java:408) at com.liferay.portal.xml.SAXReaderImpl.read(SAXReaderImpl.java:384) at com.liferay.portal.xml.SAXReaderImpl.read(SAXReaderImpl.java:419) at com.liferay.portal.kernel.xml.SAXReaderUtil.read(SAXReaderUtil.java:165) at com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal.convertStaticContentToDynamic(UpgradeJournal.java:237) at com.liferay.journal.internal.upgrade.v0_0_5.UpgradeJournal.updateJournalArticles(UpgradeJournal.java
Our code uses
java.sql.ResultSet.getString(String)
method instead of
java.sql.ResultSet.getClob(String)
for data retrieval from clob columns.
Under some context, getString(String) method gets truncated data.
See also: https://docs.oracle.com/javase/8/docs/api/java/sql/Clob.html
Oracle Support admits some bugs using getString(String) method under ojdbc7.jar driver library.
Oracle Support recommends using ojdbc8.jar driver library with at least Oracle 12.2.0.1.0 JDBC 4.2 versioning.