TYPE=VIEW
query=select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),concat(\'BY \',`co-operativebank-201`.`headvoucher`.`sub_head`,\' A/C\',\' -\',`co-operativebank-201`.`headvoucher`.`acc_no`),concat(\'BY \',`co-operativebank-201`.`headvoucher`.`sub_head`,\' A/C\')) AS `sub_head`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `dr`,0 AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and (`co-operativebank-201`.`headvoucher`.`shcode` = \'18949\')) union all select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,concat(\'BY INTEREST\',\' A/C\') AS `sub_head`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `dr`,0 AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and (`co-operativebank-201`.`headvoucher`.`shcode` = (\'18949\' + 48000))) union all select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,\'TO CASH A/C\' AS `sub_head`,0 AS `dr`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`deposit_type` = \'CASH\') and (`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and ((`co-operativebank-201`.`headvoucher`.`shcode` = \'18949\') or (`co-operativebank-201`.`headvoucher`.`shcode` = (\'18949\' + 48000)))) union all select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,\'TO TRANSFER A/C\' AS `sub_head`,0 AS `dr`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`deposit_type` = \'TRANSFER\') and (`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and ((`co-operativebank-201`.`headvoucher`.`shcode` = \'18949\') or (`co-operativebank-201`.`headvoucher`.`shcode` = (\'18949\' + 48000))))
md5=88a7919ae4b0299216ee0997a2925223
updatable=0
algorithm=0
definer_user=admin
definer_host=localhost
suid=2
with_check_option=0
timestamp=2026-03-10 07:59:54
create-version=1
source=select sub_head as headname,shcode as code,if(htcode=\'28000\' or htcode=\'22000\',CONCAT(\'BY \',sub_head,\' A/C\',\' -\',acc_no),CONCAT(\'BY \',sub_head,\' A/C\')) AS sub_head,if(htcode=\'28000\' or htcode=\'22000\',sum(cr),sum(dr)) as dr,0 cr,0 as interest, hcode as head,htcode htcode,0 as m_count from headvoucher where   date=\'2026-03-07\'  AND SHCODE=\'18949\' union all select sub_head as headname,shcode as code,CONCAT(\'BY INTEREST\',\' A/C\') AS sub_head,if(htcode=\'28000\' or htcode=\'22000\',sum(cr),sum(dr)) as  dr,0 cr,0 as interest, hcode as head,htcode htcode,0 as m_count from headvoucher where   date=\'2026-03-07\'  AND SHCODE=\'18949\'+48000 union all select sub_head as headname,shcode as code,\'TO CASH A/C\' AS sub_head,0 dr,if(htcode=\'28000\' or htcode=\'22000\',sum(cr),sum(dr)) cr,0 as interest, hcode as head,htcode htcode,0 as m_count from headvoucher where  deposit_type=\'CASH\' and date=\'2026-03-07\'  AND (SHCODE=\'18949\' OR SHCODE=\'18949\'+48000) union all select sub_head as headname,shcode as code,\'TO TRANSFER A/C\' AS sub_head,0 dr,if(htcode=\'28000\' or htcode=\'22000\',sum(cr),sum(dr)) cr,0 as interest, hcode as head,htcode htcode,0 as m_count from headvoucher where  deposit_type=\'TRANSFER\' and date=\'2026-03-07\'  AND (SHCODE=\'18949\' OR SHCODE=\'18949\'+48000)
client_cs_name=utf8mb4
connection_cl_name=utf8mb4_general_ci
view_body_utf8=select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),concat(\'BY \',`co-operativebank-201`.`headvoucher`.`sub_head`,\' A/C\',\' -\',`co-operativebank-201`.`headvoucher`.`acc_no`),concat(\'BY \',`co-operativebank-201`.`headvoucher`.`sub_head`,\' A/C\')) AS `sub_head`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `dr`,0 AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and (`co-operativebank-201`.`headvoucher`.`shcode` = \'18949\')) union all select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,concat(\'BY INTEREST\',\' A/C\') AS `sub_head`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `dr`,0 AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and (`co-operativebank-201`.`headvoucher`.`shcode` = (\'18949\' + 48000))) union all select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,\'TO CASH A/C\' AS `sub_head`,0 AS `dr`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`deposit_type` = \'CASH\') and (`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and ((`co-operativebank-201`.`headvoucher`.`shcode` = \'18949\') or (`co-operativebank-201`.`headvoucher`.`shcode` = (\'18949\' + 48000)))) union all select `co-operativebank-201`.`headvoucher`.`sub_head` AS `headname`,`co-operativebank-201`.`headvoucher`.`shcode` AS `code`,\'TO TRANSFER A/C\' AS `sub_head`,0 AS `dr`,if(((`co-operativebank-201`.`headvoucher`.`htcode` = \'28000\') or (`co-operativebank-201`.`headvoucher`.`htcode` = \'22000\')),sum(`co-operativebank-201`.`headvoucher`.`cr`),sum(`co-operativebank-201`.`headvoucher`.`dr`)) AS `cr`,0 AS `interest`,`co-operativebank-201`.`headvoucher`.`hcode` AS `head`,`co-operativebank-201`.`headvoucher`.`htcode` AS `htcode`,0 AS `m_count` from `co-operativebank-201`.`headvoucher` where ((`co-operativebank-201`.`headvoucher`.`deposit_type` = \'TRANSFER\') and (`co-operativebank-201`.`headvoucher`.`date` = \'2026-03-07\') and ((`co-operativebank-201`.`headvoucher`.`shcode` = \'18949\') or (`co-operativebank-201`.`headvoucher`.`shcode` = (\'18949\' + 48000))))
