Field groupKey in Group table isn't create properly after upgrading to Liferay 7/DXP

Description

Steps to reproduce:

  1. Upgrade a 6.2 version to master/DXP

  2. After finishing the upgrade check the Group_ table

Results:
The type of the groupKey is longtext (mysql) or similar.

Following indexes weren't created (just in mysql):

create unique index IX_A729E3A6 on Group_ (companyId, classNameId, liveGroupId, groupKey); create unique index IX_ACD2B296 on Group_ (companyId, groupKey); create unique index IX_AACD15F0 on Group_ (companyId, liveGroupId, groupKey);

Because mysql only supports a maximum of 255 characters for field indexes:

com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: BLOB/TEXT column 'groupKey' used in key specification without a key length

Expected results:
The type of the field groupKey is VARCHAR(150)

The previous indexes are created.

Activity

Show:

Linda Sui January 4, 2017 at 5:40 PM

PASSED Manual Testing following the steps in the description.

Fixed on:
Upgrade from: 6.2 EE SP17.
Tomcat 8.0.32 + MySQL 5.6. Portal ee-7.0.x GIT ID: 7cb6ea6d515ef1d0ae862266793940ce3775d3d9.

The type of the groupKey is changed to VARCHAR.

Linda Sui December 28, 2016 at 10:14 PM
Edited

PASSED Manual Testing following the steps in the description.

Fixed on:
Upgrade from: 6.2 CE GA6.
Tomcat 8.0.32 + MySQL 5.6. Portal master GIT ID: bac1ecb4d371884a83175faa4157dcce0cbfe3d9.

The type of the groupKey is changed to VARCHAR.

Note: Can check data type as the following command

select * from information_schema.columns where table_schema = 'dbname' and table_name = 'tablename';

Miguel Ángel Pastor Olivar December 28, 2016 at 1:30 AM

Just started reviewing migue/liferay-portal#921.

 

Sent from GH

Fixed
Pinned fields
Click on the next to a field label to start pinning.

Details

Assignee

Reporter

Branch Version/s

7.0.x

Backported to Branch

Committed

Fix Priority

3

7.0 Fix Pack Version

10

Story Points

Priority

Zendesk Support

Created December 27, 2016 at 8:00 AM
Updated June 25, 2023 at 11:55 PM
Resolved January 4, 2017 at 9:57 AM