[SOLVED] Localization with a hyphen can't be filtered on

I’m submitting a…

[ ] Regression (a behavior that stopped working in a new release)
[x] Bug report
[ ] Performance issue
[ ] Documentation issue or request

Current behavior

When trying to filter on a language that contains a hyphen e.g nl-BE the OData filter is required to be in an invalid format: $filter=data/Title/nl-BE eq ‘Something’

Expected behavior

To be able to filter on these languages.

Minimal reproduction of the problem

Create a schema localized in a language with a hyphen in it’s name and try to filter on it

Environment

  • [x] Self hosted with version docker
  • [ ] Self hosted with IIS
  • [ ] Self hosted with other version
  • [ ] Cloud version

Browser:

  • [ ] Chrome (desktop)
  • [ ] Chrome (Android)
  • [ ] Chrome (iOS)
  • [ ] Firefox
  • [ ] Safari (desktop)
  • [ ] Safari (iOS)
  • [ ] IE
  • [ ] Edge

Others:

I noticed the same happens when you create your own property with a hyphen, but I guess I should just change the name in this case.

If you have a property with a hyphen you can just use underscore in your queries.

Fix is in the CI pipeline.

Thank you. The underscore works fine. I’ll wait for the fix for the languages.

It might take a little bit longer because github is not fully operational: https://status.github.com/messages

Hi, the fix has been deployed. You also have to use underscore for languages, so replace de-AT with de_AT.