Canceling rendering when resultset is empty [message #1661733] |
Mon, 09 March 2015 15:21  |
Eclipse User |
|
|
|
Hey there,
We have a report containing a lot of complex logic that generates just fine when there's data to be rendered, but throws a plethora of exceptions when someone gives it parameters that don't return anything. The errors are mainly all "Column XXX doesn't exist"... which makes sense considering there's no data to actually create the dataset.
Now, I know I can do something like this to just drop an element from my report design:
var myelement = reportContext.getReportRunnable().designHandle.getDesignHandle().findElement("myElementName");
myelement.drop();
The problem is that this code works in the beforeFactory... but at this point, I don't know whether I have results or not. The place I think would work is the onFetch event, but wouldn't it be too late then to drop an element? Also, how would I know whether the resultset is empty or not?
Finally, my reports run from a PHP script passing through JavaBridge and the rptdesign themselves are calling Esproc files to get their data. With such a setup, I'd like to know what I can do to solve this problem.
Thanks in advance,
Osuwariboy
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03330 seconds