Can’t install Hikashop Starter 5.0- Error installing component

  • Posts: 4
  • Thank you received: 1
1 year 1 month ago #355590

-- HikaShop version -- : 5.0
-- Joomla version -- : 4.3.4
-- PHP version -- : 8.2
-- Browser(s) name and version -- : chrome 17.0.5938.132
-- Error-message(debug-mod must be tuned on) -- : Warning: Illegal mix of collations (utf8mb3_general_ci, IMPLICIT) and (utf8mb3)unicode)ci, IMPLICIT) for operation ‘=‘
Error installing component

Got this message when trying to install Hikashop Starter 5.0.

Warning: Illegal mix of collations (utf8mb3_general_ci, IMPLICIT) and (utf8mb3)unicode)ci, IMPLICIT) for operation ‘=‘
Error installing component

Only database tables was created and the Hikashop extension in administer folder.

I droped all the Hikashop tables from the DB and tried to uninstall the extension to do a clean install from the ftp as suggested in some articles.

Got an error with a message saying: can’t uninstall, please remove manually. I checked in all the folders listed in the message and no com_hikashop exist there but Joomla still show the extension.

I decided to manually created these com_hikashop folders and redo the Extension uninstall process. Joomla removed all the folders but I got a new message like din’t find Filesetup.XML.

Finally I moved forward with the FTP installation with exactly the same result

Warning: Illegal mix of collations (utf8mb3_general_ci, IMPLICIT) and (utf8mb3)unicode)ci, IMPLICIT) for operation ‘=‘
Error installing component

I don’t know what else to do to try to fix this issue. If somebody have an idea, you’re welcome.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
1 year 1 month ago #355591

Hi,

This error message indicates that during the installation process, HikaShop runs a MySQL query on several tables of Joomla (or one of Joomla and one of HikaShop) and the collation of the tables is not compatible even though it should normally be (since it works for everyone else).
So potentially, something or someone on your end changed the normal collation of the Joomla tables for some reason in the past, which led to this unexpected error message.
Unfortunately, the error message doesn't provide the MySQL query creating the problem, nor the line number and file path of the PHP code running that MySQL query. Also, it's the first time someone report this exact error message. So I'm not sure what to do exactly to avoid the problem.

It would be great to get the MySQL query causing the error with such modification:
Please edit the file libraries\vendor\joomla\database\src\Exception\ExecutionFailureException.php
and change the line:
parent::__construct($message, 0, $previous);
by:
parent::__construct($message.' '.$query, 0, $previous);
Then, when you run again the installation, this error message will also display the MySQL which generated the error, which will help us understand why this error is happening, so that we can tell you what to do.

Please Log in or Create an account to join the conversation.

  • Posts: 4
  • Thank you received: 1
1 year 1 month ago #355601

Hi Nicolas,

First thanks for your help. it is really appreciate.

1- Using PHP MyAdmin I remove all traces of the old installation.

2- I change the code line in ExecutionFailureException.php
public function __construct($query, $message = '', $code = 0, \Exception $previous = null)
{
// PDO uses strings for exception codes, PHP forces numeric codes, so "force" the string code to be used
parent::__construct($message.' '.$query, 0, $previous);

3- I relaunch the installation process from FTP folder with exactly the same result. No change same message without additional information about the error.

So we are at the same place.

I read an old post about the illegal mix of collation where you suggest to make sure that the hikashop_user table or the users table of Joomla have the same charset. Maybe I can start with that to eliminate this warning.

Please Log in or Create an account to join the conversation.

  • Posts: 4
  • Thank you received: 1
1 year 1 month ago #355603

I just checked My database and All the tables including the ones Hikashop created have utf8mb3_general_ci charset except 8 tables including 4 from Akeebabackup that use utf8mb4_unicode_ci. Furthermore, the server connection collation charset is set to utf8mb4_unicode_ci. Nothing about utf8mb3_unicode_ci Charset from the conflict message!!!!

Do I have to change something on these?

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
1 year 1 month ago #355602

Hi,

I suppose that you're talking about this:
www.hikashop.com/forum/install-update/90...to-4-2-5/347276.html
However, there, both collations mentioned in your error message are different. That is strange and it shouldn't be the case if it was a similar issue.
You can try to remove the piece of code and try again, as I said there, but I'm not confident the problem is from there. But we never know...

The error message says that there is a problem between utf8mb3_general_ci and utf8mb3_unicode_ci

So tables with utf8mb4_unicode_ci should not be linked to the issue.

Note also that in each table, each column can have a different collation. So it's not just the collation of the tables you need to check but the collation of the columns in each table.
It's possible that some tables have the collation utf8mb3_general_ci but that some columns in them have the collation utf8mb3_unicode_ci and when HikaShop runs one of its MySQL queries between two columns, it creates that error because of the different collation of the columns.
I would first check the columns of the users table of Joomla against the columns of the hikashop_user table.

Last edit: 1 year 1 month ago by nicolas.
The following user(s) said Thank You: SolaireC

Please Log in or Create an account to join the conversation.

  • Posts: 4
  • Thank you received: 1
1 year 1 month ago #355612

Hi Nicolas,

Problem solved. You were right, the Joomla user table contained few columns with collation utf8mb3_unicode_ci. I changed them to utf8mb3_general_ci and proceed to Hikashop installation with no problem.

Thank you so much for your help.

The following user(s) said Thank You: nicolas

Please Log in or Create an account to join the conversation.

Time to create page: 0.060 seconds
Powered by Kunena Forum