Import Error --> WARNING: [2] mb_convert_encoding(): Unknown encoding on line 388 in file /include/Localization/Localization.php

Hi @all,

I hope that someone can help me with the following issue:

Action:

  • trying to import csv
  • import ends with error: WARNING: [2] mb_convert_encoding(): Unknown encoding “UTF-8_general_ci” on line 388 in file /include/Localization/Localization.php

already tried:

  • searched google and forum last 3 days --> nothing found so far
  • added “UTF-8_general_ci” to Localization.php -> no change --> reversed the change
  • changed collation of csv --> doesn’t work
  • tried test-data in other modules --> same issue
  • searched for errors in config.php and config_override.php --> nothing found

System:

  • Suitecrm Version 7.11.8; Sugar Version 6.5.25 (Build 344)

  • modification as needed for german umlaute:

  1. database collation utf8 general_ci
  2. php.ini defasult_charset utf-8
  3. Export changed in Admin-> Localization-> standard import and export: UTF-8 collation: utf8_general_ci
  4. config.php:

‘dbconfigoption’ =>
array (
‘persistent’ => true,
‘autofree’ => false,
‘debug’ => 0,
‘ssl’ => false,
‘collation’ => ‘utf8_general_ci’,
),
‘default_action’ => ‘index’,
‘default_charset’ => ‘UTF-8_general_ci’,

Suitecrm.log:
Wed Nov 06 12:04:53 2019 [8915][8501433c-5ced-436d-60ed-5cd1555f79fa][FATAL] Caught error: mb_convert_encoding(): Unknown encoding “UTF-8_general_ci”
Wed Nov 06 12:04:54 2019 [8915][8501433c-5ced-436d-60ed-5cd1555f79fa][FATAL] Caught error: stat(): stat failed for upload/import/status_8501433c-5ced-436d-60ed-5cd1555f79fa.csv
Wed Nov 06 12:04:54 2019 [8915][8501433c-5ced-436d-60ed-5cd1555f79fa][FATAL] Caught error: touch(): UploadStream::stream_metadata is not implemented!

php log:
-empty

Can someone please guide me in a direction to solve this issue?

Kind regards, Dave

Hi,
Can you also share the CSV files you are going to import? What is your Office Version?

While import are all the special UTF-8 characters appearing properly in import Wizard?

Can you please implement one thing

Instead of

'default_charset' => 'UTF-8_general_ci',

Can you please use

 'default_charset' => 'UTF-8',

in config.php file and then repair and rebuild the CRM and then try data import??

Thanks

https://suitecrm.com/suitecrm/forum/suitecrm-7-0-discussion/19206-problems-importing-in-utf-8-displaying-french-arabic-and-other-characters

check this OUT, may be this will help you after implementing the change that i have mentioned above if thing do not gonna fixed.

Thanks

‘default_charset’ => ‘UTF-8’, --> This was the correct solution. Thank you for your help thumbsup

1 Like

You are most welcome