Search fields by many values

One question: When performing a search with the filter of a module, when I search, for example, multiple values in a field, I can separate them by comma and search for more than one, like this:
Document Number: 1,2
And as a result, I get the records that match both 1 and 2.

In a custom field of the same module, of text type, I try to search with two values and there are no matches, but if I search individually, there are matches.

Why could this be happening?

I never heard of searching with lists such as β€œ1, 2”

I just tried it in Documents module, list view, search filter, and it doesn’t work.

Are you sure this feature actually exists?

Well, I’m using the SuiteCRM version 7.11.18 and if I search for two values for a field β€œX”, it works:

image

But if I search for another field with the same format, it doesn’t work.

Where can I find the files in the code that handle this search?"

Interesting, I am learning something new. It seems to work only for number fields.

I think I’ve tracked it down the 'operator' => 'in' setting in SearchFields array.

You can find it in the Case number field in Case modules, and a generic version for every field named *_number here:

SugarObjects/templates/issue/metadata/SearchFields.php

which gets handled here during search:

1 Like

Thank you for the answer. I will try to modify the code and search for more values in the string fields.
If I can do that, I will share it in this post

1 Like