On 21 September 2011 11:01, Michael Anstis <span dir="ltr">&lt;<a href="mailto:michael.anstis@gmail.com">michael.anstis@gmail.com</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
This JIRA basically says it&#39;s a bug that Templates cannot be expanded unless a value is given for each template-key.<br></blockquote><div><br>I don&#39;t think it says that. The JIRA is due to the impossibility of distinguishing between nothing and an empty string in a spreadsheet cell (unless it were written with delimiting quotes, which it isn&#39;t).<br>
<br>You can expand templates programmatically with any value as an actual macro parameter.<br><br>To solve the spreadsheet dilemma you could think up several hacks, similar to the one that was reported as implemented for <a href="https://issues.jboss.org/browse/JBRULES-2409" target="_blank">https://issues.jboss.org/browse/JBRULES-2409</a> only yesterday, e.g., another spreadsheet setting<br>
<br>   EmptyString &lt;text&gt;<br><br>defining &lt;text&gt; as a stand-in for the nothingness of the empty string.<br><br>-W<br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>E.G. Smurf( name == &quot;@{smurfName}&quot;, colour==&quot;@{smurfColour}&quot; ) won&#39;t be included in the generated DRL unless a value for &quot;smurfName&quot; and &quot;smurfColour&quot; is given.<br>
<br>IMO, I&#39;d agree - it&#39;s a painful limitation, however thought I&#39;d ask if anybody knows of any history as to why it might have been implemented this way before I stamp over what might be considered as &quot;correct behavior&quot;?<br>

<br>Obviously, in my example, Smurfs are always blue ;)<br><br>Cheers,<br><br>Mike<br>
<br>_______________________________________________<br>
rules-dev mailing list<br>
<a href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
<br></blockquote></div><br>