Reporting for Mifos is currently powered by Pentaho through the Mifos Business Intelligence Suite (BI). Mifos BI contains a large set of standard reports and a data warehouse to provide for convenience and ease of use when building new reports. BIRT was our previous reporting solution and a small number of our standard reports are still written in BIRT and are directly embedded in the Mifos application.
Mifos BI requires a separate installation which can be done on Windows or Linux. This section provides links to documentation on accessing standard reports in Mifos, understanding the Mifos data model, building new reports, and deprecated documentation on reporting tools like BIRT and Jasper.
The overall reporting and business intelligence solution for Mifos has been transitioned from BIRT to Pentaho. Until the transition is complete, standard reports will be accessed in two different manners via Mifos.
Mifos BI reports have not been directly embedded into the Mifos UI yet; they currently must be accessed by logging into Pentaho via a separate window/tab in your internet browser. We are working on a smoother more integrated user experience for accessing the Mifos BI reports built in Pentaho. The explanation below regarding built-in Mifos report templates only applies to the limited number of embedded reports still written in BIRT.
While our overall reporting tool has been replaced by Pentaho, a number of standard reports are still BIRT-based. This explanation is relevant to those reports but will not be used for any reports going forward. Users can use the embedded BIRT report templates as is, they can edit templates to suit their own needs by changing the layout or adding/removing fields, or they can build their own reports. Report templates are grouped into categories that can be defined and edited by users with the appropriate permissions. A user can attach permissions to a report to specify who can view, edit, and categorize the report.
Generate a report. A user generates a report by selecting it from the Reports tab. The data included in the report is based on the user’s data scope and the parameters entered when generating the report. The report is displayed in PDF format, which can be downloaded. Accessing and using these reports does not require that BIRT (Business Intelligence and Reporting Tools) be installed. More information regarding the generation of each built-in Mifos report is provided later in this section.
Edit a report category. Mifos ships with a standard set of report categories that are used to organize report templates. These can be viewed, edited, deleted, and added to from the Admin tab. Report templates are assigned to categories and displayed under these categories on the Report tab.
MFIs can customize reports that ship with Mifos in the following ways:
Documentation on building custom user-specific reports for Pentaho will be made available soon. See our BIRT Reports in Mifos section for documentation on building custom BIRT reports.
The Mifos Data Model can be tricky to understand. Understanding the Mifos data model including the Mifos production database schema, Mifos Data Warehouse schema and where information lies in what tables is essential to building reports and extracting data.
Linked to from this page are several resources to help you identify where to look for certain client and portfolio information that is stored in Mifos' MySQL Database.
A visualization of the tables in the Mifos database can be accessed from this Schemaspy output of the database.
On our developer wiki on MifosForge, we've created a repository of MySQL queries that are helpful in building out new custom reports in Pentaho, extracting data needed by management and Mifos users, and pulling out information from the Mifos database. Sample queries include number of loans outstanding, branchwise number of loans disbursed and amount disbured during period, etc.
A BIRT training session put together for ENDA in June, 2008
To customize the standard reports provided by default with Mifos or to create your own reports, you will need to download and install version 2.1.2 of the BIRT RCP (Rich Client Platform) Report Designer from Eclipse. The RCP version is required because it produces reports in the version (3.2.6) supported by the BIRT Report Viewer provided with Mifos. It also simplifies the Eclipse user interface so that only essential screens and options are presented.
To install BIRT:
Designing your own report starts with planning it on paper or in a spreadsheet application like Excel. See the following sample: report designed in Excel.
If you are creating your own report, the data in the report can be extracted one of two ways:
For a technical overview on how BIRT interacts with Mifos, see Current Reports Architecture.
To create a custom report that uses SQL to extract data, use the procedure below. For help with steps you perform in BIRT, see the following in the BIRT RCP Designer online help: BIRT Report Developer Guide > Field Guide to BIRT > Learning the Basics > Tutorial 1: Building a Simple Listing Report.
If com.mysql.jdbc.Driver isn't listed, download it from http://dev.mysql.com/downloads/connector/j/5.0.html and place the file mysql-connector-java-5.1.5.bin.jar in ...\mifos\build\src_pkg\WEB-INF\platform\plugins\ where ... is the path to your Mifos working copy. For example, on Windows: C:\subversion\projects\mifos-trunk\mifos\build\src_pkg\WEB-INF\platform\plugins, on Mac OS X or GNU/Linux: /home/user/svn/mifos-trunk/mifos/build/src_pkg/WEB-INF/platform/plugins/.
As you write your query, keep the following in mind:
An input parameter is a value entered by the user. A series of input parameters, called cascading parameters, can dynamically filter, or constrain, the next option's possible values. The Collection Sheet Report uses cascading paramters.
For steps on how to create input parameters (or in BIRT terminology, data-set parameters) see the following section in the BIRT RCP Designer online help: BIRT Report Developer Guide > Field Guide to BIRT > Enabling the User to Filter Data.
The Administrative Documents feature in Mifos allows you to generate a receipt for an account -- without having to use the Reports tab. You can also use this feature to generate other administrative documents specific to an account, such as vouchers and passbooks.
To create a receipt template:
- userId
- account_id
- reportName
When you click an account's receipt link, the system automatically passes in the account ID of the loan account and generates a receipt, based on the BIRT template design you uploaded.
To add labels in another language:
Tips for populating the properties file(s):
To upload and view your report:
To edit your report:
Mifos allows you to control two things related to report security:
You handle the first by associating report-related actions with specific user roles. You handle the second by incorporating one or more parameters in your report that are based on organizational hierarchy.
To manage the permissions related to a report:
If a report has parameters based on organizational hierarchy, a user's access to that report is affected by her position in the organization's hierarchy. For example, if a user is assigned to the Head Office, which is the top of the hierarchy, she can see all report data. If a user is assigned to Branch A, she can only see data for Branch A. If a user is a loan officer, she can only see data for her clients.
The following error indicates that you are using a BIRT extension of Eclipse, instead of the BIRT RCP:
ERROR [STDERR] Caused by: Error.DesignFileException.INVALID_XML - 1 errors found! 1.) (line = 0, tag = null) org.eclipse.birt.report.model.parser.DesignParserException (code = Error.DesignParserException.UNSUPPORTED_VERSION, message : The report file of version "3.2.14" is not supported.)
To resolve this error, install the BIRT RCP.
Jasper is a reporting tool that several users have chosen to build their reports. Pentaho has replaced Jasper and BIRT as our standard reporting solution. All custom reports should be built on Pentaho. For more on Jasper, browse this documentation on Jasper created by SunGard.