What search support is available for Chinese characters?

I search some Chinese characters after I chat with someone, but not all of Chinese characters can be found.
I use docker run mattermost/platform, then I try to change mysql default charset to utf8, but I still can’t search some Chinese characters like ‘中文’.
So, what can I do for searching Chinese characters?

Hi @itwesley,

Just wondering are you running off the 0.5.0 or 0.6.0 release? We added UTF-8 as the default in 0.6.0.

To answer your question:
The search in our system is not yet very sophisticated and searches must be at least 3 characters. So searching ‘中文’ wouldn’t work but ‘中文中’ would. This makes sense for English but I understand for Chinese, and some other languages, this is far from ideal.

I’ve created a ticket to track this issue in our internal tracking system so hopefully a fix will be coming soon in one of our next releases.

1 Like

Hi @jwilander,

Appreciate for your help. I run docker(mattermost/platform:latest), is it v0.6.0?
I try to search three Chinese characters, and everything is ok.
Look forward to new release :smile:

If you’re running mattermost/platform:latest you should be getting our code as it goes into the master branch so as soon as we make the change to search you should have it :smile:

Glad I could help and let me know if you need help with anything else!

@jwilander @itwesley Just a small correction to the previous post. The mattermost/platform:latest docker tag actually points to the latest release. Right now that is v0.6.0. If you want the latest master, the tag is mattermost/platform:dev.

Hi @crspeller,
I got it. Thanks :smile:

I tried local installation on Mac. Searching Chinese characters is still problematic: It has to be three characters above, the search only matches for whole sentence, for example, the message is "中文中文“, if you search "中文” then there is no match, you have to input entire "中文中文“ in search field to get correct search result.

Hi @netsat,

There’s new documentation available for how to configure your database to search for Chinese characters. This is a new draft, would you be open to trying out these instructions and sharing feedback on your experience?