Forum Discussion
PNP Modern Search People - Show Department/Office as filter
- Sep 07, 2022
For that managed property is the OfficeNumber If you want to get only value but you can't use it for refiners.
You have to map "People:Office" crawled property to any RefinableString*** managed property and then you could use it in refiners.
Important: It might take some time to fill RefinableString managed property which you use for existing user profile (According to my past experience it took 2 days !!!).
Hope it will helpful to you and if so then Please mark my response as Best Response & Like to help others in this community
You can try below default Managed Properties which worked fine for me
It will show values from below mentioned OOTB user profile properties so make sure these property contains values.
Another thing, above mentioned property would not able available as suggestion in Filter Field drop down but as it's combo box still you can enter it manually as shown below
Below is the output of search result
Hope it will helpful to you and if so then Please mark my response as Best Response & Like to help others in this community
- EMIL_K_DITSep 07, 2022Brass Contributor
kalpeshvaghela Thanks for your reply! Yes I have tried these but will give it another spin.
Where is this screenshot from? I can't seem to find a similar one in my console.- kalpeshvaghelaSep 07, 2022Steel Contributor
Screen shot is from SharePoint User Profile and follow below steps to open it
Open your SharePoint Admin Center using URL https://{TenantName}-Admin.SharePoint.com
Go to More Feature and Click on User Profile
Click and User Profile and Search for any user
Click on Edit Profile Property and the screen shot which I shared it taken from here.
- EMIL_K_DITSep 07, 2022Brass Contributor
Thanks!
I can see the variable I want to get is in fact, Office.
In your example that's 131/1104. Do you have any idea how I can find out what this is in the search schema?