Jasper Read me
file
Created by The GlobalSolutions
This document walks you through all the
details of the installation location and how to create a simple report. It also
provides details on the user name and passwords to access various modules.
Jasper Installation Details
|
Application |
Version |
Installed Location |
Username/Password |
|
Java |
7.51 |
C:\Program
Files(X86)\Java\ |
|
|
Tomcat |
7.0.4 |
C:\Program
Files(X86)\Tomcat 7.0\ |
|
|
Postgresql |
9.3.2 |
C:\Program
Files(X86)\PostgreSQL\ |
Username -postgres Password - postgres |
|
JasperReports Server |
5.2.0 |
C:\Program
Files(X86)\jasperreports-server-cp-5.2.0\ |
Username - jasperadmin Password - jasperadmin |
|
iReport Designer |
5.5 |
C:\Program
Files(X86)\Jaspersoft\ |
|
Snapshot of the Installed Location

Accessing Postgresql database
Ø Goto
Start, select pgAdminIII.
Ø Right
click on PostgreSQL 9.3 server and click Connect
Ø Give
the username and password mentioned in the above table.
Accessing iReport designer
Ø Go
to Start > All applications >Jaspersoft.
Ø Click
on iReport-5.5.0 to launch the designer.
Note:
Based on the operating system the above path might change to start/open the iReport designer to create a report.
Creating report in iReport designer
Step
1: Connecting to Database – This step is required to determine the database
from which you are planning to build the report.
Ø In
order to connect to the database click on the Report Datasources
icon ( located in the top left of the screen) to choose the database we need to
connect to as shown below,

Ø Select
Report datasource as “Sample Database(HSQLDB test)”
and click the modify button as shown in below snapshot,

Ø Click
on Test button to check if connection is successful.
Ø Click
Ok

Click save and close the other windows.
Note:
We have used a sample database to generate the
report. Users can connect to their respective databases for testing the
product.
We have already created a sample report ‘GS_SampleReport’ by fetching data from the ORDERS table in
the sample database.
Users can create a similar report by following the
below steps and get feel on the report creation process. The below steps will
walk you through
the
steps we followed to create the report.
Step
2: Creating a report from the database that we connected in Step 1
Ø Click
step 2 icon as shown below,

Ø Click
on Report to list the templates that are already available. User can choose
from one of the existing sample report format. By choosing Blank Report user
can design the report as per his needs.

Ø Click
‘Open this template’, mention the target location and give the name for the
report to be created. Click Next and then finish.
Note:
By default, the report name will be
populated as ‘ReportN.jrxml’
where N is a number as highlighted in the below snapshot. This number ‘N’ keeps
incrementing every time the user creates a new report. Users can rename the
file based on their naming conventions. In our sample report we have named the
.jrxml file as ‘GS_SampleReport.jrxml’.
Please provide the name that you want your report to be called in the “Report
Name” field

Ø Click
Report Query (highlighted below) and write the required SQL and click OK
button. By doing this, the fields from the selected table get loaded in the
report inspector tab. In our sample report we selected the orders table as we
built the reports based on the data in that table. For you to create a sample
report you can also select the order table as shown below

Ø In
the report inspector tab, expand the “Fields”, drag and drop the required
fields into the Detail 1 section of the report template.

Ø In
the sample report, we have used the following fields: CUSTOMERID, ORDERDATE,
SHIPNAME, SHIPADDRESS and SHIPPOSTALCODE from ORDERS table. Users can select
different set of fields to create their report by dragging them to the Detail 1
pane in the middle of the window as shown below. As soon as the fields are
dropped in the detail’s 1 section you can see the corresponding column names
being created in the above section which is called “ Column heading “. Below is
a snapshot for reference.

Ø The
title, header and footer can be given by the user. Use the properties under palette
to design the report. If you don’t see the palette on the right side of your
screen go to the top menu select windows -> palette and you should be able
to see it on the right. For example in our case we used the “label Static Text”
to create the title. Pull the “label Static text” field in to the Title section
and type your title.

Ø If
there is any error during report creation, the error message will be displayed
in the Report Problems Window.

Step
3: Run the report
Ø Once
we design the report successfully, clicking on preview executes the .jrxml file and generates report in the preview tab,


Accessing Jasper Server
Ø Open
IE, http://localhost:8080/jasperserver/ - A shortcut (Jaspersoft.mht) is available in
the desktop, just double clicking that will take to the login screen as well.
Ø Enter
the username and password mentioned in the above table.
Launching Report in the Jasper Server
Below is the step we followed to post the sample
report ‘GS_SampleReport’ in Jasper Server. Users can
follow these steps to post their new report in Jasper Server.
Ø Right
Click Reports folder > Add Resource > Jasper Report
Ø In
the Report setup page, enter the name, resource id, description and the .jrxml file name you created (by default the .jrxml file will be located in the following location C:\Program
Files (x86)\Jaspersoft\SampleReports).
Ø Click
on Data Source, select “data store from repository “- > browse - > expand
“Data Sources” and select “JServer Jdbc Data Source” and hit the select button, you should see
like the below image once everything is done.

Ø Click
on submit.
Ø By
submitting, the report gets added to the repository. Here, the sample report we
created is GS_SampleReport. Users should select their
reports to load them.

Ø Click
the report GS_SampleReport (Users should select their
report) and the report gets loaded successfully as shown below,

If you have any question, please send an email support@theglobalsolutions.net
or open a ticket at www.theglobalsolutions.net