11.07.2015 Views

Setting Up iReport for Fishbowl - Fishbowl Inventory

Setting Up iReport for Fishbowl - Fishbowl Inventory

Setting Up iReport for Fishbowl - Fishbowl Inventory

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Setting</strong> <strong>Up</strong> <strong>iReport</strong> <strong>for</strong> <strong>Fishbowl</strong><strong>iReport</strong> is automatically installed along with your <strong>Fishbowl</strong> <strong>Inventory</strong> software.This section will show you how to setup <strong>iReport</strong> so you can create new reports and modify the reportsthat are installed with <strong>Fishbowl</strong> <strong>Inventory</strong>. Reports that you create or modify may need to be compiledor rebuilt whenever your <strong>Fishbowl</strong> <strong>Inventory</strong> software is upgraded because the database structure mayhave changed.While you may be able to make minor changes to existing reports without much trouble, you will need aworking knowledge of SQL and Java to build new reports.This section will help you with the following tasks:1. <strong>Setting</strong> <strong>Up</strong> <strong>iReport</strong> <strong>for</strong> the <strong>Fishbowl</strong> Server Computer2. <strong>Setting</strong> up <strong>iReport</strong> on a <strong>Fishbowl</strong> Client Computer3. Compiling and saving changes to reports1. <strong>Setting</strong> <strong>Up</strong> <strong>iReport</strong> <strong>for</strong> the <strong>Fishbowl</strong> Server ComputerOpening <strong>iReport</strong>Open <strong>iReport</strong> by clicking on the Start button. Select All Programs | <strong>Fishbowl</strong> | <strong>iReport</strong> | <strong>iReport</strong><strong>Setting</strong> <strong>Up</strong> a Database Connection<strong>iReport</strong> already includes two database (aka datasource) connections to <strong>Fishbowl</strong>: one to the Bicyclesdatabase (example.fdb) and another to the default company database (event.fdb). Even with this youmay need to modify the “<strong>Fishbowl</strong> Company” connection to point to your company’s database.In <strong>iReport</strong>, click on the Data menu and choose Connections/Datasources. Highlight the line named‘<strong>Fishbowl</strong> Company’ and click the Modify button (shown below).


In the Connections properties window you will need to change the following:JDBC Driver: org.firebirdsql.jdbc.FBDriverJDBC URL:jdbc:firebirdsql://localhost/\Program Files\<strong>Fishbowl</strong>\database\data\EVENT.FDB.Username: gonePassword: fishingIf you did not install <strong>Fishbowl</strong> to the default location, you will also need to change the file path in JDBCURL. The file path (C:\Program Files…) should match the location and name of your database. Inthis example we are connecting to the ‘EVENT.FDB’ database installed in the default location.All other fields will not need to be changed.Note: Port 3050 must be open so <strong>iReport</strong> can connect to the database.After you have done this, click “Test” to make sure the connection is successful.


<strong>Setting</strong> <strong>Up</strong> an Active ConnectionThe Active Connection allows you to immediately check changes that you make to reports to see if theyhave any errors.Set the Active Connection by going to Data | Set active connection. Select <strong>Fishbowl</strong> Company and clickOk.<strong>Setting</strong> <strong>Up</strong> ClasspathsClasspaths are java files that <strong>iReport</strong> uses to connect and run properly with your in<strong>for</strong>mation in <strong>Fishbowl</strong>.You will need to have the following six files in your Classpath window (the number 5.1 may be differentdepending on your version):elfgr-5.1.jareve-5.1.jareve-commons-5.1.jarfbcore-5.1.jarfirebirdsql-full-2.1.1.jar (or firebirdsql-full-1.5.5.1.jar if on version 4.7 or earlier)util-5.1.jarThese files are available (assuming default installation) in C:\Program Files\<strong>Fishbowl</strong>\lib1. Choose Options | Classpath2. Click Add JAR. Navigate to the Program Files\<strong>Fishbowl</strong>\lib. Hold down the control key and click on thesix files listed (or you can just highlight them all). Click Open and the files should appear in the Classpathwindow.This completes the setup process and you can now modify and create reports <strong>for</strong> <strong>Fishbowl</strong>. Anabbreviated version of the <strong>iReport</strong> Manual was installed with <strong>Fishbowl</strong> and you can download thecomplete <strong>iReport</strong> Manual from ireport.source<strong>for</strong>ge.net/manual0.2.0.html.


2. <strong>Setting</strong> <strong>Up</strong> <strong>iReport</strong> on a <strong>Fishbowl</strong> Client Computer<strong>Setting</strong> <strong>Up</strong> a Database ConnectionThe process <strong>for</strong> setting up <strong>iReport</strong> on a Client computer is similar to the Server setup. The only differenceis in the database connection (JDBC URL).JDBC Driver: org.firebirdsql.jdbc.FBDriverJDBC URL:jdbc:firebirdsql://192.168.1.10 /C:\Program Files\<strong>Fishbowl</strong>\database\data\event.FDB where 192.168.1.10is the IP address <strong>for</strong> the <strong>Fishbowl</strong> server and the file path is the location of the database file on thatserver.Username: gonePassword: fishingIf you did not install <strong>Fishbowl</strong> to the default location, you will also need to change the file path in JDBCURL. The file path should match the location and name of your database on your server.Note: Port 3050 must be open so <strong>iReport</strong> can connect to the database.After you have done this, click “Test” to make sure the connection is successful.<strong>Setting</strong> <strong>Up</strong> an Active Connection and ClasspathsUse the server instructions above to setup the Active Connection and Classpaths. The Classpath files willbe available on your current computer.


3. Creating, saving and running an <strong>iReport</strong> report in <strong>Fishbowl</strong>Select: File | Report Wizard. Enter a SQL query into the “SQL Query” box and then click Next.Example: SELECT * FROM partChoose the fields that you would like to view in your report by adding them to the box on the right side.


You may choose a field to group your results by. In this example we will not choose anything so clickNext.You can now choose a layout design. Any layout that contains the name “<strong>Fishbowl</strong>” and “ltr” is designedto print on a 8 ½ X 11 page.


You have now completed the Report Wizard and are ready to begin designing your report.The design tools and options are outlined in the <strong>iReport</strong> manual which you can download from the<strong>iReport</strong> website at http://jasper<strong>for</strong>ge.org/sf/projects/ireport.


Saving and Compiling-In order <strong>for</strong> your reports to run inside of the <strong>Fishbowl</strong> reports module you must save two files on theserver computer in the ..\<strong>Fishbowl</strong>\Server\Reports folder.-The two files you need are created when you compile and save a report in <strong>iReport</strong>. The first file is a“*.jrxml” and the second is a “*.jasper” file.-The name that you save the report cannot contain spaces.You can also provide each report with its own report name so that you can distinguish it in <strong>Fishbowl</strong> fromother reports. To do this click Edit | Report Properties from within <strong>iReport</strong>. Under the box tiled “ReportName” type out the name. This name cannot contain spaces.


Once you have designed and saved a report to the <strong>Fishbowl</strong> reports folder you must tell <strong>Fishbowl</strong> to look<strong>for</strong> new reports in the reports folder. To do this open the Reports module. Click Tools | Module optionsand click the Refresh button.Now you will be able to see and run the report from any <strong>Fishbowl</strong> Client.The report will show up in the reports list as you entered the report name. You can also organize yourcustom reports by creating new folders in the <strong>Fishbowl</strong>/Server/Reports directory.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!