Screenshot instructions:
Windows
Mac
Red Hat Linux
Ubuntu
Click URL instructions:
Right-click on ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)
You can subscribe to this list here.
2002 |
Jan
|
Feb
(1) |
Mar
(4) |
Apr
(17) |
May
(18) |
Jun
(5) |
Jul
(12) |
Aug
(22) |
Sep
(3) |
Oct
(36) |
Nov
(25) |
Dec
(37) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(69) |
Feb
(27) |
Mar
(22) |
Apr
(35) |
May
(82) |
Jun
(54) |
Jul
(63) |
Aug
(69) |
Sep
(30) |
Oct
(47) |
Nov
(36) |
Dec
(41) |
2004 |
Jan
(92) |
Feb
(94) |
Mar
(77) |
Apr
(72) |
May
(49) |
Jun
(47) |
Jul
(35) |
Aug
(24) |
Sep
(40) |
Oct
(73) |
Nov
(100) |
Dec
(59) |
2005 |
Jan
(38) |
Feb
(43) |
Mar
(174) |
Apr
(69) |
May
(44) |
Jun
(32) |
Jul
(24) |
Aug
(102) |
Sep
(53) |
Oct
(66) |
Nov
(67) |
Dec
(51) |
2006 |
Jan
(80) |
Feb
(43) |
Mar
(42) |
Apr
(103) |
May
(39) |
Jun
(92) |
Jul
(44) |
Aug
(35) |
Sep
(53) |
Oct
(28) |
Nov
(12) |
Dec
(9) |
2007 |
Jan
(10) |
Feb
(16) |
Mar
(9) |
Apr
(13) |
May
(11) |
Jun
(7) |
Jul
(3) |
Aug
(9) |
Sep
(6) |
Oct
(11) |
Nov
(20) |
Dec
(11) |
2008 |
Jan
(15) |
Feb
(8) |
Mar
(10) |
Apr
(6) |
May
(4) |
Jun
(10) |
Jul
(9) |
Aug
(16) |
Sep
(9) |
Oct
(8) |
Nov
(6) |
Dec
(14) |
2009 |
Jan
(8) |
Feb
(5) |
Mar
(6) |
Apr
(16) |
May
(6) |
Jun
(21) |
Jul
(7) |
Aug
(6) |
Sep
(8) |
Oct
(14) |
Nov
(17) |
Dec
(4) |
2010 |
Jan
(3) |
Feb
(9) |
Mar
(9) |
Apr
(2) |
May
|
Jun
|
Jul
(3) |
Aug
|
Sep
(1) |
Oct
|
Nov
(1) |
Dec
(4) |
2011 |
Jan
(1) |
Feb
(1) |
Mar
|
Apr
|
May
(2) |
Jun
(3) |
Jul
|
Aug
(2) |
Sep
(2) |
Oct
|
Nov
(1) |
Dec
|
2012 |
Jan
(1) |
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
(1) |
Nov
(2) |
Dec
|
2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
1
|
2
(16) |
3
(16) |
4
(6) |
5
(4) |
6
|
7
|
8
(4) |
9
(10) |
10
(4) |
11
(1) |
12
|
13
(1) |
14
|
15
(5) |
16
(14) |
17
(1) |
18
(2) |
19
(5) |
20
(1) |
21
|
22
|
23
(1) |
24
(4) |
25
(1) |
26
|
27
|
28
|
29
(2) |
30
(2) |
|
|
|
|
From: Srinivasan Ranganathan <srirang@ma...> - 2004-11-15 22:04:32
|
Rama Mohan Pacific Net wrote: > Hi, > > As part of our project, we have two situations we had to address. I > am sure some / all of you will meet similar situations as u use > jasperReports extensively as we have done. I would, therefore, like > to share with u the situations and the enhancements we have done. I > hope these could be useful to all of you out there and maybe Teodor > could add them to the Jasper Packaging. > > Scenario 1: Print details of customer and his address. The data is > split into two separate Java Beans. (For simplicity only attributes > are shown. The accessors and mutators are left out). > > One (Customer) -> One (Address) > > The JRBeanDataSource only supports accessing properties of Customer > and the properties of Address itself cannot be printed. Using our > enhancement, the properties must be specified in JasperReports' XML > design as > > <field name="cust_id" ... /> > <field name="cust_name" ... /> > <field name="address__address" ... /> <!-- note the __ double > underscore --> > <field name="address__city" ... /> > <field name="address__country" ... /> > > The NestedBeanCollectionDS interprets the __ and translates into > object.getAddress().getCity(). This is a really good idea. This basic idea has been taken further and developed into an "Object Graph Navigation Language" http://www.ognl.org/. Instead of reinventing the wheel, I think jasper reports can use ognl. Just my 2c worth. Cheers Srini |
From: Md. Mortoza Ali Khan <mortoza_khan@ya...> - 2004-11-15 17:59:36
|
Hi Ram Mohan That's great! Now, we await to get the enhanced version of Jasperreports and iReports. Regards, Mortoza Rama Mohan Pacific Net <ramohan@...> wrote: Hi, As part of our project, we have two situations we had to address. I am sure some / all of you will meet similar situations as u use jasperReports extensively as we have done. I would, therefore, like to share with u the situations and the enhancements we have done. I hope these could be useful to all of you out there and maybe Teodor could add them to the Jasper Packaging. Scenario 1: Print details of customer and his address. The data is split into two separate Java Beans. (For simplicity only attributes are shown. The accessors and mutators are left out). One (Customer) -> One (Address) The JRBeanDataSource only supports accessing properties of Customer and the properties of Address itself cannot be printed. Using our enhancement, the properties must be specified in JasperReports' XML design as The NestedBeanCollectionDS interprets the __ and translates into object.getAddress().getCity(). Scenario 2: Print details of Customer, all his accounts, and transactions in each account (consolidated statements). E.g., Customer 12345 Name: Jack Account 4000 1234 1234 1234 VISA Balance: 1,230.00 Tran Date Description Amount --- --------- -------- --- --------- -------- --- --------- -------- Account 5000 1234 1234 1234 MasterCard Balance: 230.00 Tran Date Description Amount --- --------- -------- --- --------- -------- --- --------- -------- The way we address such reports is to have Report 1: Master report. Prints customer details. Uses Sub Report 1 to print details of accounts & transactions. Report 2: Sub Report 1: Prints account details. Uses Sub Repot 2 to print details of transactions. Report 3: Sub Report 2: Prints transaction details. The data structure typically is one (customer) -> many (accounts) -> many (transactions) In this case Customer contains a collection of Account beans, Account in turn consists of a collection of Transaction beans. Fields in Report 1 (Master Report) are Data to sub report is passed as follows During execution, the NestedBeanCollectionDS returns the accountCol (which is a Collection object) wrapped as a NestedBeanCollectionDS. This way Report 2 (Sub report 1) will get a DataSource that JasperReports understands. Similarly field in Report 2 (Sub Report 1) Data to sub report is passed as follows And, finally fields in Report 3 (Sub Report 2) are: Please feel free to ask any clarifications. Thanx N Best Regards Rama Mohan Rao PS: We have enhanced iReport to automatically recognise nested bean properties. I will share that enhancement in a separate mail. package jasperReports.ext; import dori.jasper.engine.JRException; import dori.jasper.engine.JRField; import dori.jasper.engine.JRRewindableDataSource; import org.apache.commons.beanutils.PropertyUtils; import java.lang.reflect.Method; import java.util.ArrayList; import java.util.Collection; import java.util.Iterator; /** * NestedBeanCollectionDS * Represents a data source in which each record is represented by a JavaBean * and fields of the record are properties of the JavaBean and its member * JavaBeans. * */ public class NestedBeanCollectionDS implements JRRewindableDataSource { /** * Relies on Apache Commons BeanUtils for retrieving values of nested beans. * Uses __ to denote a nested property instead of '.' dot. */ private Collection data = null; private Iterator iterator = null; private Object currentBean = null; /** * Creates a new NestedBeanCollectionDS object. * * @param beanCollection */ public NestedBeanCollectionDS(Object bean) { if( bean == null) { throw new NullPointerException(); } if( bean instanceof java.util.Collection) { this.data = (java.util.Collection)bean; } else { ArrayList al = new ArrayList(); al.add(bean); this.data = al; } if (this.data != null) { this.iterator = this.data.iterator(); } } /** * next * * @return boolean * * @throws JRException */ public boolean next() throws JRException { boolean hasNext = false; try { if (this.iterator != null) { hasNext = this.iterator.hasNext(); if (hasNext) { this.currentBean = this.iterator.next(); } } return hasNext; } finally { /** * The data source can be used repeatedly. * E.g., once for view and once for print. * To ensure that every time a report is requested the pointer is * at the top of the data source, we must reset the iterator once * we reach the end of the report. */ if (!hasNext) { if (this.data != null) { this.iterator = this.data.iterator(); } } } } /** * getFieldValue. * Based on field name, retrieves the field value from the underlying * JavaBean. * a) Replaces '__' that denote a nested property with '.' and uses Apache * Common's PropertyUtils to retrieve the value. * b) If the retrieved value is a Collection, returns a * NestedBeanCollectionDS that wraps the underlying Collection. This * facilitates passing of collections to sub-reports. * * @param jrField * * @return returns Field Value * * @throws JRException */ public Object getFieldValue(JRField jrField) throws JRException { Object value = null; String dot = "__"; if (currentBean != null) { String fieldName = jrField.getName(); String fieldName2 = fieldName.replaceAll("__", "."); try { value = PropertyUtils.getProperty(currentBean, fieldName2); if (value instanceof java.util.Collection) { value = new NestedBeanCollectionDS((Collection) value); } } catch (Exception e) { throw new JRException("fail to get field value for "+fieldName+ " in bean "+ currentBean.getClass().getName(), e); } } return value; } /** * getValue * * @param fieldName * @param jrFieldValueClass * @param bean * * @return Object * * @throws JRException */ private Object getValue(String fieldName, Class jrFieldValueClass, Object bean) throws JRException { Object value = null; Class beanClass = bean.getClass(); fieldName = fieldName.substring(0, 1).toUpperCase()+ fieldName.substring(1); String methodName = "get"+fieldName; Method method = null; try { method = beanClass.getMethod(methodName, null); } catch (NoSuchMethodException e) { } if (method == null && jrFieldValueClass == Boolean.class) { try { methodName = "is"+fieldName; method = beanClass.getMethod(methodName, null); } catch (NoSuchMethodException e) { } } if (method == null) { throw new JRException("Property getter method not found in bean for the field : "+ fieldName); } else { try { value = method.invoke(bean, null); } catch (Exception e) { throw new JRException("Error retrieving field value from bean : "+ methodName, e); } } return value; } /** * moveFirst * * @throws JRException */ public void moveFirst() throws JRException { if (this.data != null) { this.iterator = this.data.iterator(); } } } __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |
From: Rama Mohan Pacific Net <ramohan@pa...> - 2004-11-15 15:26:19
|
Hi Kalpesh, Firstly, JasperReports is 'Java'. I.e., u can specify all file paths using / (forward slash). UNIX or DOS. Secondly, there are a few ways to address SQL issues. 1) pass the SQL as a parameter and use the following <queryString><![CDATA[$P!{sqlQuery}]]> </queryString> 2) use ANSI-SQL and desist from using database specific extensions (e.g., ORACLE's + for outer join) 3) use a product like OJB to query data and pass the queried data as a Collection of Java Beans. Hope this helps. Best Regards Rao (Rama Mohan Rao) --- Original Message ---- Hi, I pass SQL connection to jasper fillManager() which in turn executes the SQL queries written in query section of the template. The queries written are MS-SQL specific. Now, I want to use same template for Oracle DB. Now, the problem is SQL queries written in query section of template will fail on Oracle database. So, can I pass query string in parameter map ? If yes, how to access the parameter map in query section ? Current setup is Windows 2000 with MS-SQL 2000. So, all our templates have MS-SQL specific queries hard-coded in template design with subreports included in main templates and accessed like <subreportExpression class="java.io.File"><![CDATA[new File($V{BaseDir}+"\\reports\\"+$P{PARTITION_ID}+"\\templates\\12004", $P{SUBREPORT_SUMMARY_FILE_NAME})]]></subreportExpression> Now, we are moving towards SOLARIS - ORACLE combination. We do not want to keep two copies of template with only change in query section. This will increase our maintenance. So, our aim is to create OS + DB independent template. Also, the path mentioned above uses back slash but Solaris needs front slash (I am not sure). How to achieve same in the template during design time only. All you suggestions/comments are most welcome. We want to submit the efforts required at earliest. So, please give me suggestions at earliest. Thanks and Regards, Kalpesh |
From: Kalpesh Chordia <kchordia@eg...> - 2004-11-15 13:40:43
|
Hi, I pass SQL connection to jasper fillManager() which in turn executes the SQL queries written in query section of the template. The queries written are MS-SQL specific. Now, I want to use same template for Oracle DB. Now, the problem is SQL queries written in query section of template will fail on Oracle database. So, can I pass query string in parameter map ? If yes, how to access the parameter map in query section ? Current setup is Windows 2000 with MS-SQL 2000. So, all our templates have MS-SQL specific queries hard-coded in template design with subreports included in main templates and accessed like <subreportExpression class="java.io.File"><![CDATA[new File($V{BaseDir}+"\\reports\\"+$P{PARTITION_ID}+"\\templates\\12004", $P{SUBREPORT_SUMMARY_FILE_NAME})]]></subreportExpression> Now, we are moving towards SOLARIS - ORACLE combination. We do not want to keep two copies of template with only change in query section. This will increase our maintenance. So, our aim is to create OS + DB independent template. Also, the path mentioned above uses back slash but Solaris needs front slash (I am not sure). How to achieve same in the template during design time only. All you suggestions/comments are most welcome. We want to submit the efforts required at earliest. So, please give me suggestions at earliest. Thanks and Regards, Kalpesh |
From: Rama Mohan Pacific Net <ramohan@pa...> - 2004-11-15 05:24:19
|
package jasperReports.ext; import dori.jasper.engine.JRException; import dori.jasper.engine.JRField; import dori.jasper.engine.JRRewindableDataSource; import org.apache.commons.beanutils.PropertyUtils; import java.lang.reflect.Method; import java.util.ArrayList; import java.util.Collection; import java.util.Iterator; /** * NestedBeanCollectionDS<br> * Represents a data source in which each record is represented by a JavaBean * and fields of the record are properties of the JavaBean and its member * JavaBeans.<br> * <br> */ public class NestedBeanCollectionDS implements JRRewindableDataSource { /** * Relies on Apache Commons BeanUtils for retrieving values of nested beans.<br> * Uses __ to denote a nested property instead of '.' dot. */ private Collection data = null; private Iterator iterator = null; private Object currentBean = null; /** * Creates a new NestedBeanCollectionDS object. * * @param beanCollection */ public NestedBeanCollectionDS(Object bean) { if( bean == null) { throw new NullPointerException(); } if( bean instanceof java.util.Collection) { this.data = (java.util.Collection)bean; } else { ArrayList al = new ArrayList(); al.add(bean); this.data = al; } if (this.data != null) { this.iterator = this.data.iterator(); } } /** * next * * @return boolean * * @throws JRException */ public boolean next() throws JRException { boolean hasNext = false; try { if (this.iterator != null) { hasNext = this.iterator.hasNext(); if (hasNext) { this.currentBean = this.iterator.next(); } } return hasNext; } finally { /** * The data source can be used repeatedly. * E.g., once for view and once for print. <br> * To ensure that every time a report is requested the pointer is * at the top of the data source, we must reset the iterator once * we reach the end of the report. */ if (!hasNext) { if (this.data != null) { this.iterator = this.data.iterator(); } } } } /** * getFieldValue.<br> * Based on field name, retrieves the field value from the underlying * JavaBean.<br> * a) Replaces '__' that denote a nested property with '.' and uses Apache * Common's PropertyUtils to retrieve the value.<br> * b) If the retrieved value is a Collection, returns a * NestedBeanCollectionDS that wraps the underlying Collection. This * facilitates passing of collections to sub-reports. * * @param jrField * * @return returns Field Value * * @throws JRException */ public Object getFieldValue(JRField jrField) throws JRException { Object value = null; String dot = "__"; if (currentBean != null) { String fieldName = jrField.getName(); String fieldName2 = fieldName.replaceAll("__", "."); try { value = PropertyUtils.getProperty(currentBean, fieldName2); if (value instanceof java.util.Collection) { value = new NestedBeanCollectionDS((Collection) value); } } catch (Exception e) { throw new JRException("fail to get field value for "+fieldName+ " in bean "+ currentBean.getClass().getName(), e); } } return value; } /** * getValue * * @param fieldName * @param jrFieldValueClass * @param bean * * @return Object * * @throws JRException */ private Object getValue(String fieldName, Class jrFieldValueClass, Object bean) throws JRException { Object value = null; Class beanClass = bean.getClass(); fieldName = fieldName.substring(0, 1).toUpperCase()+ fieldName.substring(1); String methodName = "get"+fieldName; Method method = null; try { method = beanClass.getMethod(methodName, null); } catch (NoSuchMethodException e) { } if (method == null && jrFieldValueClass == Boolean.class) { try { methodName = "is"+fieldName; method = beanClass.getMethod(methodName, null); } catch (NoSuchMethodException e) { } } if (method == null) { throw new JRException("Property getter method not found in bean for the field : "+ fieldName); } else { try { value = method.invoke(bean, null); } catch (Exception e) { throw new JRException("Error retrieving field value from bean : "+ methodName, e); } } return value; } /** * moveFirst * * @throws JRException */ public void moveFirst() throws JRException { if (this.data != null) { this.iterator = this.data.iterator(); } } } |