As far as I know, the record search box on a record-backed gridField will do a search on the raw data of all of the columns in the grid. For example, searching for "username1" will return any rows that contain "username1" in any of the columns' raw data, regardless of how the data is formatted. If the column data was formatted to show First Name or Last Name, a search for "username1" would still return the row; however a search for the First Name value or Last Name value would not return any results, as this is a formatted value and not the raw value.
I have a requirement for the search box to enable searching on first name and last name values, not only username. Are there any elegant solutions to enable this?
The only ideas I have are not very elegant:
Discussion posts and replies are publicly visible
Using custom fields on a record type you can create separate fields for first name and last name. This removes the need to update a view or CDT.
This does not solve this issue. This issue is that the Appian record search does not return matches on formatted values (i.e. values generated by passing the data into an expression). In your proposed solution, the username value will be formatted to first and last name display values, using the user() function. The native search only searches on the raw data, in this case, the username. So even though the column displays "Wen" for first name, the data that backs that column is a username "whuynh", so searching "Wen" won't return this row. A search for "whuynh" will return the row. Does that make sense?
Starting in Appian 21.2 we have custom fields on record types which are different than fields you format on the grid.
https://docs.appian.com/suite/help/21.2/custom-record-fields.html
When referencing these fields, the search bar will pick up these fields
Brilliant as usual. Thanks, Danny!
Danny, we've upgraded to 20.3 and I tried to implement this; however, 20.3 does not support the user() function in custom record fields. Do you know when function, rule, and relationships for custom record fields will be supported?