Search not working

Hey dear XWiki-community,
I have set up an XWiki installation and configured the language to be german. I have created a handful of pages and other users have as well. Those pages all share the same language. If i search words which appear on all of these pages, only some of the pages I created show up (and those only show the headings, not the page content, although the word also appears there) and none of the user-created ones.
I was searching like this word (wildcards on both ends to be sure to catch all of them) and already tried re-indexing, but to no avail.
Is this a common problem? How can I fix my wiki search?

Edit: I read that the page language changes the way Solr indexes. Maybe the german language does not work well with Solr?

Solution: I had to change the language in order for Solr to index properly.

Hi, how did you change the language and to what language? I’m experiencing the same weird behaviour with Czech and English pages under one wiki.

I was using “German (Austria)” and changed it to “German” (in the wiki administration under “content” and “localisation”).
All the pages which had been created in “German (Austria)” had to be re-created (I copied the old page’s content from the source editor to the new page).

Thanks for your reply. I would really appreciate some explanation from the xwiki team on why this is happening :slight_smile:. Recreating pages seems impossible to me, there’s many hundreds of them that would need it.

Maybe there’s another way. I am new to XWiki and could not find a quick way of changing a page’s language, unfortunately.
Depending on where the wiki stores its page information, you may be able to adapt the language via SQL or a multi-“search and replace” in the file system (e.g. via notepad++).

Changing a language can be done in Edit mode, on the Information tab under the page content area. You can select Locale there.
Snímek obrazovky 2021-10-05 v 12.05.25

But only one by one, unfortunately :confused:

That’s true. I once did a bulk change of locale in the database and it worked well (although it took some time to figure out the correct query): update xwikidoc set xwd_default_language = 'cs' where xwd_default_language in ('en', 'en_US', 'cs_CZ'); COMMIT;

1 Like