Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Data Set can't find Report Variables
pgrie
<div>Hello,</div>
<div> </div>
<div>I have a report with one report variable named DateEnd :</div>
<div> </div>
<div>
<div><variable-element name="DateEnd"></div>
<div style="margin-left:40px;"><expression name="value" type="javascript"></div>
<div style="margin-left:40px;">'31122014'</div>
<div style="margin-left:40px;"></expression></div>
<div style="margin-left:40px;"><property name="type">report</property></div>
<div></variable-element></div>
</div>
<div> </div>
<div>And I want to use it like a parameter into a data set.</div>
<div>I create my dataset and my request :</div>
<div>
<div> </div>
<div>select sum( d.nb_dossiers) as nbDossiersAvecCout from</div>
<div> agg_proto_****_jour d , ecp_proto_**** p</div>
<div>where d.id_date >= to_date(?,'ddmmyyyy') </div>
<div> </div>
<div>And I add a parameter into my dataset, and I passed in"Default Value" 'vars["DateEnd"]' and the value None into "Linked To Report Parameter".</div>
<div> </div>
<div>And I have always this exception :</div>
<div> </div>
</div>
<div>org.eclipse.birt.data.engine.core.DataException: Data engine operation failed due to an unexpected exception.</div>
<div>A BIRT exception occurred. See next exception for more information.</div>
<div>There are errors evaluating script "vars["DateEnd"]":</div>
<div>Report variable"DateEnd" does not exist</div>
<div style="margin-left:40px;">at org.eclipse.birt.data.engine.impl.ParameterUtil.evaluateInputParameterValue(ParameterUtil.java:316)</div>
<div style="margin-left:40px;"> </div>
<div style="margin-left:40px;"> </div>
<div>How can I use Report variable into data set request ?</div>
<div> </div>
<div>Thanks for your help</div>
<div> </div>
<div>Paul</div>
Find more posts tagged with
Comments
pgrie
<p>I don't know if it's the good method but I created my query in Property Binding and it works now</p>
JFreeman
<p>As a heads up, the reason you were getting the error with your original configuration is because Report Variables are not created until after parameter selection. Instead I believe you can use a Persistent Global Variable.</p>
<p> </p>
<p>Regarding the query in Property Binding, I'm not sure that is going to be best practice. However, if it works and you are not seeing adverse behavior you are probably okay. I would just keep that portion in mind if you end up having other issues or strange behavior.</p>