<div dir="ltr"><div>That didn't work, Roman, same error. <br><br></div><div>All of the examples use a $ in the expression there. What are the rules for using a $ vs not?<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Dec 7, 2015 at 10:06 AM, Roman Pudil - AMI Praha a.s. <span dir="ltr"><<a href="mailto:roman.pudil@ami.cz" target="_blank">roman.pudil@ami.cz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#ffffff">
<div>Hi Devin,</div>
<div>problem is probably in:</div><span class="">
<div> <expression><br> <c:path><font color="#ea161e">$givenName</font></c:path><br> </expression><br></div>
</span><div>Please, try (without "$" char):</div>
<div> </div>
<div> <expression><br> <c:path>givenName</c:path><br> </expression><br></div>
<div>Regards</div>
<div> </div>
<div>
<div style="FONT-SIZE:12pt;FONT-FAMILY:Tahoma">
<table style="WHITE-SPACE:normal;WORD-SPACING:0px;BORDER-COLLAPSE:collapse;TEXT-TRANSFORM:none;COLOR:rgb(0,0,0);FONT:medium 'Times New Roman';LETTER-SPACING:normal;TEXT-INDENT:0px">
<tbody>
<tr>
<td style="FONT-SIZE:11px;FONT-FAMILY:Arial,sans-serif;VERTICAL-ALIGN:bottom;COLOR:rgb(0,0,0)" colspan="2">
<p><span style="FONT-SIZE:14px;FONT-WEIGHT:bold">Roman Pudil</span><br>solution architect<br><br>gsm: <a href="tel:%5B%2B420%5D%20775%20663%20666" value="+420775663666" target="_blank">[+420] 775 663 666</a><br>e-mail:<span> </span><a href="mailto:roman.pudil@ami.cz" target="_blank">roman.pudil@ami.cz</a></p></td>
<td style="BORDER-RIGHT:rgb(204,204,204) 1px solid"> </td>
<td> </td>
<td style="FONT-SIZE:11px;FONT-FAMILY:Arial,sans-serif;VERTICAL-ALIGN:bottom;COLOR:rgb(0,0,0)">
<p>AMI Praha a.s.<br>Pláničkova 11<br>162 00 Praha 6<br>tel./fax: <a href="tel:%5B%2B420%5D%20274%20783%20239" value="+420274783239" target="_blank">[+420] 274 783 239</a><br>web:<span> </span><a href="http://www.ami.cz/" target="_blank">www.ami.cz</a></p></td>
<td style="BORDER-RIGHT:rgb(204,204,204) 1px solid"> </td>
<td> </td>
<td style="FONT-SIZE:11px;FONT-FAMILY:Arial,sans-serif;COLOR:rgb(0,0,0)">
<p><img title="AMI Praha a.s." alt="" src="http://www.ami.cz/images/podpis/ami_logo.gif" border="0"></p></td></tr>
<tr>
<td colspan="8"><br><a href="http://www.ami.cz/reseni-a-sluzby/bezpecnost-dat/identity-management" target="_blank"><img alt="" src="http://www.ami.cz/images/podpis/AMI-podpis-IdM_1.png" border="0"></a></td></tr>
<tr>
<td style="FONT-SIZE:11px;FONT-FAMILY:Arial,sans-serif;COLOR:rgb(128,128,128)" colspan="8"><br>Textem tohoto e-mailu podepisující neslibuje uzavřít ani neuzavírá za společnost AMI Praha a.s.<br>jakoukoliv smlouvu. Každá smlouva, pokud bude uzavřena, musí mít výhradně písemnou formu.</td></tr></tbody></table></div></div>
<div> </div>
<div> </div>
<div> </div>
<div>------ Původní zpráva ------</div>
<div>Od: "Radovan Semancik" <<a href="mailto:radovan.semancik@evolveum.com" target="_blank">radovan.semancik@evolveum.com</a>></div>
<div>Komu: <a href="mailto:midpoint@lists.evolveum.com" target="_blank">midpoint@lists.evolveum.com</a></div>
<div>Odesláno: 7.12.2015 16:02:48</div>
<div>Předmět: Re: [midPoint] assignmentTargetSearch "null polystring orig" error</div><div><div class="h5">
<div> </div>
<div style="COLOR:#000000">
<blockquote cite="http://56659F98.4090206@evolveum.com" type="cite">
<div>Hi,<br><br>I have similar mapping working in our story tests.<br><br>How does your input object looks like? I mean, how does the user looks like before it is processed by the template?<br>Is there any chance that the givenName is null?<br><br>The evaluation of null expressions has changed a bit in 3.3. But I think that your expression should work and you are probably hitting a but. I will need more data to replicate it.<br><br><pre cols="72">--
Radovan Semancik
Software Architect
<a href="http://evolveum.com" target="_blank">evolveum.com</a>
</pre><br><br>On 12/04/2015 05:15 PM, Devin Rosenbauer wrote:<br></div>
<blockquote type="cite">
<div dir="ltr">Can anybody else please try this mapping on their end and see if it works?<br></div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Tue, Dec 1, 2015 at 1:51 PM, Devin Rosenbauer <span dir="ltr"><<a href="mailto:devin@identityworksllc.com" target="_blank">devin@identityworksllc.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT:1ex;BORDER-LEFT:#ccc 1px solid;MARGIN:0px 0px 0px 0.8ex">
<div dir="ltr">Version is 3.3.<br>
<div><br>I've got the following in my user template, based on a somewhat modified version of what's in the documentation online:<br><br> <mapping><br> <source><br> <c:path>$user/givenName</c:path><br> </source><br> <expression><br> <assignmentTargetSearch><br> <targetType>c:OrgType</targetType><br> <filter><br> <q:equal><br> <q:path>c:name</q:path><br> <q:value><br> <expression><br> <path>$givenName</path><br> </expression><br> </q:value><br> </q:equal><br> </filter><br> <createOnDemand>true</createOnDemand><br> <populateObject><br> <populateItem><br> <expression><br> <c:path>$givenName</c:path><br> </expression><br> <target><br> <c:path>name</c:path><br> </target><br> </populateItem><br> </populateObject><br> </assignmentTargetSearch><br> </expression><br> <target><br> <c:path>assignment</c:path><br> </target><br> </mapping><br clear="all">
<div><br></div>
<div>I expect that this would create an Org called "Devin" and assign the user to it.<br><br></div>
<div>Here's what I get as an error message when I attempt to save and reconcile the user:<br>
<div style="WIDTH:1121px">
<ul>
<li>
<div>
<div title="Partial error">Failed to convert query. Reason: Null polystring orig in XNode(map:1 entries)(givenName=PPV(PolyString:Devin); ) in expression in mapping in objectTemplate:c0c010c0-d34d-b33f-f00d-777222222334(User Template 2)</div>
<div title="Partial error">
<ul>
<li style="MARGIN-TOP:5px">
<div><span>operation.com.evolveum.midpoint.web.page.admin.PageAdminFocus.save</span> </div></li>
<li><span><u>Cause:</u> <span>
<p>Failed to convert query. Reason: Null polystring orig in XNode(map:1 entries)(givenName=PPV(PolyString:Devin); ) in expression in mapping in objectTemplate:c0c010c0-d34d-b33f-f00d-777222222334(User Template 2)</p></span></span></li></ul></div></div></li></ul></div>The documentation on the Expressions page and the samples appear to be somewhat incorrect here. I've had to make some corrections from <query> to <filter>, adding a <source>, and so forth. I also am temporarily using an OOTB field instead of a custom field to ensure that it's a PolyString and not an xsd:string, just to make sure that wasn't the issue.<br><br>At this point, it seems pretty clear that it is grabbing the value in the XNodeMap, since it's printed in the error message. <br><br>So, how should this mapping be structured to do what I need to do?<span><font color="#888888"><br></font></span></div><span><font color="#888888">
<div><br>-- <br>
<div>
<div dir="ltr">Devin Rosenbauer<br>Principal Consultant<br>Identity Works LLC<br><a href="tel:%2B1%20585%20210%203201" value="+15852103201" target="_blank">+1 585 210 3201</a><br></div></div></div></font></span></div></div></blockquote></div><br><br clear="all"><br>-- <br>
<div>
<div dir="ltr">Devin Rosenbauer<br>Principal Consultant<br>Identity Works LLC<br><a href="tel:%2B1%20585%20210%203201" value="+15852103201" target="_blank">+1 585 210 3201</a><br></div></div></div><br>
<fieldset></fieldset> <br><pre>_______________________________________________
midPoint mailing list
<a href="mailto:midPoint@lists.evolveum.com" target="_blank">midPoint@lists.evolveum.com</a>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" target="_blank">http://lists.evolveum.com/mailman/listinfo/midpoint</a>
</pre></blockquote><br><br></blockquote></div></div></div></div><br>_______________________________________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com">midPoint@lists.evolveum.com</a><br>
<a href="http://lists.evolveum.com/mailman/listinfo/midpoint" rel="noreferrer" target="_blank">http://lists.evolveum.com/mailman/listinfo/midpoint</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature"><div dir="ltr">Devin Rosenbauer<br>Principal Consultant<br>Identity Works LLC<br>+1 585 210 3201<br></div></div>
</div>