i:0#.w|Ali.Mazaheri

SharePoint, SharePoint and SharePoint!

Importing SharePoint user profile multi-value properties using BCS

Importing SharePoint user profile multi-value properties using BCS

  • Comments 1

I was asked by one of my customers to help troubleshooting why they could not import multi-value values for user profiles using BCS in SharePoint 2010, first of all this TechNet article and Spence Harbar’s blog have a lot of good information on planning augmenting user profiles using BCS in SharePoint 2010 which is highly recommended if you have not looked at yet. In this case customer had a BCS model which had “Read Item” and “Read List” methods implemented and simply returning data as “UserID” (Same value as Windows account name map to identifier) and “Skill” (one or more), the issue was when trying to create the sync the option to for “1:many mapping”  was disabled:

image

and they were only allowed to do a 1 –> 1 mapping and hence only importing the first skill into “Skills” user profile property!

image

As I was reviewing the BDCM file I noticed that the comparison filter for “UserID” was missing, after adding the “FilterDescriptor” :

<FilterDescriptors> 
                <FilterDescriptor Type="Comparison" FilterField="UserID" Name="UserID"> 
                  <Properties> 
                    <Property Name="UsedForDisambiguation" Type="System.Boolean">false</Property> 
                    <Property Name="IsDefault" Type="System.Boolean">false</Property> 
                    <Property Name="CaseSensitive" Type="System.Boolean">false</Property> 
                    <Property Name="Comparator" Type="System.String">Equals</Property> 
                    <Property Name="UseValueAsDontCare" Type="System.Boolean">true</Property> 
                    <Property Name="DontCareValue" Type="System.String"></Property> 
                  </Properties> 
                </FilterDescriptor> 
</FilterDescriptors>

and configuring the sync connection along with setting the “Filter items by” for “1:many” setting:

image

 

All values were imported to “Skills” property as a multi-value data after starting the sync:

image

  • Thanks for the post, but I really don't understand where you got the filterdescriptor from.

    I created my BDC in designer and make an item read and listread command.  I am guessing that you are referring to the readlist command.  I want to use the filed EmpNumber.  I am not sure what to do with this screen and how you got values like DontCareValue, and UseValueAsDontCare.  How can I add this filter to my external content type?  Will this mess anything else up, or is it just there to get around the issue with the profile sync?

Page 1 of 1 (1 items)
Leave a Comment
  • Please add 7 and 8 and type the answer here:
  • Post