Jump to content

Error when adding new page with non-ascii characters in a page field


Recommended Posts

Posted

I create a page reference field that allows user to create new page in the page edit page. I got this error:

Error adding page "一二三" - SQLSTATE[HY000]: General error: 1267 Illegal mix of collations (ascii_general_ci,IMPLICIT) and (utf8_general_ci,COERCIBLE) for operation '='

 think it worked fine before I upgraded to 3.0.115.

Any idea?

Gideon

Posted

Hi,

I think this is a bug in the Page Reference field  which was introduced after core version 3.0.106. I tested it with both multi-language and single language setting. Both of them give the same error when trying to create a page with non ASCII page name in the page edit page. Should I report this to the github bug issue?

Gideon

Posted

Hi,

After testing with different version of the core. I found that the creation of page in page field function normally up to 3.0.110. It doesn't work anymore from 3.0.111. I will file a bug report to github.

Gideon

  • Like 1
  • 2 weeks later...
Posted

I've added a few details about the cause of the expection to the issue. In short, the pages.name table is created with an ascii charset by the installer, which should probably be changed.

As a workaround, after installation, execute the following statement:

ALTER TABLE pages MODIFY COLUMN `name` varchar(128) character set utf8 NOT NULL;

(Change utf8 to utf8mb4 if you selected that character set in the installer)

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...