Clarity

 View Only
  • 1.  Error expression in a custom script with special characters

    Posted Aug 10, 2017 07:53 AM

    Trying to create a custom script with a portfolio xogwrite, we are getting the next error:

     

    "Element type "investment_type" must be followed by either attribute specifications, ">" or "/>""

     

    The block that is generating this error is the next one:

     

    <Content>
    <Filters>
    <investment_type code="idea" expression="( idea.z_status ==  lookup(&quot;Z_LKP_ESTADO_IDEA&quot;, &quot;6&quot;)  ||  ( idea.z_status ==  lookup(&quot;Z_LKP_ESTADO_IDEA&quot;, &quot;4&quot;) ))  &amp;&amp;  idea.is_active == 1 &amp;&amp;  ( idea.z_client ==  lookup(&quot;LOOKUP_COMPANIES&quot;, ${clsp}) ) &amp;&amp;  ( idea.z_type ==  lookup(&quot;IMM_TYPE&quot;, &quot;PROJECT&quot;) )"/>
    </Filters>
    </Content>

     

    This expression is that we get with portfolio xogread.

     

    When we delete the character &, error doesn't appear but the expression in content editor portfolio is invalid.

     

    Someone does it know how to write special characters (like ", &, >, <) in xogwrite?

     

    Thanks in advance.



  • 2.  Re: Error expression in a custom script with special characters

    Posted Aug 10, 2017 08:36 AM

    That looks BUG-y to me - if that XML format / syntax is the same as you get from the XOG read then you should be able to XOG write it back - i.e. I don't think its a problem with the special characters as you have the right XML encoding of the (&quot; and so on).

     

    I'd try maybe with the xml like this;

     

    <Filters>
    <investment_type code="idea" expression="( idea.z_status ==  lookup(&quot;Z_LKP_ESTADO_IDEA&quot;, &quot;6&quot;)  ||  ( idea.z_status ==  lookup(&quot;Z_LKP_ESTADO_IDEA&quot;, &quot;4&quot;) ))  &amp;&amp;  idea.is_active == 1 &amp;&amp;  ( idea.z_client ==  lookup(&quot;LOOKUP_COMPANIES&quot;, ${clsp}) ) &amp;&amp;  ( idea.z_type ==  lookup(&quot;IMM_TYPE&quot;, &quot;PROJECT&quot;) )">

    </investment_type>

    </Filters>

     

    Just to see what happens, otherwise I'd be looking for a BUG in the CA support / knowledge base and/or raising a support call ?



  • 3.  Re: Error expression in a custom script with special characters

    Posted Aug 10, 2017 09:50 AM

    Thank you very much for your response.

     

    I tried with tag </investment_type>, but the error persists.

     

    I'm gonna contact with CA support.