<?xml version="1.0" encoding="UTF-8"?>
<bm:model xmlns:bm="http://www.leaf-framework.org/schema/bm">
    <bm:operations>
        <bm:operation name="query">
            <bm:query-sql><![CDATA[
                SELECT
                    *
                FROM
                    (SELECT
                        t.contract_id,
                        TO_CHAR((SUM(t.VALUE)/10000), 'FM999,999,999,999.00') sum_value
                    FROM
                        con_contract_mortgage_item_lv t
                    GROUP BY
                        t.contract_id
                    ) t1 #WHERE_CLAUSE#
            ]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
</bm:model>
