43
Views
7
Comments
mobile search with UTF-8 characters not working (æøå)
Application Type
Mobile

Hi. 

I cannot search for words which contains the "æ, ø, å" letters from the UTF-8 Charset with a "like" statement on client site for a mobile app.

I am doing the following: 

I got at local aggregate that displays a list of items. Each item has a item description. These descriptions are using characters from the UTF-8 charset.  (æøå) 

The filter of the aggregate looks like this: 

LocalItem.ItemDescription like "%" + Search + "%"

Lets sat i have a description called: "MINIRAL MASKE TIL MÆND", and i search on "MÆND" then it will not bring any results.  When i do the same search on server side from service studio I get the desired result.

It seems to me that the local storage are using a different Charset then on the server side? 


Any idea of what i might be doing wrong ? 


2021-09-15 19-52-45
Tiago Correia

Good Morning Thomas!

Just to make it clear, when you open the local aggregate without any filter you can see the example "MINIRAL MASKE TIL MÆND" rigth?



2020-09-10 06-03-37
Thomas Sandager Eldrup

Yes. 

I can see the record in the list when there are no filter. But i cannot search for the letters Æ, Ø or Å that are contained in the record. everything else works like a charm. :) 

2021-09-15 19-52-45
Tiago Correia

Did you tryed while debugging or try to set a assign?

I created a local storage, inserted the record "MINIRAL MASKE TIL MÆND" and then got a aggregate with the filter "LocalEntity1.Attribute1 like "%" + "Æ" + "%"" and worked like a charm.

You cannot see the preview in local storage because the studio doesn't know the data in each device, but in runtime it will work.

I hope that fix your problem, if you have any more problems with that just ask!


Best regards,


Tiago Correia

2020-09-10 06-03-37
Thomas Sandager Eldrup

I can search for it when i search directly in the aggregate server side. But when i create a search field in a mobile app, distribute the app, and try to search out the name on the app (Android) i doesn't work. 

So, I can search the result on the "server side" but now on the "local" side in run time. 


2021-09-15 19-52-45
Tiago Correia

I tried and works, in the desktop emulator and in the android app.

Did you refresh the local entity aggregate in the "on change" event of the search field? And then assign the new value for expresion?

2020-09-10 06-03-37
Thomas Sandager Eldrup

Yes i do refresh the aggregate in the "on change" event. This is wired. 

Here is my results: 

In app search: 

when typing just "M" i can se the record. when typing "MÆ" it is gone.,


How it look backend: 


:/

2021-09-15 19-52-45
Tiago Correia

Strange..mine it's working fine...
All records 

Searched records 

Can you send the Oml?

Check the max. records in the refresh maybe?

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.