<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hi Rodrigo,<br>
    <br>
    Just a curious question: What is the reason that you do not user the
    activation/validTo property of the user?<br>
    <br>
    I'm not trying to persuade you or push you to use a specific
    solution. I just wonder whether the midPoint validity time
    constraints have some limitation that prohibits the use in practice
    or whether there is some other barrier.<br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Radovan Semancik
Software Architect
evolveum.com
</pre>
    <br>
    <br>
    <br>
    <div class="moz-cite-prefix">On 08/22/2016 09:00 PM, Rodrigo Yanis
      wrote:<br>
    </div>
    <blockquote
cite="mid:CADu-59ELH=JVK4wN8cgD1DLpZcO++72OogS9r+iRHZzA2gdUkQ@mail.gmail.com"
      type="cite">
      <div dir="ltr">Hello everyone,
        <div><br>
        </div>
        <div>I'm currently trying to build a task to disable users when
          they reach their termination date in midPoint (expressed on a
          custom attribute as dd/MM/yyyy).</div>
        <div><br>
        </div>
        <div>I'm having difficulties defining a search filter that would
          evaluate equality to a value returned by a Groovy script, the
          code is the following:</div>
        <div><br>
        </div>
        <div>
          <div><scext:executeScript xmlns:scext="<a
              moz-do-not-send="true"
href="http://midpoint.evolveum.com/xml/ns/public/model/scripting/extension-3">http://midpoint.evolveum.com/xml/ns/public/model/scripting/extension-3</a>"></div>
          <div>                <s:search xmlns:s="<a
              moz-do-not-send="true"
              href="http://midpoint.evolveum.com/xml/ns/public/model/scripting-3">http://midpoint.evolveum.com/xml/ns/public/model/scripting-3</a>"></div>
          <div>                   
            <s:type>c:UserType</s:type></div>
          <div>                    <s:searchFilter></div>
          <div>                        <q:equal></div>
          <div>                           
            <q:path>extension/metaEndDate</q:path></div>
          <div>                            <c:expression></div>
          <div>                                <c:script></div>
          <div>                                    <c:code></div>
          <div>                                        def dateTime =
            new Date().format( 'dd/MM/yyyy' );</div>
          <div>                                        return
            dateTime.toString();</div>
          <div>                                    </c:code></div>
          <div>                                </c:script></div>
          <div>                            </c:expression></div>
          <div>                        </q:equal></div>
          <div>                    </s:searchFilter></div>
          <div>                    <s:action></div>
          <div>                       
            <s:type>disable</s:type></div>
          <div>                    </s:action></div>
          <div>                </s:search></div>
          <div>            </scext:executeScript></div>
          <div><br>
          </div>
          <div>Error (execution time) I recieve is the following: <span
              style="color:rgb(51,51,51);font-family:"Source Sans
              Pro","Helvetica
Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:20px;background-color:rgb(249,249,249)">Couldn't
              execute script: Couldn't parse object filter due to schema
              exception</span></div>
          <div><span style="color:rgb(51,51,51);font-family:"Source
              Sans Pro","Helvetica
Neue",Helvetica,Arial,sans-serif;font-size:14px;line-height:20px;background-color:rgb(249,249,249)"><br>
            </span></div>
          I understand this must be related to namespaces definitions. I
          couldn't find any example of what i'm trying to do either.</div>
        <div><br>
        </div>
        <div>Do you know if this is possible?</div>
        <div><br>
        </div>
        <div>Thanks.<br>
          <div>
            <div class="gmail_signature"
              data-smartmail="gmail_signature">
              <div dir="ltr">
                <div>
                  <div dir="ltr">
                    <div>
                      <div dir="ltr">
                        <div>
                          <div dir="ltr">
                            <div dir="ltr">
                              <div dir="ltr"><br>
                              </div>
                              <div dir="ltr"><font face="arial,
                                  helvetica, sans-serif"><b>Rodrigo
                                    Yanis.</b><br>
                                  <img moz-do-not-send="true"
                                    src="http://www.identicum.com/img/favicon.ico">Identicum
                                  S.A.<br>
                                </font>Jorge Newbery 3226<br>
                                Tel: +54 (11) 4824-9971<font
                                  face="arial, helvetica, sans-serif"><br>
                                  <a moz-do-not-send="true"
                                    href="mailto:ryanis@identicum.com"
                                    target="_blank"><font
                                      color="#0b5394">ryanis@identicum.com</font></a><br>
                                  <a moz-do-not-send="true"
                                    href="http://www.identicum.com/"
                                    target="_blank"><font
                                      color="#0b5394">www.identicum.com</font></a></font></div>
                            </div>
                          </div>
                        </div>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
midPoint mailing list
<a class="moz-txt-link-abbreviated" href="mailto:midPoint@lists.evolveum.com">midPoint@lists.evolveum.com</a>
<a class="moz-txt-link-freetext" href="http://lists.evolveum.com/mailman/listinfo/midpoint">http://lists.evolveum.com/mailman/listinfo/midpoint</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>