Forum Discussion
How to map User Profile to ECT field
- Nov 12, 2017
Problem solved! :)
Is it possible for you to share it?
You have 2 choices:
1. Use simple string with the name of the user. When you map such crawled property with managed property that keeps user information (i.e. Author) refiners will merge those information together
2. Use lookup notation. User fields are strings that are a lookup value to a user. Lookup notation is like <id>;#<display name> so i.e. "20;#Test User". This notation still makes refiners to display user names (i.e. Author will display only "Test User", without "20;#") and moreover you can pass ID in order to manage behavior on click (on custom BCS profile page).
Check my sample screen below.
I've created example list with some Title and UserString field that is simple text line. I fill it with some values (+ run crawl. Crawled property of that field mapped to Author managed property). Then I use search to get all list items. Observations:
- there are 2 different notations for test user, both merged and pretty rendered.
- you can pass "-1" for users that doesn't exist in UPS
- I intentionally made a typo ("#;" instead of ";#") - for that user refiner didn't take just username but whole string.
Hope it's clear. If not - ask :)