Foren

Database - Data too long for column 'title'

Mattia Possenti, geändert vor 12 Jahren.

Database - Data too long for column 'title'

Junior Member Beiträge: 35 Beitrittsdatum: 19.04.11 Neueste Beiträge
Hi folks,
I have a question about lportaldatabase on liferay 5.2.3
have a problem in publishing the pages that require encoding with special characters like russian or chinese. When I publish a page I get this error in server logs.

[#|2011-12-20T15:26:52.328+0100|INFO|sun-appserver2.1|javax.enterprise.system.stream.out|_ThreadID=30;_ThreadName=TP-Processor16;|15:26:52,326 ERROR [JDBCExceptionReporter.logExceptions():101] Data truncation: Data too long for column 'title' at row 1 |#]

The error is clear enough, the column title is too short for the title encoded in chinese/russian
I have increased the column title from varchar(250) to longtext (utf8_general_ci) both in Layout and JournalArticle tables
Even with this modification I get the error.

Someone of you has had a similar issue? Is there any limitation at application level in liferay code?

Many thanks

Mattia
thumbnail
David H Nebinger, geändert vor 12 Jahren.

RE: Database - Data too long for column 'title'

Liferay Legend Beiträge: 14919 Beitrittsdatum: 02.09.06 Neueste Beiträge
The title should not be localized, as it is really just used for selecting the journal article for display.

The content, however, can be localized and will display in the appropriate language.
Mattia Possenti, geändert vor 12 Jahren.

RE: Database - Data too long for column 'title'

Junior Member Beiträge: 35 Beitrittsdatum: 19.04.11 Neueste Beiträge
I have found the issue.
If I let manage the connection to the database to liferay, in the portal-ext.properties file, I got the error. If I let my application server (glassfish) to handle database connection then I don't have the issue.
Now I've to understand why letting liferay manage the connection doesn't allow me to publish page.