TYPE=VIEW
query=select `v1`.`no` AS `no`,if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`) AS `acc_no`,`an`.`name` AS `name`,`an`.`lfno` AS `lfno`,sum(`v1`.`cr`) AS `CASH`,\'0\' AS `TRAN`,`v1`.`date` AS `date`,`v1`.`sub_head` AS `sub_head` from `co-operativebank-neturia`.`voucher` `v1` USE INDEX (`by_sub_head`) USE INDEX (`by_date`) USE INDEX (`by_cash_acc`) USE INDEX (`by_acc_no`) join `co-operativebank-neturia`.`quick_name` `an` USE INDEX (`by_acc_no`) where (((`v1`.`Acc_no` = `an`.`acc_no`) or (`v1`.`cash_acc` = `an`.`acc_no`)) and (`v1`.`sub_head` > 57000) and (`v1`.`sub_head` <= 57999) and (`v1`.`sub_head` = \'57906\') and (`v1`.`date` = \'2025-10-08\') and (`v1`.`deposit_type` = \'CASH\') and (`v1`.`cr` <> \'0\')) group by if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`) union all select `v1`.`no` AS `no`,if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`) AS `acc_no`,`an`.`name` AS `name`,`an`.`lfno` AS `lfno`,\'0\' AS `CASH`,sum(`v1`.`cr`) AS `TRAN`,`v1`.`date` AS `date`,`v1`.`sub_head` AS `sub_head` from `co-operativebank-neturia`.`voucher` `v1` USE INDEX (`by_sub_head`) USE INDEX (`by_date`) USE INDEX (`by_cash_acc`) USE INDEX (`by_acc_no`) join `co-operativebank-neturia`.`quick_name` `an` USE INDEX (`by_acc_no`) where (((`v1`.`Acc_no` = `an`.`acc_no`) or (`v1`.`cash_acc` = `an`.`acc_no`)) and (`v1`.`sub_head` > 57000) and (`v1`.`sub_head` <= 57999) and (`v1`.`sub_head` = \'57906\') and (`v1`.`date` = \'2025-10-08\') and (`v1`.`deposit_type` = \'TRANSFER\') and (`v1`.`cr` <> \'0\')) group by if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`)
md5=bf19bc234f5f3dfe543e8ef9dbb40427
updatable=0
algorithm=0
definer_user=admin
definer_host=%
suid=2
with_check_option=0
timestamp=2025-10-09 07:33:55
create-version=1
source=select v1.no,if(v1.acc_no=\'\',v1.cash_acc,v1.acc_no) as acc_no,name as name,lfno,sum(cr) as CASH,\'0\' as TRAN,date,v1.sub_head from voucher v1 USE INDEX (by_acc_no,by_cash_acc,by_date,by_sub_head),quick_name an USE INDEX (by_acc_no) where (v1.acc_no=an.acc_no or v1.cash_acc=an.acc_no) and v1.sub_head>57000 and v1.sub_head<=57999 and v1.sub_head=\'57906\' and v1.date=\'2025-10-08\' AND DEPOSIT_TYPE=\'CASH\' AND cR<>\'0\'  group by if(v1.acc_no=\'\',v1.cash_acc,v1.acc_no) union all select v1.no,if(v1.acc_no=\'\',v1.cash_acc,v1.acc_no) as acc_no,name as name,lfno,\'0\' as CASH,sum(cr) as TRAN,date,v1.sub_head from voucher v1 USE INDEX (by_acc_no,by_cash_acc,by_date,by_sub_head),quick_name an USE INDEX (by_acc_no) where (v1.acc_no=an.acc_no or v1.cash_acc=an.acc_no) and v1.sub_head>57000 and v1.sub_head<=57999 and v1.sub_head=\'57906\' and v1.date=\'2025-10-08\' AND DEPOSIT_TYPE=\'TRANSFER\' AND cR<>\'0\'  group by if(v1.acc_no=\'\',v1.cash_acc,v1.acc_no)
client_cs_name=utf8
connection_cl_name=utf8_general_ci
view_body_utf8=select `v1`.`no` AS `no`,if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`) AS `acc_no`,`an`.`name` AS `name`,`an`.`lfno` AS `lfno`,sum(`v1`.`cr`) AS `CASH`,\'0\' AS `TRAN`,`v1`.`date` AS `date`,`v1`.`sub_head` AS `sub_head` from `co-operativebank-neturia`.`voucher` `v1` USE INDEX (`by_sub_head`) USE INDEX (`by_date`) USE INDEX (`by_cash_acc`) USE INDEX (`by_acc_no`) join `co-operativebank-neturia`.`quick_name` `an` USE INDEX (`by_acc_no`) where (((`v1`.`Acc_no` = `an`.`acc_no`) or (`v1`.`cash_acc` = `an`.`acc_no`)) and (`v1`.`sub_head` > 57000) and (`v1`.`sub_head` <= 57999) and (`v1`.`sub_head` = \'57906\') and (`v1`.`date` = \'2025-10-08\') and (`v1`.`deposit_type` = \'CASH\') and (`v1`.`cr` <> \'0\')) group by if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`) union all select `v1`.`no` AS `no`,if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`) AS `acc_no`,`an`.`name` AS `name`,`an`.`lfno` AS `lfno`,\'0\' AS `CASH`,sum(`v1`.`cr`) AS `TRAN`,`v1`.`date` AS `date`,`v1`.`sub_head` AS `sub_head` from `co-operativebank-neturia`.`voucher` `v1` USE INDEX (`by_sub_head`) USE INDEX (`by_date`) USE INDEX (`by_cash_acc`) USE INDEX (`by_acc_no`) join `co-operativebank-neturia`.`quick_name` `an` USE INDEX (`by_acc_no`) where (((`v1`.`Acc_no` = `an`.`acc_no`) or (`v1`.`cash_acc` = `an`.`acc_no`)) and (`v1`.`sub_head` > 57000) and (`v1`.`sub_head` <= 57999) and (`v1`.`sub_head` = \'57906\') and (`v1`.`date` = \'2025-10-08\') and (`v1`.`deposit_type` = \'TRANSFER\') and (`v1`.`cr` <> \'0\')) group by if((`v1`.`Acc_no` = \'\'),`v1`.`cash_acc`,`v1`.`Acc_no`)
