Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow underscore in search fields, more #1213

Closed
jacobwod opened this issue Oct 13, 2022 · 1 comment
Closed

Allow underscore in search fields, more #1213

jacobwod opened this issue Oct 13, 2022 · 1 comment
Assignees
Projects
Milestone

Comments

@jacobwod
Copy link
Member

#1187 made some changes to which fields are considered valid in Admin. Unfortunately we missed some characters. As of now I've identified the underscore as missing, which leads to this:

Skärmavbild 2022-10-13 kl  10 49 43

@jacobwod jacobwod added this to the 3.x milestone Oct 13, 2022
@jacobwod jacobwod self-assigned this Oct 13, 2022
@jacobwod jacobwod added this to Approved ideas in Hajk via automation Oct 13, 2022
@jacobwod
Copy link
Member Author

I was about to settle on this description of SQL standard:

SQL identifiers and key words must begin with a letter (a-z, but also letters with diacritical marks and non-Latin letters) or an underscore (_). Subsequent characters in an identifier or key word can be letters, underscores, digits (0-9), or dollar signs ($).

But then I tried in our PostgreSQL and see what was possible:
Skärmavbild 2022-10-13 kl  13 03 56

So in order to ensure compatibility with existing configurations, we should allow more than what I'd expect. Especially since PostgreSQL allows more anyway, so there's a risk folks are using it.

Let's expand our current check to also allow _ and . (dot only in the middle of name - however strange it looks, it seems to be allowed as you can see above).

@jacobwod jacobwod modified the milestones: 3.x, 3.11 Oct 13, 2022
@jacobwod jacobwod moved this from Approved ideas to Done in Hajk Oct 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Hajk
  
Done
Development

No branches or pull requests

1 participant