rushfee/resource/db/rushfee_sql.xml

34 lines
1.2 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sqls SYSTEM "sql_definition.dtd">
<sqls>
<sql group="rushfee_list">
<i id="getList"><![CDATA[
select t.customerid customerid,
t.cust_name cust_name,
t.cust_tax_code cust_tax_code,
t.org_name org_name,
t.invoice_tel invoice_tel,
to_char(t.end_date,'yyyy-MM-dd') end_date
from VIEW_RUSHFEE_LIST t
where t.end_date is not null
and t.end_date>=RUSH_GET_WhatYouWantDay(0,{expstate} ) and t.end_date<=RUSH_GET_WhatYouWantDay(1,{expstate} )
and $equal(t.org_id,company)
and t.customerid not in
(
select l.customer_id
from RUSH_RECORD l
where l.customer_id = t.customerid
and t.end_date <= add_months(trunc(sysdate, 'yyyy'), 12) - 1
)
and $equal(t.revenueid,revenue)
and $equal(t.end_datechr,service_end_date)
order by t.end_date
]]></i>
<i id="grouplist"><![CDATA[
select t.id ,t.memo text from RUSH_DICTIONARY t where t.codetype='willend' or t.codetype='alreadyend'
]]></i>
</sql>
</sqls>