Documentation Request: Clarity around searchable field types #5553
Unanswered
bkuhl
asked this question in
Ideas & Feature Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have a system where it's very common we look up resources by an external ID. The IDs are stored as integers within the database and not a string, which means they don't work well with the global search on some occasions. For example, if I search for
1054541801417093100no results are found, but if I search for10545418014170931it does find a record, even when1054541801417093100is the actual value in the database. I confirmed there's nothing funky happening to the value (e.g. number being changed due to int conversion) or anything, it seems to be mysql's fault. The solution I came up with was to remove the value from the search field:and instead add a custom condition:
This generates the following SQL when searching:
I think it might be good to update the phpdoc for
$searchto explain that it's for string/text fields and not integers.Beta Was this translation helpful? Give feedback.
All reactions