September 03, 2013

Step 3 : Design a query of database

  1. Click on icon Design query database like below.


  2. Write a query in textbox (Example : SELECT * FROM Patients) and click button OK.

  3. Change the languages of query.

Step 2 : Create a connection of database

  1. Click on icon connection database.


  2. Click on button New to set-up new connection.


  3. Choose Database JDBC Connection and click on button Next >


  4. Field up textfield Name, JDBC Driver, JDBC URL, Username and Password of connection. Click button Save.


  5. Below is list of connection. By Default it must be clicked on any connection. 







Step 1 : Create a new blank report design

  1. Click File -> New.


  2. Choose Report -> Blank A4 and click button Open this Template


  3. Rename Report Name and click button Next >


  4. Click button Finish


  5. Viewed of blank sample report.

September 02, 2013

Introduction to IReport Designer

Sources from :- IReport Designer .


  • Free, open source report designer
  • Sophisticated layout containing charts, images, subreports, crosstab and etc.
  • Access your data through
    • JDBC
    • TableModels
    • Javabean
    • XML
    • Hibernate
    • CSV
    • Custom sources
  • Publish reports as
    • PDF
    • RTF
    • XML
    • XLS
    • CSV
    • HTML
    • XHTML
    • text
    • DOCX
    • OpenOffice
The simple workflow can be guided:
  1. Create a new blank report design
  2. Create a connection of database
  3. Design a query of database
  4. Drag field to details of band
  5. Adjust the design



SQL Join

Ada 4 jenis Join iaitu :-

  1. Inner Join
  2. Left Join
  3. Right Join
  4. Full Join
INNER JOIN = JOIN



LEFT JOIN = LEFT OUTER JOIN


RIGHT JOIN = RIGHT OUTER JOIN


FULL OUTER JOIN


SQL Aliases - Combine the column

SQL Syntax:

Select
     CustomerName,
     Address + ',' City + ',' + Postcode + ',' Country AS Address
From
     Customers;

Results: