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

chill_work

Members
  • Posts

    24
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Security Advisories

Downloads

Everything posted by chill_work

  1. After posting, we kept messing with it. We actually had it working on another box but never put our finger on what the difference was. The problem was how maven is building out our deployment for JBoss. When it creates the ear directory, it has a lib directory with all the jars. Well, so does the war/WEB-INF/lib. But on the other box, we purposely removed jars from WEB-INF/lib. Once we did this locally and on the other box, we stop receiving the above exception. Thanks, Calvin
  2. FYI.. We are running under JBoss 4.2.3 using Java 6. We made sure the 'work' directory and 'tmp' directory are cleared. Also, we can see that the built in query setup as a datasource gets run. It is when the output is being created that the report fails with the above exception. We are using log4j, is there an expression that we can add to it, to deliver more information? Thanks, Calvin
  3. One other thing, if you force a color on the rectangle without using a style, does it work? Calvin
  4. I don't know if this will help but we have done is created a new Boolean object with in the conditional expression. Check out the code below. Calvin Code:<conditionalStyle> <conditionExpression><![CDATA[new Boolean($F{ResponseMeasure}.equalsIgnoreCase( "100" ))]]></conditionExpression> <style isDefault="false" style="TopBoxBold" forecolor="#666666" fontName="Verdana" isBold="true"/> </conditionalStyle>
  5. I might not understand the actual problem, however, I do know that when you size your Statictext or textfields bigger than the band or cell it is in, the text will not be shown. If you are using iReport, check the textfield box and make sure it isn't green. Green means that it might display it might not. You might need to wrap it to verify is working correctly. If it is working, then you might have to adjust your report size, band size, and then text size appropriately. A lot of times, I try to make the band much bigger than the field and then have the field auto size. Though, I understand if this is in a table like report structure with so many columns, you might not have the extra room. Calvin
  6. No problem. Thanks, Calvin Code:java.lang.ArrayStoreException: net.sf.jasperreports.engine.base.JRBaseExpressionChunk at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.readArray(ObjectInputStream.java:1667) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1323) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:480) at net.sf.jasperreports.engine.base.JRBaseStyle.readObject(JRBaseStyle.java:1471) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351) at java.util.ArrayList.readObject(ArrayList.java:593) at sun.reflect.GeneratedMethodAccessor329.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351) at java.util.ArrayList.readObject(ArrayList.java:593) at sun.reflect.GeneratedMethodAccessor329.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947) at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871) at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753) at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329) at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351) at org.hibernate.util.SerializationHelper.deserialize(SerializationHelper.java:210) at org.hibernate.util.SerializationHelper.deserialize(SerializationHelper.java:240) at org.hibernate.type.SerializableToBlobType.fromBytes(SerializableToBlobType.java:69) at org.hibernate.type.SerializableToBlobType.get(SerializableToBlobType.java:61) at org.hibernate.type.AbstractLobType.nullSafeGet(AbstractLobType.java:46) at org.hibernate.type.AbstractType.hydrate(AbstractType.java:81) at org.hibernate.persister.entity.AbstractEntityPersister.hydrate(AbstractEntityPersister.java:2101) at org.hibernate.loader.Loader.loadFromResultSet(Loader.java:1380) at org.hibernate.loader.Loader.instanceNotYetLoaded(Loader.java:1308) at org.hibernate.loader.Loader.getRow(Loader.java:1206) at org.hibernate.loader.Loader.getRowFromResultSet(Loader.java:580) at org.hibernate.loader.Loader.doQuery(Loader.java:701) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:236) at org.hibernate.loader.Loader.loadEntity(Loader.java:1860) at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:48) at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:42) at org.hibernate.persister.entity.AbstractEntityPersister.load(AbstractEntityPersister.java:3049) at org.hibernate.event.def.DefaultLoadEventListener.loadFromDatasource(DefaultLoadEventListener.java:399) at org.hibernate.event.def.DefaultLoadEventListener.doLoad(DefaultLoadEventListener.java:375) at org.hibernate.event.def.DefaultLoadEventListener.load(DefaultLoadEventListener.java:139) at org.hibernate.event.def.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:195) at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:103) at org.hibernate.impl.SessionImpl.fireLoad(SessionImpl.java:878) at org.hibernate.impl.SessionImpl.get(SessionImpl.java:815) at org.hibernate.impl.SessionImpl.get(SessionImpl.java:808) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.hibernate.context.ThreadLocalSessionContext$TransactionProtectionWrapper.invoke(ThreadLocalSessionContext.java:301) at $Proxy88.get(Unknown Source) at com.mktinsights.cee.command.reporting.GetReportInstanceCommand.execute(GetReportInstanceCommand.java:43) at com.mktinsights.cee.command.BaseCommand.execute(BaseCommand.java:47) at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:191) at com.mktinsights.cee.web.reporting.ReportExecuteBean.checkReportStatus(ReportExecuteBean.java:650) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.el.parser.AstValue.invoke(AstValue.java:131) at org.apache.el.MethodExpressionImpl.invoke(MethodExpressionImpl.java:276) at com.sun.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:68) at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:88)11:46:34,739 INFO [sTDOUT] at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:102) at javax.faces.component.UICommand.broadcast(UICommand.java:387) at org.ajax4jsf.component.AjaxActionComponent.broadcast(AjaxActionComponent.java:55) at org.ajax4jsf.component.AjaxViewRoot.processEvents(AjaxViewRoot.java:321) at org.ajax4jsf.component.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:296) at org.ajax4jsf.component.AjaxViewRoot.processPhase(AjaxViewRoot.java:253) at org.ajax4jsf.component.AjaxViewRoot.processApplication(AjaxViewRoot.java:466) at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:82) at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100) at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178) at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290) at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:390) at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:517) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:147) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.mktinsights.cee.web.performance.PerformanceFilter.doFilter(PerformanceFilter.java:59) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.shale.application.faces.ShaleApplicationFilter.doFilter(ShaleApplicationFilter.java:267) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.mktinsights.cee.web.securityfilter.CspSecurityFilter.doFilter(CspSecurityFilter.java:212) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175) at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182) at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446) at java.lang.Thread.run(Thread.java:637)
  7. Hello, Unfortunately, our project has had to move to Java 6 for other development reasons. What we have found is we get this exception when running a JasperReport. java.lang.ArrayStoreException: net.sf.jasperreports.engine.base.JRBaseExpressionChunk We have determine that when we remove the <conditionalstyle> element from the jrxml, the report works. See below. We can leave the style in there but when adding a condition, we get the ArrayStoreException. Any thoughts or ideas on how we can go back to using the conditionalStyles would be appreciated. Thank you, Calvin Code:<style name="TopBoxBold" isDefault="false" forecolor="#666666" fontName="Verdana"> <conditionalStyle> <conditionExpression><![CDATA[new Boolean($F{ResponseMeasure}.equalsIgnoreCase( "100" ))]]></conditionExpression> <style isDefault="false" style="TopBoxBold" forecolor="#666666" fontName="Verdana" isBold="true"/> </conditionalStyle> </style>
  8. Are you refering to those extra blank lines when you do an export to Excel? If so, in iReport you can set it under Options menu for the XLS Exporter "Is Remove Empty Space Between Rows", check mark it. If you are doing this from code then you will do the following: Code: exporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, Boolean.TRUE); Hope that helps. Calvin
  9. Does the JasperServer Ultimate Guide contain information on using the JasperServer API to store off reports in the Repository? Thanks, Calvin
  10. If you have multiple datasources (even if they are different), as far as I know you have to do subreports. That would be nice if you can have multiple datasources and then just have a bunch of fields. Calvin
  11. I have created Datasources so that Jasper can iterate through it. What I have done is created my own DataSource class that implements JRDataSource. It then has a next() function and a getFieldValue( JRField field). Below is a sample of what i mean. Code: public class SomeDataSource implements JRDataSource { private index = -1; private List someList = null; public SomeDataSource( List someList ) { this.someList = someList; } public boolean next() throws JRException { ++ index; if ( this.someList != null ) { return ( index < this.someList.size() ); } else { return false; } } public Object getFieldValue( JRField field ) throws JRException { Object value = null; A a = (a) this.someList.get( index ); value = a.getY(); return value; } You might need more code in the getField so that you can match your x value with field.getName(). Now what I did was used a map instead of a simple class. I then put the map into a list. So my map represented the fields/columns and then the list contain the rows. Most of the doc does not contain good java examples. I had to dig through the example demo code to figure this out. I hope your head starts to feel better. Calvin
  12. If I am following you correctly what you would do is this: where columnDate >= $P{someDate} and columnDate <= ${someDate} Of course this is for a range. If you are doing = and the date is a "dateTime" variable you will have to consider the time stamp with in that variable. Otherwise, you can substring it to test just the date. Calvin
  13. I don't know if this will help you but we don't set our our subreports like you have done. We get the realPath off the request object. Code:String path = request.getSession().getServletContext().getRealPath("/"«»);Of course, this path represents the root level of our webapp. So if your reports are in a subdirectory you will need to modify this. And then we set a specific parameter that JasperReport uses. Code:[code]parameters.put( "SUBREPORT_DIR", path); Then in the subreportExpression we have the following. Code:[code] <subreportExpression class="java.lang.String"><![CDATA[$P{SUBREPORT_DIR} + "SomeSubReport.jasper"]]></subreportExpression> This might not solve the EOF or the junk you are getting but it will trim some code down. I would also check your path and make sure that the main report can find your subreports. That was our problem in the past with EOF and why we went with the changes above. Calvin
  14. How many times can I say duh!!!. Man I am sorry I posted a dumb question. Thanks for replying Teodor. For others that might not know where Teodor is talking about I will post the code. Code: response.setHeader( "Content-disposition","inline; filename=" + fileName + "." + this.contentType.toLowerCase() );
  15. As I understand it, you need the column to change based on data you are getting from some datasource (database, javabean, etc.). I wouldn't make the column field static. Just make it a regular textField. In the textFieldExpression you can add your condition (I am assuming it is a string). Code: $F{someDataField}.equalsIgnoreCase( "data" ) ? "Column Text" : "" You might have to play with this to get the formatting to work out right on your report; especially if other columns might be position the same way. Calvin
  16. Have you tried printing out your parameter to make sure it has what you need? When you say it does not work, do you mean it is blank? If it isn't blank, then make sure that the main report is passing it down to the subreport correctly. I am not sure what the code looks like but I do know when I do this in iReport I have to make sure I set what parameters I want to pass down to the subreport. Calvin
  17. We needed to create a temp table as well. And what we end up doing was creating the temp table before we called the jasper report. We passed the same connection used for the temp table down to jasper. Then in the query of the report, this report would select against the temp table. I was able to do this in a report that had four subreports. Each of the subreport used the temp table. Hope this is helpful. Calvin
  18. Excellent! We recently solved this too. The same connection does persist for all subreports or subdatasets. I have not tried with multiple crosstabs but with multiple subreports; it works. The only thing that we are concern with is doing this for all our reports. If there are 1000+ users using a website, I know that each would get there own connection but couldn't this be detriment to the database? At some point when it can't fit anymore temp tables in memory, it will start caching to disk. This will definitely defeat the performance gain when using temp tables. For now, we are only using them where we know we get a huge performance increase. Any thoughts on this? Calvin
  19. I believe your solution is fine. Another way you might consider (if using a database source) is to add a table that has months and the unique identifier(is this unique identifier dynamic?). Now with your query, join to this table and do a group by for the identifier. I would then set one the fields to be the month and add the variable to my crosstab. I guess you are already grouping by the unique identifier and setting it as a field for the crosstab. Choices, choices :)
  20. Hello, If this is a dup post please send me to the right post. I am trying to set the OUTPUT_FILE_NAME on an exporter parameter. I am using it for PDF or XLS and I get the same results. Instead of using the filename I passed in it uses the name of the web page I was directed to ( for example if the address is http://..../report.jsf then the file that is created is report.xls or report.pdf). I have no issue with the report itself just the name of the file. Below is the code snippet. Code: JRExporter exporter = new JRXlsExporter(); exporter.setParameter(JRXlsExporterParameter.OUTPUT_FILE_NAME, fileName); exporter.setParameter(JRXlsExporterParameter.JASPER_PRINT, jasperPrint); exporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, Boolean.TRUE); exporter.setParameter(JRXlsExporterParameter.IS_WHITE_PAGE_BACKGROUND, Boolean.TRUE ); exporter.setParameter(JRXlsExporterParameter.IS_DETECT_CELL_TYPE, Boolean.TRUE ); exporter.setParameter(JRXlsExporterParameter.IS_FONT_SIZE_FIX_ENABLED, Boolean.TRUE ); exporter.setParameter(JRXlsExporterParameter.OUTPUT_STREAM, outputStream); exporter.exportReport(); The fileName that is created does not contain any extension. Thanks, Calvin Hill
  21. Hello, This is possible but you will have to implement this in your own application. I am not aware of a way to do it from running inside of iReport. So, I guess the first question I would ask; Are you running your reports under a webapp? If so, then your webapp would need to capture the link (with any necessary parameters) and then call back down to a different report or even the same report. I guess the different query is under a different report. This is the high level view of what we did. Thanks, Calvin
  22. We've experience the same problem. When I have 5 or more reports loaded in iReport and I am moving between reports doing copying, changing the report GUI, or adding parameters. Also, if I have done several test runs with the previewer it will happen. I have not been able to actually nail down at what specific point it happens. Thanks, Calvin
  23. Hello, I have a report that has multiple groups(bands). Each group represents a range in time, i.e. week, month, quarter, YTD. How do I adhere that specific date range to the group. I tried adding it to the Group expression but I am not sure what I need to put. Does it need to be an if condition that returns true or false? Any help on this would be appreciated. Thanks, Calvin
×
×
  • Create New...