Jump to content
We've recently updated our Privacy Statement, available here ×

rsilverns.sympatico.ca

Members
  • Posts

    151
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Everything posted by rsilverns.sympatico.ca

  1. Just curious what others have done in the way of load tests for JasperServer. I am evaluating it for use in an enterprise environment where large-scale reporting would be the norm. Wondering what others have found in the way of their own tests and any tips they have for optimizing reports run through jasperserver. Thanks, Robin
  2. Change the element that has the text's option to be: Stretch With Overflow: True This will have the text field stretch down the page and stretching the detail bands boundries if the text is taller than the image. HTH, Robin
  3. That is how you would implement it actually.... or write a custom data source as well. Create a simple collection object and encapsulate your data object in this colleciton. Then use JRBeanCollectionDataSource to utilize this collection as a datasource. Then to access the various objects in your complex value object you will have fields, each field corresponds to a member variable inside your value object (set classes accordingly). For the collections, you can treat them as 1 of 2 ways: 1. Access the items in the collection staticially in a field expression: ie.. "My Favorite Food: " + myVector.elementAt(1), (2)... etc. 2. Create a sub-report data source being another JRBeanCollectionDataSource and have the items be printed in a subreport. HTH, Robin
  4. Has anyone encountered this issue before using the webservices component? If I pass the date as a Date and change my parameter in the report to be a String, the error goes away. Edit: The cause appears to be with the parsing of the date from string on the server. The exception was: Code:java.lang.NumberFormatException: For input string: "Thu Feb 22 10:33:51 AST 2007" at java.lang.NumberFormatException.forInputString(Unknown Source) at java.lang.Long.parseLong(Unknown Source) at java.lang.Long.valueOf(Unknown Source) at com.jaspersoft.jasperserver.ws.axis2.RepositoryHelper.convertParameterValues(RepositoryHelper.java:707) at com.jaspersoft.jasperserver.ws.axis2.ManagementService.runReport(ManagementService.java:1845) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397) at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186) at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323) etc. etc. etc. Seeing the "java.lang.Long.parseLong" line near the start of the exception I switched my date object to be "new Date().getTime()" and the date is passed (and parsed) properly. It appears that you need to pass any dates to the report as long objects. I went back and re-read the web services guide and sure enough, all this was listed in there. RTFM Robin! Post edited by: rsilver@bfm.bm, at: 2007/02/26 17:27
  5. I implemented a test of a connection to my jasperserver installation via a webservices. My tests relied on the jasperserver/ireport plugin classes located in the ireport plugin distribution. Part of my test was to fill a report, get the jrprint object in return then export to pdf. I ran into an error when doing so with respect to my date parameter that I pass to the report via the jasperserver date control properly (and through a programatic test filling as well). The code I use is: Code: private static void runTestOne() throws Exception { JServer server = new JServer(); server.setUrl("http://testserver:8080/jasperserver/services/repository"«»); server.setUsername("jadmin"«»); server.setPassword("gggttt123"«»); WSClient client = server.getWSClient(); System.out.println("Version Check: " + client.getVersion()); ResourceDescriptor rd = new ResourceDescriptor(); rd.setWsType(ResourceDescriptor.TYPE_REPORTUNIT); rd.setUriString("/reports/samples/student_listing"«»); HashMap map = new HashMap(); map.put("STUDENT_LNAME", "Doe"«»); map.put("STUDENT_ENROLL_DATE", "01/01/2006"«»); JasperPrint jp = client.runReport(rd, map); JRPdfExporter exporter = new JRPdfExporter(); exporter.setParameter(JRPdfExporterParameter.JASPER_PRINT, jp); File reportFile = new File("test.pdf"«»); exporter.setParameter(JRPdfExporterParameter.OUTPUT_FILE, reportFile); exporter.exportReport(); } In the report, STUDENT_LNAME is of type String, and STUDENT_ENROLL_DATE is of type date. I've tried passing in "new Date()", "01/01/2006", "01-01-2006", etc. The error I get is (using "new Date()" for date param): Code:[code]java.lang.Exception: 1 - For input string: "Wed Feb 21 15:23:57 AST 2007" at com.jaspersoft.jasperserver.irplugin.wsclient.WSClient.runReport(WSClient.java:382) at com.jaspersoft.jasperserver.irplugin.wsclient.WSClient.runReport(WSClient.java:299) at bm.bfm.capdev.reportingpoc.JasperServerWebServicesTestOne.runTestOne(JasperServerWebServicesTestOne.java:51) at bm.bfm.capdev.reportingpoc.JasperServerWebServicesTestOne.main(JasperServerWebServicesTestOne.java:21) Does anyone have any thoughts as to why my call is failing? If I rewrite the date parameter in my report to be a string, pass it as "01-01-2006" and parse it manually in each expression it's used in my report using SimpleDateFormat, then the call works properly and my report is returned to be exported to pdf. Thanks, Robin Post edited by: rsilver@bfm.bm, at: 2007/02/21 18:32
  6. The JasperServer Web Services Guide version 1.2.0 refers on page 3 to "a set of helper classes, including a ready-to-use client that can make it easier to integrate..." Where can these helper classes be found and is there an API to use them? I am testing out the webservices functionality and would like to utilize these classes so that I don't have to re-create the files. Thanks, Robin
  7. Hi All, I am running a jasper 1.1.0 server and wanted to check out the WSDL and start testing webservices against it. I tried using: http://localhost:8080/jasperserver/services/repository?wsdl But received the following message: Code: <error> <description>Unable to generate WSDL for this service</description> <reason> Either user has not dropped the wsdl into META-INF or operations use message receivers other than RPC. </reason> </error> Am I using the correct WSDL URL or is this indicitive of an error of some sort during the installation? It is on Linux and am hoping to avoid the hassel of upgrading to 1.2 at this time, as it involves issuing support tickets etc. etc. Any input is appreciated. Thanks! Robin
  8. Setup a parameter like "FILES_ROOT" or something. And have it be passed to the report to specify the root path to the image on each system.
  9. You just treat the expression as a java expression that expresses that logic. instead of: $F{Monitor}+" "+ $R{loc.15}+" "+ $F{Monitor-SNR}+")" try: $F{Monitor} == null?"":$F{Monitor}+" "+ $R{loc.15}+" "+ $F{Monitor-SNR}+")"
  10. The expression of your field could be: $F{myfield} == null?"-":$F{myField}.toString() and change expression class to be String. Replace the field.toString with a number formatter class as appropriate.
  11. Hey there, I was wondering if there was any plans to integrate iReports as an Eclipse RCP app in the near future? The current plugin seems to only launch the external Swing gui. True integration into Eclipse would make it the designer of choice for my team. :) If a dev can comment on this, it would be greatly appreciated. Thx, Rob
  12. What do you mean by extra columns being added? Did you check that the report column/page widths match up to the actual width of all your fields? If it is wider, there will be a wide column added to the excel file produced to account for this width. HTH, Robin
  13. Hey all, I am producing a complex report of 15+(averages around 18) pages, many sub-reports, scriptlets etc. I produce the report and demo it for the user using the viewer. All of the pages appear properly and look as they should. When I print the pages from this viewer there appears to be a random issue where the contents of certain pages are not being printed. So I would have title, page1, 2, 3,4 then page 5 would be partially there with certain elements missing etc. Has anyone encountered something similar in the past? Thx, Robin
  14. Ahh good point... but whereas my seperation character has been switched to be a "|" it still surrounds the commas with quotes? Edit: After looking at the source code, it appears that they assume all commas to be the delimeter even if the delimiter is switched. Will issue a bug on this one. Thx, Rob Post edited by: rsilver@bfm.bm, at: 2006/12/11 12:17
  15. I have a report being exported as a CSV file which is behaving strangely. One of my fields is having " placed around the numeric value when a format is applied to it. My data row consists of... NAME | ACCT DESCRIPTION | ACCT VALUE | ACCT NOTES where all values are Strings, except ACCT VALUE which is a Big Decimal. When I apply no formatting the value prints fine.. e.g. 1152.42, however when I try to introduce a thousand's seperator ',' the problem is encounterd.. 1152.42 becomes "1,152.42" rather than 1,152.42 (the quotes are showing up in export file). Is this some feature of CSV exporter related to the width of my fields in the report file, or is it a bug? Anyone with input please feel free to post. Thx, Robin Post edited by: rsilver@bfm.bm, at: 2006/12/08 18:19
  16. If your using the parameter in the report queryString, you may want to try adding a '!' to the paramater.. so $P{myparam} becomes $P!{myparam}. This sometimes helps, depending on usage. HTH, Robin
  17. JasperIntelligence is the Business Intelligence server and has the option to schedule report generation, interface with LDAP etc. You may want to review this product to see if it suits your needs. HTH. Robin
  18. There is a feature request to implement this feature, but it is still a feature request only.
  19. Introduce columns to your report structure. Place the field into the left-most column. That should be it.
  20. You could place an entry on the summary page with a printwhen expression of new Boolean($V{REPORT_COUNT}.intValue() == 0) and have print when no recrods option set to all sections no detail but this would mean that any other band you had would also be printed.
  21. Can you confirm the parameter names you are using to... A. Pass parameters to the main report. B. Parameter names that you are using in main report C. Sub-report parameters and expression for the sub-reprot D. Parameter names in the sub-report? HTH, Robin
  22. To make sure I understand what your asking, you print the names, 1 from each record in your data set? ie. the table is: ID | NAME 1 | Joe 2 | Frank 3 | Suzy 4 | Nancy So your jasper report has: -----detail band------ $F{NAME} ---------------------- giving you: -----detail band------ Joe Frank Suzy Nancy ---------------------- ? If so, you can introduce columns and set the fill order to be Horizontal. This way you will have n columns allowing for n records to be filled to the right and then another line filled to the right. So assuming that we use 3 columns: ------ detail band ------------ Joe Frank Suzy Nancy ------------------------------- HTH, Robin
  23. I may have spoken too soon... this trick works for reports that do not have "Pages" introduced by the false group header trick, but when you do that the system breaks down and I have a "null" generated for each page except the last page for the X in Page X of Y. Am seeing an infinite loop introduced during report filling somehow. Not sure what is going on will attempt to debug it. Will add this as a feature request.
  24. That fixed it.. nice trick guys! For those reading this post, as per lucianc's other post the solution was..... Code:<variable name="CurrPageNo" class="java.lang.Integer" resetType="Page"> <variableExpression>$V{PAGE_NUMBER}</variableExpression> </variable> .. <textField evaluationTime="Auto"> .. <textFieldExpression><![CDATA["Page " + $V{CurrPageNo} + " / " + $V{PAGE_NUMBER}]]></textFieldExpression> </textField> Thanks, Robin
×
×
  • Create New...