Can the Report Viewer work with Scripted DataSets ? [message #263864] |
Wed, 02 January 2008 09:46  |
Eclipse User |
|
|
|
Originally posted by: assaf.frank.dynasec.org
Hi,
I'm looking to generate my reports while using my application java APIs
(using DB datasource directly is too complex).
SO is my only way is to use the scripted data set ?
Can this work with the erport viewer ? Can I pass params within a request
objet to the viewer ?
I would like to continue to work with the viewer becuase of its extensive
paging and export capabilities (basiclly to excel..)
What are my other options to continue to work with the viewer but generate
the data from my own java classes? (If I prodocue text files and use file
datasource how can users generate reports at the same time ??)
Thanks very much.
|
|
|
|
|
|
|
|
|
Re: Can the Report Viewer work with Scripted DataSets ? [message #264276 is a reply to message #264273] |
Thu, 10 January 2008 08:42   |
Eclipse User |
|
|
|
Originally posted by: assaf.frank.dynasec.org
Hi Jason,
Sorry for all this but this can really help me.
I didn't manage to do what you said before so I just tried to copy the
viewer folders from my working viewer app in tomcat into my application:
I copied as is all folders (webcontenet and empty -
attachments,scriptlib,logs,documents) , all contents of web-inf into my
application web-inf (when file already exists , like , web.xml , or lib
folder) I just added the birt specific content into my application web.xml
or jars in my lib folder)..
Finaly I tried to access the viewer by the same url as my application
(using the frameset servlet call) and managed to get the first page
(export,print buttons) of the viewer..but then get JS errors (object
expected) that stop the report (and no parmeter window pups up and so
on..)..
1. Can I expect the viewer to work this way ? (or am I wasting my time
here)
2. Any idea where the wrong JS paths need to be corrected
Thanks very much !
|
|
|
Re: Can the Report Viewer work with Scripted DataSets ? [message #264337 is a reply to message #264276] |
Fri, 11 January 2008 11:47   |
Eclipse User |
|
|
|
Originally posted by: jasonweathersby.alltel.net
I have not tried this method, but it should work.
Can you try copying over the index.jsp and try calling in your new app?
Another option may be to take your existing app and write out the files
like you discussed earlier. You could name the files based on the
sessionid of your current app and then pass the name of the file as a
report parameter to the Viewer app. After the report processed the data
you could use the afterFactory event to delete the file.
Jason
assaf wrote:
> Hi Jason,
>
> Sorry for all this but this can really help me.
> I didn't manage to do what you said before so I just tried to copy the
> viewer folders from my working viewer app in tomcat into my application:
> I copied as is all folders (webcontenet and empty -
> attachments,scriptlib,logs,documents) , all contents of web-inf into my
> application web-inf (when file already exists , like , web.xml , or lib
> folder) I just added the birt specific content into my application
> web.xml or jars in my lib folder)..
>
> Finaly I tried to access the viewer by the same url as my application
> (using the frameset servlet call) and managed to get the first page
> (export,print buttons) of the viewer..but then get JS errors (object
> expected) that stop the report (and no parmeter window pups up and so
> on..)..
>
> 1. Can I expect the viewer to work this way ? (or am I wasting my time
> here)
> 2. Any idea where the wrong JS paths need to be corrected
>
> Thanks very much !
>
|
|
|
|
Re: Can the Report Viewer work with Scripted DataSets ? [message #264405 is a reply to message #264401] |
Sun, 13 January 2008 12:56  |
Eclipse User |
|
|
|
org.mozilla.javascript.ImporterTopLevel is placed in the
org.mozilla.rhino plugin and contains the initStandardObject method.
It is possible that your application loads this class from some other
location. I suppose that you have js.jar within your application that
isn't compatible with BIRT.
Snjeza
assaf wrote:
> I tried to call the index.jsp from the birt viewer and the page was
> displayed successfully.. the problem is that when I wish to display the
> test report from the index page I get an error : (the class
> org.mozilla.javascript.ImporterTopLevel is known in the application but
> I did not see any initStandardObjects method - only init method)-
>
> Any idea ?
> -[ViewerServlet]: java.lang.NoSuchMethodError:
> org.mozilla.javascript.ImporterTopLevel: method
> initStandardObjects(Lorg/mozilla/javascript/Context;Z)V not found
> at
> org.eclipse.birt.core.script.ScriptContext.<init>(ScriptContext.java:80)
> at
> org.eclipse.birt.report.engine.executor.ExecutionContext.<init >(ExecutionContext.java:311)
>
> at
> org.eclipse.birt.report.engine.api.impl.EngineTask.<init>(EngineTask.java:160)
>
> at
> org.eclipse.birt.report.engine.api.impl.EngineTask.<init>(EngineTask.java:176)
>
> at
> org.eclipse.birt.report.engine.api.impl.GetParameterDefiniti onTask. <init>(GetParameterDefinitionTask.java:92)
>
> at
> org.eclipse.birt.report.engine.api.impl.ReportEngineHelper.c reateGetParameterDefinitionTask(ReportEngineHelper.java:298)
>
> at
> org.eclipse.birt.report.engine.api.impl.ReportEngine.createG etParameterDefinitionTask(ReportEngine.java:318)
>
> at
> org.eclipse.birt.report.service.ReportEngineService.createGe tParameterDefinitionTask(Unknown
> Source)
> at
> org.eclipse.birt.report.service.BirtViewerReportService.getP arameterDefinitionTask(Unknown
> Source)
> at
> org.eclipse.birt.report.service.BirtViewerReportService.getP arameterDefinitions(Unknown
> Source)
> at
> org.eclipse.birt.report.context.ViewerAttributeBean.__initPa rameters(Unknown
> Source)
> at
> org.eclipse.birt.report.context.ViewerAttributeBean.__init(U nknown Source)
> at org.eclipse.birt.report.context.BaseAttributeBean.init(Unkno wn
> Source)
> at
> org.eclipse.birt.report.context.ViewerAttributeBean.<init>(Unknown Source)
> at org.eclipse.birt.report.context.BirtContext.__init(Unknown Source)
> at org.eclipse.birt.report.context.BaseContext.<init>(Unknown Source)
> at org.eclipse.birt.report.context.BirtContext.<init>(Unknown Source)
> at
> org.eclipse.birt.report.servlet.ViewerServlet.__getContext(U nknown Source)
> at
> org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherSer vlet.doGet(Unknown
> Source)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:743)
> at
> org.apache.axis.transport.http.AxisServletBase.service(AxisS ervletBase.java:327)
>
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
> at
> com.ibm.ws.webcontainer.servlet.ServletWrapper.service(Servl etWrapper.java:1572)
>
> at
> com.ibm.ws.webcontainer.servlet.ServletWrapper.service(Servl etWrapper.java:1521)
>
> at
> com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(We bAppFilterChain.java:136)
>
> at org.eclipse.birt.report.filter.ViewerFilter.doFilter(Unknown Source)
> at
> com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilte r(FilterInstanceWrapper.java:142)
>
> at
> com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(We bAppFilterChain.java:121)
>
> at
> com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(W ebAppFilterChain.java:82)
>
> at
> com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest (ServletWrapper.java:759)
>
> at
> com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.j ava:3071)
> at
> com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGro up.java:236)
> at
> com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHos t.java:210)
> at
> com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContai ner.java:1958)
> at
> com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChanne lLink.java:89)
> at
> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleD iscrimination(HttpInboundLink.java:472)
>
> at
> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleN ewInformation(HttpInboundLink.java:411)
>
> at
> com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.com plete(HttpICLReadCallback.java:101)
>
> at
> com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete (WorkQueueManager.java:566)
>
> at
> com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQ ueueManager.java:619)
>
> at
> com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(WorkQ ueueManager.java:952)
>
> at
> com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(Work QueueManager.java:1039)
>
> at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1471)
|
|
|
Powered by
FUDForum. Page generated in 0.09194 seconds