Global Search not working for Custom Field Choice Sets #8963

Closed
opened 2025-12-29 20:43:24 +01:00 by adam · 1 comment
Owner

Originally created by @jonasnieberle on GitHub (Dec 14, 2023).

Deployment Type

Self-hosted

NetBox Version

v.3.6.6

Python Version

3.8

Steps to Reproduce

I tested the search in my private netbox instance and also tested the search in the public demo.
The screenshots are from the public demo.

Create a custom field choice set:

image

Create a custom field and select the custom field choise set:

image

Edit vlan and select one entry from the custom field:

image

Search in the global search for the selected entry:

image

Expected Behavior

The global search should show the vlans with the searched entry from the custom field choice set.

Observed Behavior

The global search not show the searched custom field choice set entry.

Originally created by @jonasnieberle on GitHub (Dec 14, 2023). ### Deployment Type Self-hosted ### NetBox Version v.3.6.6 ### Python Version 3.8 ### Steps to Reproduce I tested the search in my private netbox instance and also tested the search in the public demo. The screenshots are from the public demo. Create a custom field choice set: ![image](https://github.com/netbox-community/netbox/assets/100405740/ea6d1572-6b14-42c7-86f3-0c39729397e2) Create a custom field and select the custom field choise set: ![image](https://github.com/netbox-community/netbox/assets/100405740/a9e85f45-f7a0-4904-b32e-b67a1e5baecf) Edit vlan and select one entry from the custom field: ![image](https://github.com/netbox-community/netbox/assets/100405740/77bb5015-8b61-4050-b3d5-b8dfe40f21ed) Search in the global search for the selected entry: ![image](https://github.com/netbox-community/netbox/assets/100405740/0ba7b19d-f68f-4724-bed1-81701ff525a6) ### Expected Behavior The global search should show the vlans with the searched entry from the custom field choice set. ### Observed Behavior The global search not show the searched custom field choice set entry.
adam closed this issue 2025-12-29 20:43:24 +01:00
Author
Owner

@jeremystretch commented on GitHub (Dec 14, 2023):

The global search engine does not search against choice fields, either core or custom. This is because pre-defined choices are inherently not unique and thus easily pollute search results. Instead, you can filter the list of objects by the desired custom field value.

@jeremystretch commented on GitHub (Dec 14, 2023): The global search engine does not search against choice fields, either core or custom. This is because pre-defined choices are inherently not unique and thus easily pollute search results. Instead, you can filter the list of objects by the desired custom field value.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#8963