Mifos X Database
Mifos X ER diagram - All table (pdf)
Core MifosX Database Tables (pdf)
MifosX Application Users, Roles and Permissions Tables( pdf)
MifosX Code, Enum, Notes and CurrencyTables (pdf)
MifosX Reporting MetaData Tables (pdf)
Table Name | Description |
---|---|
Core Tables | |
m_office | Offices and Branches. Hierarchical structure. There is a 'hierarchy' field which has a dot notation e.g. '.3.2.' is the value for office_id 2 which has a parent office_id of 3 and the parent of 3 is the default top office with a hierarchy of '.' - if you order office records by hierarchy field they are returned in the tree structure of the hierarchy. |
m_office_transaction | Allow recording of office transactions into and out of an m_office. It can be used to set opening balances e.g. someone funded the Head Office with $25,000 US. It can be used to show the Head Office giving and receiving funds from branches. It can be used to declare incidental costs within a branch e.g. $100 US for furniture.
Note: This table is used for Heaven Family MFI, and in general need not be applicable to others. |
, m_staff | All the MFI's staff. Some (or all) of these will have logins for Mifos X (m_app_user). Currently, very lonely as development recently started. |
m_group | Groups, Centers |
m_group_client | All formation of a group by adding clients. A Client can be in more than one group at one time. (development recently started) |
m_client | Clients |
m_charge | Fees, Penalties and Charges - still under development - may need to have separate tables for fees, penalties and charges - may not. Currently scope to all flat and % fees for loans. |
m_product_loan | Defines a loan product. |
m_product_loan_charge | Defines the list of m_charges associated with loan product. |
m_fund | Identifies a fund. And so can be used for seeing how funds have been 'disbursed'. Can be associated with loan products and loans. |
m_loan | Loans |
m_loan_charge | List of charges associated with a loan. |
m_loan_transaction | Loan Disbursals, Repayments, Waivers and Adjustments. |
m_loan_repayment_schedule | Loan schedules (installments for loans). |
m_product_savings | Defines a savings product (very lonely at the moment, doesn't even have its m_savings table set up - still under development) |
m_product_deposit | Defines a deposit account. The current scope is Fixed Term Deposit Accounts and Certificate of Deposit Accounts. |
m_deposit_account | Deposit account - relates to m_product_deposit |
m_deposit_account_transaction | Deposit account transactions - deposits, withdrawals and interest postings |
m_client_identifier | Identifiers associated with a customer |
m_document | Metadata of documents associated with various entities (clients, loans, client Identifiers, staff) |
Application Users, Roles & Permissions Tables | |
m_appuser | Mifos X application users (logins) |
m_role | Application roles |
m_appuser_role | Roles associated with an application user |
m_permission | Application permissions |
m_role_permission | Permissions associated with a role. |
Codes, Enums, Notes & Currency Tables | |
m_code | User definable codes. Right now there are no user defined codes in the mifos X database. But there will be e.g. gender, title. Some 'user-defined' code values may be shipped with the database but these values can be changed and added to. |
m_code_value | User defined values for m_code. The code field will typically save the m_code_value.id. Example SQL select cv.code_value as Occupation from m_client c left join m_code_value cv on cv.id = c.occupation_id |
r_enum_value | Database version of Java enums. Not linked to Java code. For reporting only. e.g. If I want to report on loan statuses, I see what enums are used and put values on this table. Example SQL select l.id, st.enum_message_property as Status from m_loan l left join r_enum_value st on st.enum_name = "loan_status_id" and st.enum_id = l.id |
m_currency | List of currencies and currency data. |
m_organisation_currency | List of currencies that can be used within the MFI (organisation). Probably will be put in the "On the way out Tables" list at some point as the same functionality can be achieved by adding a "can_use" flag onto m_currency. |
m_note | General note table. Other tables such as m_client, m_loan, m_loan_transactions can have notes associated with them. |
ref_loan_transaction_processing_strategy | The 'strategy' to be applied when receiving loan repayments e.g. What order to pay fees, penalties, interest and principal. |
Reporting MetaData Tables | Functionality related to these tables runs Pentaho reports and returns Pentaho output (html, pdf, excel, csv formats). Also runs "screen-based" reports/charts where the Java API returns a generic resultset output which is processed by a reporting JQuery plugin based on JQuery Data Tables |
stretchy_report | Data for Pentaho reports, screen-based reports and charts (includes SQL if not Pentaho) |
stretchy_parameter | Parameter definition data (may include SQL) |
stretchy_report_parameter | Parameters for Reports |
rpt_sequence | Utility table (just has an id value) used to create certain reports... not important. Might be put in the "On the Way Out" list at some point. |
Registered External Data Tables | |
x_registered_table | Contains a list of registered external tables (currently MySql in same database as Mifos X schema) and the Mifos X core table to which they are associated. Allows the external table's data to be restricted to the user hierarchy and CRUD permissions to be managed. |