none
Populating domain attribute into FIM. The return type(Object) of function IIF is not Binary RRS feed

  • Question

  • I'm trying to use the Function "ConvertSidToString" with the CustomExpression:

    IIF(Eq(Left(ConvertSidToString(objectSid),41),"S-1-5-21-xxxxxxxxxx-xxxxxxxxxx-xxxxxxxxxx"),"DOMAINA",IIF(Eq(Left(ConvertSidToString(objectSid),41),"S-1-5-21-xxxxxxxxxx-xxxxxxxxxx-xxxxxxxxxx"),"DOMAINB",IIF(Eq(Left(ConvertSidToString(objectSid),41),"S-1-5-21-xxxxxxxxxx-xxxxxxxxxx-xxxxxxxxxx"),"DOMAINC","Unknown")))

    However, I get the error: The return type(Object) of function IIF is not Binary

    Friday, March 11, 2016 1:18 AM

Answers

  • Hi,

    I never use Function, in Sync Rules as it is hard to modify that and even hand for testing and copy over the function to other systems.

    Instead I use Custom Expression every time. So just paste your above expression into the text feld of "Custom Expression" and select destination attribute domain.

    That worked in my testlab.

    /Peter


    Peter Stapf - ExpertCircle GmbH - My blog: JustIDM.wordpress.com

    • Proposed as answer by UNIFYBobMVP Monday, March 14, 2016 12:03 PM
    • Marked as answer by bobo2 Monday, March 14, 2016 11:01 PM
    Friday, March 11, 2016 7:20 PM

All replies

  • Hi,

    I just pasted the above expression into my current MIM demo lab into the AD Person Inbound Sync Rule and it worked well without any error.
    I remember I also did that multiple times with FIM.

    What built of FIM do you currently use ?

    /Peter


    Peter Stapf - ExpertCircle GmbH - My blog: JustIDM.wordpress.com

    Friday, March 11, 2016 4:39 PM
  • Hi Peter,

    I'm doing this with MIM 2016.

    I'm selecting "Function", then "ConvertSidToString", then "CustomExpression"

    Which guide did you follow? I've never used FIM before and the MS technet guide for deploying MIM is riddled with errors. (eg under "Creating Inbound sync rule", Rule1 Source=sAMAccountName, Destination=f")

    cheers

    Friday, March 11, 2016 6:58 PM
  • Hi,

    I never use Function, in Sync Rules as it is hard to modify that and even hand for testing and copy over the function to other systems.

    Instead I use Custom Expression every time. So just paste your above expression into the text feld of "Custom Expression" and select destination attribute domain.

    That worked in my testlab.

    /Peter


    Peter Stapf - ExpertCircle GmbH - My blog: JustIDM.wordpress.com

    • Proposed as answer by UNIFYBobMVP Monday, March 14, 2016 12:03 PM
    • Marked as answer by bobo2 Monday, March 14, 2016 11:01 PM
    Friday, March 11, 2016 7:20 PM