CSV Export not formatting correctly


Hi Team,

We have some static text like report name and run by in Page Header section then we have a table component in the Group Header section to display data in tabular format.

The export works fine in PDF format however with CSV we can see some extra blank columns getting generated like below:

Can you please help me to resolve this issue.

        Test Report        
              Run Date: ########
 Name Login First Name Last Name   Number  Date   Country  
sfdsafdf reykxcfg tyjkurtgerq n rhyreiumk   132356 22-Feb-08      


puneet.040289's picture
Joined: Feb 11 2019 - 10:14pm
Last seen: 2 weeks 1 day ago

1 Answer:


Looks like you're getting some unwanted content in csv output, probably from a page header or title band - look at the 'exclude' optoins in the jasper config reference:


You can exclude items on a per format basis by key (remove on a per element basis) or band (remove entire band) for a specific format. The documentation is a little lacking but a simple google search will get you what you're looking for -

    <property name="net.sf.jasperreports.export.csv.exclude.origin.band.pageHeader" value="pageHeader"/>
darth_fader's picture
Joined: Mar 7 2010 - 9:45pm
Last seen: 3 days 18 hours ago