TYPE=VIEW
query=select `a`.`lf_no` AS `lf_no`,`a`.`Acc_no` AS `acc_no`,`a`.`Date_open` AS `date_open`,`a`.`Maturity_Date` AS `Maturity_Date`,`a`.`Maturity_Amount` AS `Maturity_Amount`,`a`.`Name` AS `name`,`ab`.`bal` AS `Principle_Amount`,`a`.`interest` AS `interest` from `co-operativebank-mohati`.`account` `a` join `co-operativebank-mohati`.`account_balance` `ab` where ((`a`.`Acc_no` = `ab`.`acc_no`) and (`a`.`Date_open` <= \'2025-03-31\') and (`a`.`Acc_Type` = \'reinv\') and (`ab`.`bal` <> 0)) union all select `a`.`lf_no` AS `lf_no`,`a`.`Acc_no` AS `acc_no`,max(`r`.`open_date`) AS `date_open`,max(`a`.`Maturity_Date`) AS `max(a.Maturity_Date)`,`a`.`Maturity_Amount` AS `Maturity_Amount`,`a`.`Name` AS `name`,`ab`.`bal` AS `Principle_Amount`,`a`.`interest` AS `interest` from `co-operativebank-mohati`.`account` `a` join `co-operativebank-mohati`.`account_balance` `ab` join `co-operativebank-mohati`.`fd_m_int_pay` `r` where ((`r`.`acc_no` = `a`.`Acc_no`) and (`r`.`acc_no` = `ab`.`acc_no`) and (`a`.`Acc_no` = `ab`.`acc_no`) and (`a`.`Date_open` >= \'2025-03-31\') and (`r`.`open_date` <= \'2025-03-31\') and (`a`.`Acc_Type` = \'reinv\')) group by `a`.`Acc_no`
md5=034cb7cfbb3fa03efd79e0b2e23e9156
updatable=0
algorithm=0
definer_user=admin
definer_host=localhost
suid=2
with_check_option=0
timestamp=2025-06-20 12:09:52
create-version=1
source=select a.lf_no,a.acc_no,a.date_open,a.Maturity_Date,a.Maturity_Amount,a.name,ab.bal Principle_Amount,a.interest from account a,account_balance ab where a.acc_no=ab.acc_no and a.date_open<=\'2025-03-31\' and a.acc_type=\'reinv\' and ab.bal<>0   union all SELECT  a.lf_no,a.acc_no, max(r.open_date) as date_open, max(a.Maturity_Date),a.Maturity_Amount, a.name, ab.bal Principle_Amount, a.interest FROM account a, account_balance ab,fd_m_int_pay r WHERE (r.acc_no = a.acc_no) And (r.acc_no = ab.acc_no)  And a.acc_no = ab.acc_no AND (a.date_open >=  \'2025-03-31\' and r.open_date<=\'2025-03-31\') AND a.acc_type =\'reinv\'  group by acc_no
client_cs_name=utf8
connection_cl_name=utf8_general_ci
view_body_utf8=select `a`.`lf_no` AS `lf_no`,`a`.`Acc_no` AS `acc_no`,`a`.`Date_open` AS `date_open`,`a`.`Maturity_Date` AS `Maturity_Date`,`a`.`Maturity_Amount` AS `Maturity_Amount`,`a`.`Name` AS `name`,`ab`.`bal` AS `Principle_Amount`,`a`.`interest` AS `interest` from `co-operativebank-mohati`.`account` `a` join `co-operativebank-mohati`.`account_balance` `ab` where ((`a`.`Acc_no` = `ab`.`acc_no`) and (`a`.`Date_open` <= \'2025-03-31\') and (`a`.`Acc_Type` = \'reinv\') and (`ab`.`bal` <> 0)) union all select `a`.`lf_no` AS `lf_no`,`a`.`Acc_no` AS `acc_no`,max(`r`.`open_date`) AS `date_open`,max(`a`.`Maturity_Date`) AS `max(a.Maturity_Date)`,`a`.`Maturity_Amount` AS `Maturity_Amount`,`a`.`Name` AS `name`,`ab`.`bal` AS `Principle_Amount`,`a`.`interest` AS `interest` from `co-operativebank-mohati`.`account` `a` join `co-operativebank-mohati`.`account_balance` `ab` join `co-operativebank-mohati`.`fd_m_int_pay` `r` where ((`r`.`acc_no` = `a`.`Acc_no`) and (`r`.`acc_no` = `ab`.`acc_no`) and (`a`.`Acc_no` = `ab`.`acc_no`) and (`a`.`Date_open` >= \'2025-03-31\') and (`r`.`open_date` <= \'2025-03-31\') and (`a`.`Acc_Type` = \'reinv\')) group by `a`.`Acc_no`
