aleksandra.gencheva Posted February 24, 2014 Share Posted February 24, 2014 Hi Everybody,I have a question about the REST API of the JasperReports Server. For Example I want to get the same report but in three different formats (PDF, HTM, CSV). I will make three calls to the API - is it possible to get them with one call and also what will happen when I call it 3 times the same report - will it execute 3 times all the stored procedures or it will do it only one time?Thanks a lot. Link to comment Share on other sites More sharing options...
hozawa Posted February 24, 2014 Share Posted February 24, 2014 The current API only accepts one output format so you'll have to make 2 calls. It's seems to be executing 3 times. If you have a really large report, it's probably better to output in one format and then to converted that to other formats. Link to comment Share on other sites More sharing options...
Solution ilona Posted February 25, 2014 Solution Share Posted February 25, 2014 With REST v2 you can call the report by its ID and ask for different formats. It should not run the query more than once because it's getting the JPRINT object. Regards,Ilona Link to comment Share on other sites More sharing options...
hozawa Posted February 25, 2014 Share Posted February 25, 2014 Can you tell me which api call to use? "reportExcutions" is used to execute a report and there's an "outputFormat" here. "outputResource" is used to retrieve the report output but there's not option to specify the output here. Quote from Web Service Guide: "Every export format of the report has an ID that is used to retrieve it. For example, the HTML export in the previous example has the ID html. To download the main report output, specify this export ID in the following method" Link to comment Share on other sites More sharing options...
aleksandra.gencheva Posted February 25, 2014 Author Share Posted February 25, 2014 Thanks a lot. Could you please tell me if I can request this JPRINT object and store it in a database so later the user to be able to export the report in a format he wants? Is it possible to interact with this format from .NET code? Thanks again Link to comment Share on other sites More sharing options...
hozawa Posted March 3, 2014 Share Posted March 3, 2014 This is planned for JasperReports Server to be released this year (5.6.0 or 5.7.0?) but not in the current 5.5.0. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now