   CONSTRAINT `FKGroupRoleGroupId` FOREIGN KEY (`group_id`) REFERENCES `m_group` (`id`),
   CONSTRAINT `FK_grouprole_m_codevalue` FOREIGN KEY (`role_cv_id`) REFERENCES `m_code_value` (`id`)
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-/*!40101 SET character_set_client = @saved_cs_client */;
-
---
--- Dumping data for table `m_group_roles`
---
-
-LOCK TABLES `m_group_roles` WRITE;
+
+-- Dumping data for table mifostenant-default.m_group_roles: ~0 rows (approximately)
 /*!40000 ALTER TABLE `m_group_roles` DISABLE KEYS */;
 /*!40000 ALTER TABLE `m_group_roles` ENABLE KEYS */;
-UNLOCK TABLES;
-
---
--- Table structure for table `m_guarantor`
---
-
+
+
+-- Dumping structure for table mifostenant-default.m_guarantor
 DROP TABLE IF EXISTS `m_guarantor`;
-/*!40101 SET @saved_cs_client     = @@character_set_client */;
-/*!40101 SET character_set_client = utf8 */;
-CREATE TABLE `m_guarantor` (
+CREATE TABLE IF NOT EXISTS `m_guarantor` (
   `id` bigint(20) NOT NULL AUTO_INCREMENT,
   `loan_id` bigint(20) NOT NULL,
   `client_reln_cv_id` int(11) DEFAULT NULL,

  CONSTRAINT `FK_acc_accounting_rule_id` FOREIGN KEY (`acc_rule_id`) REFERENCES `acc_accounting_rule` (`id`),
  CONSTRAINT `FK_m_code_value_id` FOREIGN KEY (`tag_id`) REFERENCES `m_code_value` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `acc_rule_tags`
--

LOCK TABLES `acc_rule_tags` WRITE;
/*!40000 ALTER TABLE `acc_rule_tags` DISABLE KEYS */;
/*!40000 ALTER TABLE `acc_rule_tags` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `c_cache`
--

DROP TABLE IF EXISTS `c_cache`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `c_cache` (
  `id` bigint(20) NOT NULL AUTO_INCREMENT,
  `cache_type_enum` tinyint(1) NOT NULL DEFAULT '1',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `c_cache`
--

LOCK TABLES `c_cache` WRITE;
/*!40000 ALTER TABLE `c_cache` DISABLE KEYS */;
INSERT INTO `c_cache` VALUES (1,1);
/*!40000 ALTER TABLE `c_cache` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `c_configuration`
--

DROP TABLE IF EXISTS `c_configuration`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `c_configuration` (
  `id` bigint(20) NOT NULL AUTO_INCREMENT,
  `name` varchar(50) DEFAULT NULL,
  `value` int(11) DEFAULT NULL,
  `enabled` tinyint(1) NOT NULL DEFAULT '0',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `c_configuration`
--

LOCK TABLES `c_configuration` WRITE;
/*!40000 ALTER TABLE `c_configuration` DISABLE KEYS */;
INSERT INTO `c_configuration` VALUES (1,'maker-checker',NULL,0),(4,'amazon-S3',NULL,0),(5,'reschedule-future-repayments',NULL,1),(6,'reschedule-repayments-on-holidays',NULL,0),(7,'allow-transactions-on-holiday',NULL,0),(8,'allow-transactions-on-non_workingday',NULL,0),(9,'constraint_approach_for_datatables',NULL,0),(10,'penalty-wait-period',2,1),(11,'force-password-reset-days',0,0),(12,'grace-on-penalty-posting',0,1);
/*!40000 ALTER TABLE `c_configuration` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `c_external_service`
--

DROP TABLE IF EXISTS `c_external_service`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `c_external_service` (
  `name` varchar(150) NOT NULL,
  `value` varchar(250) DEFAULT NULL,
  UNIQUE KEY `name` (`name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `c_external_service`
--

LOCK TABLES `c_external_service` WRITE;
/*!40000 ALTER TABLE `c_external_service` DISABLE KEYS */;
INSERT INTO `c_external_service` VALUES ('s3_access_key',NULL),('s3_bucket_name',NULL),('s3_secret_key',NULL);
/*!40000 ALTER TABLE `c_external_service` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `job`
--

DROP TABLE IF EXISTS `job`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `job` (
  `id` bigint(20) NOT NULL AUTO_INCREMENT,
  `name` varchar(50) NOT NULL,
  `display_name` varchar(50) NOT NULL,

  CONSTRAINT `fk_report_parameter_001` FOREIGN KEY (`report_id`) REFERENCES `stretchy_report` (`id`) ON DELETE CASCADE,
  CONSTRAINT `fk_report_parameter_002` FOREIGN KEY (`parameter_id`) REFERENCES `stretchy_parameter` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=426 DEFAULT CHARSET=utf8;

-- Dumping data for table mifostenant-default.stretchy_report_parameter: ~319 rows (approximately)
/*!40000 ALTER TABLE `stretchy_report_parameter` DISABLE KEYS */;
INSERT INTO `stretchy_report_parameter` (`id`, `report_id`, `parameter_id`, `report_parameter_name`) VALUES
	(1, 1, 5, NULL),
	(2, 2, 5, NULL),
	(3, 2, 6, NULL),
	(4, 2, 10, NULL),
	(5, 2, 20, NULL),
	(6, 2, 25, NULL),
	(7, 2, 26, NULL),
	(8, 5, 5, NULL),
	(9, 5, 6, NULL),
	(10, 5, 10, NULL),
	(11, 5, 20, NULL),
	(12, 5, 25, NULL),
	(13, 5, 26, NULL),
	(14, 6, 5, NULL),
	(15, 6, 6, NULL),
	(16, 6, 10, NULL),
	(17, 6, 20, NULL),
	(18, 6, 25, NULL),
	(19, 6, 26, NULL),
	(20, 7, 5, NULL),
	(21, 7, 6, NULL),
	(22, 7, 10, NULL),
	(23, 7, 20, NULL),
	(24, 7, 25, NULL),
	(25, 7, 26, NULL),
	(26, 8, 5, NULL),
	(27, 8, 6, NULL),
	(28, 8, 10, NULL),
	(29, 8, 25, NULL),
	(30, 8, 26, NULL),
	(31, 11, 5, NULL),
	(32, 11, 6, NULL),
	(33, 11, 10, NULL),
	(34, 11, 20, NULL),
	(35, 11, 25, NULL),
	(36, 11, 26, NULL),
	(37, 11, 100, NULL),
	(38, 12, 5, NULL),
	(39, 12, 6, NULL),
	(40, 12, 10, NULL),
	(41, 12, 20, NULL),
	(42, 12, 25, NULL),
	(43, 12, 26, NULL),
	(44, 13, 1, NULL),
	(45, 13, 2, NULL),
	(46, 13, 3, NULL),
	(47, 13, 5, NULL),
	(48, 13, 6, NULL),
	(49, 13, 10, NULL),
	(50, 13, 20, NULL),
	(51, 13, 25, NULL),
	(52, 13, 26, NULL),
	(53, 14, 1, NULL),
	(54, 14, 2, NULL),
	(55, 14, 3, NULL),
	(56, 14, 5, NULL),
	(57, 14, 6, NULL),
	(58, 14, 10, NULL),
	(59, 14, 20, NULL),
	(60, 14, 25, NULL),
	(61, 14, 26, NULL),
	(62, 15, 5, NULL),
	(63, 15, 6, NULL),
	(64, 15, 10, NULL),
	(65, 15, 20, NULL),
	(66, 15, 25, NULL),
	(67, 15, 26, NULL),
	(68, 15, 100, NULL),
	(69, 16, 5, NULL),
	(70, 16, 6, NULL),
	(71, 16, 10, NULL),
	(72, 16, 20, NULL),
	(73, 16, 25, NULL),
	(74, 16, 26, NULL),
	(75, 16, 100, NULL),
	(76, 20, 1, NULL),
	(77, 20, 2, NULL),
	(78, 20, 10, NULL),
	(79, 20, 20, NULL),
	(80, 21, 1, NULL),
	(81, 21, 2, NULL),
	(82, 21, 5, NULL),
	(83, 21, 10, NULL),
	(84, 21, 20, NULL),
	(85, 48, 5, 'branch'),
	(86, 48, 2, 'date'),
	(87, 49, 5, 'branch'),
	(88, 49, 1, 'fromDate'),
	(89, 49, 2, 'toDate'),
	(90, 50, 5, 'branch'),
	(91, 50, 1, 'fromDate'),
	(92, 50, 2, 'toDate'),
	(93, 51, 1, NULL),
	(94, 51, 2, NULL),
	(95, 51, 5, NULL),
	(96, 51, 10, NULL),
	(97, 51, 25, NULL),
	(98, 52, 5, NULL),
	(99, 53, 5, NULL),
	(100, 53, 10, NULL),
	(101, 54, 1, NULL),
	(102, 54, 2, NULL),
	(103, 54, 5, NULL),
	(104, 54, 10, NULL),
	(105, 54, 25, NULL),
	(106, 55, 5, NULL),
	(107, 55, 6, NULL),
	(108, 55, 10, NULL),
	(109, 55, 20, NULL),
	(110, 55, 25, NULL),
	(111, 55, 26, NULL),
	(112, 56, 5, NULL),
	(113, 56, 6, NULL),
	(114, 56, 10, NULL),
	(115, 56, 20, NULL),
	(116, 56, 25, NULL),
	(117, 56, 26, NULL),
	(118, 56, 100, NULL),
	(119, 57, 5, NULL),
	(120, 57, 6, NULL),
	(121, 57, 10, NULL),
	(122, 57, 20, NULL),
	(123, 57, 25, NULL),
	(124, 57, 26, NULL),
	(125, 58, 5, NULL),
	(126, 58, 6, NULL),
	(127, 58, 10, NULL),
	(128, 58, 20, NULL),
	(129, 58, 25, NULL),
	(130, 58, 26, NULL),
	(131, 58, 100, NULL),
	(132, 59, 1, NULL),
	(133, 59, 2, NULL),
	(134, 59, 5, NULL),
	(135, 59, 6, NULL),
	(136, 59, 10, NULL),
	(137, 59, 20, NULL),
	(138, 59, 25, NULL),
	(139, 59, 26, NULL),
	(140, 61, 5, NULL),
	(141, 61, 10, NULL),
	(142, 92, 1, 'fromDate'),
	(143, 92, 5, 'selectOffice'),
	(144, 92, 2, 'toDate'),
	(145, 93, 1, NULL),
	(146, 93, 2, NULL),
	(147, 93, 5, NULL),
	(148, 93, 6, NULL),
	(149, 94, 2, 'endDate'),
	(150, 94, 6, 'loanOfficerId'),
	(151, 94, 5, 'officeId'),
	(152, 94, 1, 'startDate'),
	(256, 106, 2, NULL),
	(257, 106, 6, NULL),
	(258, 106, 5, NULL),
	(259, 106, 1, NULL),
	(263, 118, 1, 'fromDate'),
	(264, 118, 2, 'toDate'),
	(265, 118, 1004, 'accountNo'),
	(266, 119, 1, 'fromDate'),
	(267, 119, 2, 'toDate'),
	(268, 119, 5, 'selectOffice'),
	(269, 119, 1005, 'selectProduct'),
	(270, 120, 5, 'branch'),
	(271, 120, 6, 'loanOfficer'),
	(272, 120, 10, 'currencyId'),
	(273, 120, 20, 'fundId'),
	(274, 120, 25, 'loanProductId'),
	(275, 120, 26, 'loanPurposeId'),
	(276, 121, 5, 'Branch'),
	(277, 121, 6, 'loanOfficer'),
	(278, 121, 10, 'CurrencyId'),
	(279, 121, 20, 'fundId'),
	(280, 121, 25, 'loanProductId'),
	(281, 121, 26, 'loanPurposeId'),
	(282, 121, 100, 'parType'),
	(283, 122, 5, 'Branch'),
	(284, 122, 6, 'loanOfficer'),
	(285, 122, 10, 'CurrencyId'),
	(286, 122, 20, 'fundId'),
	(287, 122, 25, 'loanProductId'),
	(288, 122, 26, 'loanPurposeId'),
	(289, 122, 1, 'startDate'),
	(290, 122, 2, 'endDate'),
	(291, 123, 5, 'Branch'),
	(292, 123, 6, 'Loan Officer'),
	(293, 123, 10, 'CurrencyId'),
	(294, 123, 20, 'fundId'),
	(295, 123, 25, 'loanProductId'),
	(296, 123, 26, 'loanPurposeId'),
	(297, 123, 100, 'parType'),
	(298, 124, 5, 'Branch'),
	(299, 124, 6, 'Loan Officer'),
	(300, 124, 10, 'CurrencyId'),
	(301, 124, 20, 'fundId'),
	(302, 124, 25, 'loanProductId'),
	(303, 124, 26, 'loanPurposeId'),
	(304, 125, 5, 'Branch'),
	(305, 125, 6, 'Loan Officer'),
	(306, 125, 10, 'CurrencyId'),
	(307, 125, 20, 'fundId'),
	(308, 125, 25, 'loanProductId'),
	(309, 125, 26, 'loanPurposeId'),
	(310, 125, 100, 'parType'),
	(311, 126, 5, 'Branch'),
	(312, 126, 6, 'Loan Officer'),
	(313, 126, 10, 'CurrencyId'),
	(314, 126, 20, 'fundId'),
	(315, 126, 25, 'loanProductId'),
	(316, 126, 26, 'loanPurposeId'),
	(317, 127, 5, 'Branch'),
	(318, 128, 5, 'Branch'),
	(319, 128, 10, 'CurrencyId'),
	(320, 129, 5, 'Branch'),
	(321, 129, 10, 'CurrencyId'),
	(322, 130, 5, 'selectOffice'),
	(323, 131, 5, 'Branch'),
	(324, 131, 6, 'Loan Officer'),
	(325, 131, 10, 'CurrencyId'),
	(326, 131, 20, 'fundId'),
	(327, 131, 25, 'loanProductId'),
	(328, 131, 26, 'loanPurposeId'),
	(329, 132, 5, 'Branch'),
	(330, 132, 6, 'Loan Officer'),
	(331, 132, 1, 'startDate'),
	(332, 132, 2, 'endDate'),
	(333, 133, 5, 'Branch'),
	(334, 133, 10, 'CurrencyId'),
	(335, 133, 20, 'fundId'),
	(336, 133, 1, 'startDate'),
	(337, 133, 2, 'endDate'),
	(338, 134, 10, 'CurrencyId'),
	(339, 134, 20, 'fundId'),
	(340, 134, 1, 'startDate'),
	(341, 134, 2, 'endDate'),
	(342, 135, 5, 'Branch'),
	(343, 135, 6, 'Loan Officer'),
	(344, 135, 10, 'CurrencyId'),
	(345, 135, 20, 'fundId'),
	(346, 135, 25, 'loanProductId'),
	(347, 135, 26, 'loanPurposeId'),
	(348, 136, 5, 'Branch'),
	(349, 136, 6, 'Loan Officer'),
	(350, 136, 10, 'CurrencyId'),
	(351, 136, 20, 'fundId'),
	(352, 136, 25, 'loanProductId'),
	(353, 136, 26, 'loanPurposeId'),
	(354, 137, 5, 'Branch'),
	(355, 137, 6, 'Loan Officer'),
	(356, 137, 10, 'CurrencyId'),
	(357, 137, 20, 'fundId'),
	(358, 137, 25, 'loanProductId'),
	(359, 137, 26, 'loanPurposeId'),
	(360, 138, 5, 'Branch'),
	(361, 138, 6, 'Loan Officer'),
	(362, 138, 10, 'CurrencyId'),
	(363, 138, 20, 'fundId'),
	(364, 138, 25, 'loanProductId'),
	(365, 138, 26, 'loanPurposeId'),
	(366, 139, 5, 'Branch'),
	(367, 139, 6, 'Loan Officer'),
	(368, 139, 10, 'CurrencyId'),
	(369, 139, 20, 'fundId'),
	(370, 139, 25, 'loanProductId'),
	(371, 139, 26, 'loanPurposeId'),
	(372, 139, 1, 'startDate'),
	(373, 139, 2, 'endDate'),
	(374, 139, 3, 'obligDateType'),
	(375, 140, 5, 'Branch'),
	(376, 140, 6, 'Loan Officer'),
	(377, 140, 10, 'CurrencyId'),
	(378, 140, 20, 'fundId'),
	(379, 140, 25, 'loanProductId'),
	(380, 140, 26, 'loanPurposeId'),
	(381, 140, 1, 'Startdate'),
	(382, 140, 2, 'Enddate'),
	(383, 140, 3, 'obligDateType'),
	(384, 141, 5, 'Branch'),
	(385, 141, 6, 'Loan Officer'),
	(386, 141, 10, 'CurrencyId'),
	(387, 141, 20, 'fundId'),
	(388, 141, 25, 'loanProductId'),
	(389, 141, 26, 'loanPurposeId'),
	(390, 141, 100, 'parType'),
	(391, 142, 5, 'Branch'),
	(392, 142, 6, 'loanOfficer'),
	(393, 142, 10, 'CurrencyId'),
	(394, 142, 20, 'fundId'),
	(395, 142, 25, 'loanProductId'),
	(396, 142, 26, 'loanPurposeId'),
	(397, 142, 100, 'parType'),
	(398, 143, 5, 'Branch'),
	(399, 143, 10, 'CurrencyId'),
	(400, 143, 25, 'loanProductId'),
	(401, 143, 1, 'startDate'),
	(402, 143, 2, 'endDate'),
	(403, 144, 5, 'Branch'),
	(404, 144, 6, 'Loan Officer'),
	(405, 144, 1, 'startDate'),
	(406, 144, 2, 'endDate'),
	(407, 145, 5, 'Branch'),
	(408, 145, 10, 'CurrencyId'),
	(409, 145, 25, 'loanProductId'),
	(410, 145, 1, 'startDate'),
	(411, 145, 2, 'endDate'),
	(412, 146, 1, 'startDate'),
	(413, 146, 2, 'endDate'),
	(414, 146, 1004, 'accountNo'),
	(415, 147, 1, 'startDate'),
	(416, 147, 2, 'endDate'),
	(417, 147, 1004, 'accountNo'),
	(418, 149, 5, ''),
	(419, 150, 5, ''),
	(420, 151, 5, ''),
	(421, 152, 5, ''),
	(422, 153, 5, ''),
	(423, 154, 5, ''),
	(424, 155, 5, ''),
	(425, 156, 5, '');
/*!40000 ALTER TABLE `stretchy_report_parameter` ENABLE KEYS */;


-- Dumping structure for table mifostenant-default.x_registered_table
DROP TABLE IF EXISTS `x_registered_table`;
CREATE TABLE IF NOT EXISTS `x_registered_table` (
  `registered_table_name` varchar(50) NOT NULL,
  `application_table_name` varchar(50) NOT NULL,
  PRIMARY KEY (`registered_table_name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Dumping data for table mifostenant-default.x_registered_table: ~0 rows (approximately)
/*!40000 ALTER TABLE `x_registered_table` DISABLE KEYS */;
/*!40000 ALTER TABLE `x_registered_table` ENABLE KEYS */;


-- Dumping structure for table mifostenant-default.x_table_column_code_mappings
DROP TABLE IF EXISTS `x_table_column_code_mappings`;
CREATE TABLE IF NOT EXISTS `x_table_column_code_mappings` (
  `column_alias_name` varchar(50) NOT NULL,
  `code_id` int(10) NOT NULL,
  PRIMARY KEY (`column_alias_name`),
  KEY `FK_x_code_id` (`code_id`),
  CONSTRAINT `FK_x_code_id` FOREIGN KEY (`code_id`) REFERENCES `m_code` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Dumping data for table mifostenant-default.x_table_column_code_mappings: ~0 rows (approximately)
/*!40000 ALTER TABLE `x_table_column_code_mappings` DISABLE KEYS */;
/*!40000 ALTER TABLE `x_table_column_code_mappings` ENABLE KEYS */;
/*!40101 SET SQL_MODE=IFNULL(@OLD_SQL_MODE, '') */;
/*!40014 SET FOREIGN_KEY_CHECKS=IF(@OLD_FOREIGN_KEY_CHECKS IS NULL, 1, @OLD_FOREIGN_KEY_CHECKS) */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
