Hi! 1. As I understood from your xml data source you probably need to consider changing it a bit because you might have different number of C element occurrences... Will this one work for you? I attached it as data1.xml file <?xml version="1.0" encoding="UTF-8"?> <A id="tt"> <B id="Monday"> <C> <D>2009-03-04</D> <E>502</E> </C> <C> <D>2009-03-04</D> <E>502</E> </C> <C id="kk"> <D>2009-03-04</D> <E>502</E> </C> <C id="ii"> <D>2009-03-04</D> <E>502</E> </C> </B> <B id="tuesday"> <C> <D>2008-03-04</D> <E>502</E> </C> <C> <D>2008-02-04</D> <E>502</E> </C> <C id="kk2"> <D>2008-01-04</D> <E>502</E> </C> <C id="ii2"> <D>2009-03-06</D> <E>502</E> </C> </B> </A> 2. You need to create Master report where you'll be iterating over days of the week (element B) and include Subreport where you'll be iterating over all C's that you have in this day I provided a master's datasource to the subreport with this expression: ((net.sf.jasperreports.engine.data.JRXmlDataSource) $P{REPORT_DATA_SOURCE}).dataSource("/A/B[@id="+$F{WeekDay}.toString()+"]/C") Note: this will work only in case your B element have different id's cause a subreport's datasource rely on uniqueness of B element Hope this will help! Regards, Andriy