Temporary solution for missing mySQL 8 support

Due to a conflict between the new reserved word GROUPS in mySQL 8 and a table named Groups in RT it is currently not possible to use RT with mySQL 8

However, I have managed to do it anyway by a few changes in RT 4.4.4

In the RT perl code I have changed the tablename “Groups” to “Groups” (enclosed in backticks) a number of places and in SearchBuilder.pm _GetAlias added a statement to remove backticks when generating an alias.

/usr/share/perl5/vendor_perl/DBIx/SearchBuilder.pm:1283: my $table = shift; $table =~ s/`//g;

rt4/share/html/Elements/ShowMemberships:66: TABLE2 => ‘Groups’,
rt4/lib/RT/Interface/Web.pm:4109: TABLE2 => ‘Groups’,
rt4/lib/RT/SearchBuilder/Role/Roles.pm:123: TABLE2 => ‘Groups’,
rt4/lib/RT/Report/Tickets.pm:547: push @{ $res{’Groups’} }, $group_by->{‘NAME’};
rt4/lib/RT/Test.pm:757: FIELD1 => ‘GroupId’, TABLE2 => ‘Groups’, FIELD2 => ‘id’,
rt4/lib/RT/Group.pm:79:sub Table {’Groups’}
rt4/lib/RT/User.pm:1735: TABLE2 => ‘Groups’,
rt4/lib/RT/User.pm:2838: TABLE2 => ‘Groups’,
rt4/lib/RT/Principal.pm:578: " FROM Groups, Principals, CachedGroupMembers WHERE "
rt4/lib/RT/Groups.pm:79:sub Table { ‘Groups’}

I have not done sufficient testing to verify, that thís is sufficient, but I do have access to the messages.
The rt-validator will need some careful updating.

1 Like