<p>Hello,</p>
<p> </p>
<p>I'm following the post at <a href="
; I'm able to get output to a log. However, when I deploy the report the BIRT viewer, the report throws an exception. I've added the following to the beforeOpen script section of my data set. My script is below: </p>
<p> </p>
<p>
</p>
<p> </p>
<p>importPackage(Packages.java.io);<br><br>
logFileName = "/tmp/Report.log";<br><br>
out = new PrintWriter(new FileWriter(logFileName, false)); // creates a new print writer to output log<br><br>
var zoneCodes = params["ZoneCodes"].value; // gets the value of AssetTag from report parameter<br>
var assetTag = params["AssetTag"].value; // gets the value of AssetTag from report parameter<br><br>
out.println("Zone Codes = " + zoneCodes);<br>
out.println("Asset Tag = " + assetTag);<br><br>
if (assetTag != 'ALL') {<br>
this.queryText = this.queryText + "\nAND e.asset_tag = '" + assetTag + "'";<br>
}<br><br>
if (zoneCodes != 'ALL_ZONES') {<br>
this.queryText = this.queryText + "\nAND l.zone_code = '" + zoneCodes + "'";<br>
}<br><br>
this.queryText = this.queryText + "\nORDER BY nextdatedue";<br><br>
out.println("\nthis.queryText = " + this.queryText);<br>
out.close();