Searching by user details

AI-generated summary

The discussion revolves around searching users by their profile details on Discourse. Plabforum is facing an issue where the search function is limited in this respect, particularly for custom user fields like exam dates. Despite the fields being indexed, the search results only show a few users and prioritize topic and post searches over user profile details.

Plabforum provided an example where users have their exam dates visible in their profiles, but the search function only returns results for username searches. RGJ asked for clarification on how the exam dates are stored, and Plabforum explained that they are in a custom field created during sign-up.

Canapin shared relevant links to similar discussions on meta.discourse.org, including one about searching with custom user fields. Plabforum mentioned enabling the feature but still facing issues.

RGJ demonstrated the problem by showing that searching for a custom field value does not return any results. JammyDodger suggested a possible time-lag or formatting issue, but Plabforum clarified that the exam dates are searchable and indexed, and the issue lies in the search function’s limitation to only three categories: topics, tags, and usernames.

My platform heavily depends on searching users by there profile details.
But on Discourse you dont get that much flexibility and only limited search through user details.

How to fix that?

This might be a feature request, if you mean profile information on discourse isn’t indexed by the built in search function?

It is indexed but not all of it and very less flexibility.

Not indexed at same level as search function works for topics and posts.
That’s an issue for my site.

Can you give a few examples where you find Discourse is limited in this respect?

My site help people connect with similar exam dates.

All users in there profile have there exam date visible but used search function to find users by there exam dates, it only show a drop down of 5-6 users but when searched it shows the search from the topics. The search function is able to recognise the specific details from user’s profile details but it can only produce results for username searches.

I hope this makes sense.

How? Is it in a field or in their bio or…?

In the field that I had created during sign up, which is editable and visible in there user card.

The same thing was asked here:

And here:

edit: The 2nd one is mentioning specifically the API so you can ignore this link, though it’s a bit of the same feature in core as the search uses the API.

I have enabled that

The problem is that if I do this

and then fill in a value and search for it

it does not return any results.

I think there can be a time-lag between filling in the custom field and it appearing in the search, if that could be an issue? (I think the job runs every hour or so) - Are the custom fields searchable in the user directory? - #12 by JammyDodger

It also doesn’t like special characters so much, so maybe it could be the format of the exam date entered? - Multiselect Custom User Field not appearing in Search? - #3 by MichelleBasey

Exam dates are searchable, details filled in custom field of user field show up during users sign up as a question. For example, the custom field was exam date, so during sign up user will write there date.

This dates are searchable and indexed in search forum, that’s not the problem.

Problem is, the search function works for topics, tags and username- only this three categories. So the complete search for a detail in user’s profile is not accessible but searchable.