Enterprise Java

Birt Made Report Easy

Here is the complete guide to build report in Eclipse using Birt plugin.

Birt or Business Intelligence and Reporting tool is a tool that can build report without writing toooo many java codes. If you are using ireport you know what I’m talking about :) (crystal report.. no point :D)

Main draw back in Ireport is we have to write too many codes to build simple report that can integrate to java application. But in Birt no need to write codes just drag n drop.

Birt is a Eclipse Plugin (Only to Eclipse) that you can download. So in this article we demonstrate how to build some sample report with ease of drag n drop :)

Here we go…

Step 1

  • Download Eclipse (http://www.eclipse.org/)
    • You can download eclipse for report users (Comes with Birt Plugin)
  • If you already have eclipse just install the birt plugin
    • Help –> Install New Software –> Click Add
    • Give name as Birt and give location as http://download.eclipse.org/birt/update-site/3.7-interim/
    • Click Ok
    • Select All packages (tic) and accept the license agreement (whether we like it or not :P ).
    • It will take some time to download all the packages and after the download restart the eclipse.

Step 2

  • Before make project adjust your perspective to Report Design
  • To do that Window –> Show View –> Other
  • Select Report tab and select all the fields

Step 3

  • Now its the time to create new project
  • File –> New –> Other –> Business Intelligence and Reporting Tool –> Report Project
  • Give a Name for the Project and click finish.

Step 4

  • Now the Project is created. But we have to create a report.
  • To do that File –> New –> Other –> Business Intelligence and Reporting Tool –> Report
  • Give a name for report and and click Next.
  • In here you can choose the report template. (If you have one you can use it. but before you have to register the report template. will talk about this later)
  • I choose Blank Report and click Finish.

Step 5

  • Now report is ok. But we need to display data.
  • Click Palette in Left Hand side (this is the place that all controls have) and drag n drop Table component to report design.
  • Give number of rows and columns and click Ok.
  • Now you can see the table in report view (layout you are currently in)

Step 6

  • So the basic designing part is done. but data?? (give me 5 min)
  • Click on the Data Explorer (right hand sof Palatte) –> right click and select new data source
  • In here we can configure the database. For this demo we configure in built database that comes up with Birt. (Classic Model) (Others will talk later)
  • Select Classic Models –> Next –> Finish.

Step 7

  • Right click data set –> new data set –> Next
  • In the query window you can see the databases available.
  • Select CLASSICMODELS expand it.
  • In the query text area you can write the SQL query.
  • In here we select customer name, customer first name and customer phone (You can do this by double clicking the table values in Available items)
  • After click Ok you can see the window edit data set (if you have any query issue it will show some error window)

Step 8

  • Click Preview tab (in layout are) and you can see the output of data.
  • Run –> View Report –> In web browser –> you can see the report in web browser.
  • Can give more advance function like export to doc, pdf, ppt and many more.

Here is some basic things about Birt report. But Birt is more than that. You can write javascript to get more functionality. We will talk about this later. That means the Advance Birt :)

Reference: Birt Made Report Easy from our JCG partner Rajith Delantha at the Looping around with Rajith… blog.

Rajith Delantha

Rajith is an software engineer, open source contributor and love to develop application based on open source projects.
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
J. Theisen
J. Theisen
8 years ago

Thanks for posting about BIRT, BIRT is a very nice package to create reports and visualizations for our data and with the ability to extend the reports with Java or JavaScript gives the ability to create pretty complicated reports easily, our company uses COGNOS and bitt can create most any report that COGNOS can at a fraction of the cost:)) thanks for the write up

Back to top button