<?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 t.unit_id,
       t.unit_code,
       t.company_id,
       fd.description_text as unit_name
  from exp_org_unit t, fnd_descriptions fd
 where t.description_id = fd.description_id
  and fd.language=userenv('lang')
   and t.org_unit_type = 'SALES'
   and t.parent_unit_id is not null
   and t.enabled_flag = 'Y'
   and t.company_id = 2145;]]></bm:query-sql>
        </bm:operation>
    </bm:operations>
    <bm:fields>
        <bm:field name="unit_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="UNIT_ID"/>
        <bm:field name="unit_code" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="UNIT_CODE"/>
        <bm:field name="company_id" databaseType="NUMBER" datatype="java.lang.Long" physicalName="COMPANY_ID"/>
        <bm:field name="unit_name" databaseType="VARCHAR2" datatype="java.lang.String" physicalName="UNIT_NAME"/>
    </bm:fields>
</bm:model>
