Reporting

About the Feature

Bahmni provides multiple options for Reports/Analytics: From out-of-the-box reports for common requirements, to SQL reports, to a secondary analytics database that can pull data from Bahmni and structure it in a reporting amenable (flat) format, etc. Reports are available in PDF, CSV and HTML format. See all details on this in the Implementer Guide: Reporting Overview (Bahmni).

One can also define a Microsoft Excel file with formulas or macros which can be used to create visualizations using the capabilities of Excel.

Report Queue

This feature gives the ability to get results on large data sets. Let's say, to get list of observations recorded for all patients in the past year or six months. This is a huge data set and surely you can't run it using instant reports. Things that can go wrong are server will definitely timeout waiting for result or your web browser will crash trying to load hundreds of MegaBytes of data if you chose HTML / PDF format. So, the approach for report running has been changed. Any report request will be queued and the user can go to 'My Reports' tab to see the status of the request and can download once the processing is complete. The running of report requests are moved to background jobs.

Reports save location (default)

By default if there is no configuration, the reports are saved at  /home/bahmni/reports

Changing the reports save location

In order to override the default behaviour, configure reports_save_dir with the required location. Refer List Of Configurable Installation Variables

Reports SSL Certificate configutation

For configuration of ssl certification check this link Reports SSL certificate configuration

Downloading reports:

All the reports that are run can be seen in 'My Reports' page. The report can have one of the status. If the status is 'Queued' it means that the system accepted the report and will run it. If the status is 'Processing', it means that the system is currently running the report. If the status is 'Download', you can click on the status link and download the report. If it is 'Error', it means that the system encountered an error while trying to run the report and by clicking on the status link, you can see the error message.


Cleanup reports

Scheduled reports that are stored in the file system are automatically removed along with its database entry after configured number of days.  This is done as part of scheduler service from bahmni-reports service. At the time of removal (say 12 AM), if the system is powered off or bahmni-service is down, cleanup process will run automatically once the system is powered on or bahmni-service is resumed.


Default Behaviour

By default, all the reports that are more than 60 days old will be removed every night at 12AM.

Overriding the default behaviour

Default behaviour of the cleanup report service can be overriden  by reconfiguring following property values from bahmni-reports.properties file found in /etc/bahmni-reports folder

Example
reports.cleanup.triggerTime = 0 45 10 * * ? 
reports.cleanup.keepItForNDays = 30

In the above configured entries, cleanup job will run every day at 10.45 AM and will remove the reports that are more than 30 days old.

If you are changing the above configuration, for the new values to be picked up please make sure to restart the bahmni-reports service after any configuration changes.

Command to restart the service
sudo service bahmni-reports restart

For cron trigger time scheduling (reports.cleanup.triggerTime key) check the url : http://www.quartz-scheduler.org/documentation/quartz-2.x/tutorials/crontrigger.html


Where is it Used?

Reports are used by the hospital administrator for extracting data in predefined formats and are used for generating metrics and analysis.

Benefits

Reporting has numerous advantages. Some of them include:

  • Preparing status reports to be submitted to the government, funding agencies, stakeholders, etc.

  • Using the valuable data analysis to bolster advocacy efforts.
  • To be able to optimally follow-up patients.

Screenshot



On this Page

 

Usage Details
Implementation Details



The Bahmni documentation is licensed under Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)