Mercurial > HIS > BLT-XML
annotate ehis.数据统计.营业收入.运营情况汇总.XML @ 1:be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
author | Schmit <liny.jii@nnsui.com> |
---|---|
date | Sun, 08 Sep 2024 17:07:59 +0800 |
parents | |
children |
rev | line source |
---|---|
1
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
1 <?xml version="1.0" encoding="UTF-8"?> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
2 <report report-id="ehis.鏁版嵁缁熻.钀ヤ笟鏀跺叆.杩愯惀鎯呭喌姹囨" title="杩愯惀鎯呭喌姹囨" seq="0" is-detail="true"> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
3 <description>杩愯惀鎯呭喌姹囨</description> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
4 <attrs> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
5 <attr key="datasource" value="default"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
6 <attr key="leftFixedColCount" value="0"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
7 <attr key="rightFixedColCount" value="0"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
8 <attr key="showTotalRow" value="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
9 <attr key="showRowIndex" value="true"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
10 <attr key="showColIndex" value="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
11 <attr key="showColLine" value="true"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
12 <attr key="showRowLine" value="true"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
13 <attr key="showHeader" value="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
14 <attr key="showTools" value="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
15 <attr key="trackMouseOver" value="true"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
16 <attr key="defaultColWidth" value="100"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
17 <attr key="rowNoColWidth" value="40"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
18 <attr key="pageType" value="A4"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
19 <attr key="pageDirect" value="V"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
20 <attr key="pageFontSize" value="11"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
21 <attr key="pageSize" value="297,210"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
22 <attr key="pageMargin" value="10,10,10,10"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
23 <attr key="pageMaxRowCount" value="50"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
24 <attr key="autoSizeCol" value="0" /> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
25 </attrs> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
26 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
27 <params> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
28 <param id="jgxs"> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
29 <sql> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
30 <![CDATA[ |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
31 select count(1) col into #t from |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
32 ( |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
33 select 鏈烘瀯ID value,鍚嶇О text from bas_鏈烘瀯 where 鏈烘瀯ID=${user.companyPartyId} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
34 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
35 select 鏈烘瀯ID value,鍚嶇О text from bas_鏈烘瀯 where isnull(绠$悊鏈烘瀯ID,'')=${user.companyPartyId} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
36 ) a |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
37 ; |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
38 select case when col>1 then 'false' else 'true' end aaa from #t |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
39 ]]> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
40 </sql> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
41 </param> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
42 <param id="mrjg"> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
43 <sql> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
44 <![CDATA[ |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
45 select ${user.companyPartyId} id |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
46 ]]> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
47 </sql> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
48 </param> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
49 </params> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
50 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
51 <enums> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
52 <enum id="tjjg"> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
53 <sql> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
54 <![CDATA[ |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
55 select 鏈烘瀯ID value,鍚嶇О text from bas_鏈烘瀯 where 鏈烘瀯ID=${user.companyPartyId} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
56 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
57 select 鏈烘瀯ID value,鍚嶇О text from bas_鏈烘瀯 where isnull(绠$悊鏈烘瀯ID,'')=${user.companyPartyId} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
58 ]]> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
59 </sql> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
60 </enum> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
61 </enums> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
62 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
63 <header-items> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
64 <header-item id="缁熻鏈烘瀯" type="enum" enum-id="tjjg" title="缁熻鏈烘瀯" default="${mrjg}" hidden="${jgxs}" value-col="value" use-like='false' text-col="text" width="250" trigger-query="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
65 <header-item id="鏃堕棿" type="datetimerange" title="缁熻鏃堕棿" default="浠婂ぉ" width="190" trigger-query="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
66 <header-item id="鏌ユ壘" type="text" width="150" use-like="false" title="鏌ユ壘" hidden="true" empty-text="璇疯緭鍏ユ煡鎵句俊鎭" trigger-query="false"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
67 </header-items> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
68 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
69 <select> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
70 <field id="鍒嗙被" title="鍒嗙被"><![CDATA[鍒嗙被]]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
71 <field id="鍒1" title="鍒1"><![CDATA[鍒1]]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
72 <field id="鍒1鍊" title="鍒1鍊"><![CDATA[鍒1鍊糫]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
73 <field id="鍒2" title="鍒2"><![CDATA[鍒2]]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
74 <field id="鍒2鍊" title="鍒2鍊"><![CDATA[鍒2鍊糫]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
75 <field id="鍒3" title="鍒3"> <![CDATA[鍒3]]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
76 <field id="鍒3鍊" title="鍒3鍊"> <![CDATA[鍒3鍊糫]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
77 <field id="鍒4" title="鍒4"> <![CDATA[鍒4]]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
78 <field id="鍒4鍊" title="鍒4鍊"> <![CDATA[鍒4鍊糫]></field> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
79 </select> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
80 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
81 <from> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
82 <![CDATA[ |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
83 ( |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
84 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
85 '闂ㄨ瘖鎯呭喌' 鍒嗙被,'鎸傚彿浜烘暟' 鍒1,gh.鎸傚彿浜烘暟 鍒1鍊,'鎸傚彿閲戦' 鍒2,cast(gh.鎸傚彿閲戦 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
86 '棣栬瘖浜烘暟' 鍒3,gh.棣栬瘖浜烘暟 鍒3鍊,'澶嶈瘖浜烘暟' 鍒4,gh.澶嶈瘖浜烘暟 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
87 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
88 left join #gh gh on jg.鏈烘瀯ID=gh.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
89 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
90 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
91 '闂ㄨ瘖鎯呭喌' 鍒嗙被,'闂ㄨ瘖浜烘' 鍒1,mzjs.闂ㄨ瘖浜烘 鍒1鍊,'鎬婚噾棰' 鍒2,cast(mzjs.鎬婚噾棰 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
92 '鍖讳繚閲戦' 鍒3,mzjs.鎶ラ攢閲戦 鍒3鍊,'鐜伴噾閲戦' 鍒4,mzzf.鐜伴噾鏀粯 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
93 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
94 left join #mzjs mzjs on jg.鏈烘瀯ID=mzjs.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
95 left join #mzzf mzzf on jg.鏈烘瀯ID=mzzf.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
96 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
97 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
98 '闂ㄨ瘖鎯呭喌' 鍒嗙被,'澶勬柟鎬绘暟' 鍒1,mzcf.澶勬柟鎬绘暟 鍒1鍊,'鑽搧閲戦' 鍒2,cast(mzcf.鑽搧閲戦 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
99 '璇婄枟閲戦' 鍒3,mzcf.璇婄枟閲戦 鍒3鍊,'澶勬柟鍧囬' 鍒4,case when mzcf.澶勬柟鎬绘暟<>0 then cast(mzjs.鎬婚噾棰/mzcf.澶勬柟鎬绘暟 as decimal(10,2)) else null end 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
100 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
101 left join #mzcf mzcf on jg.鏈烘瀯ID=mzcf.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
102 left join #mzjs mzjs on jg.鏈烘瀯ID=mzjs.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
103 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
104 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
105 '闂ㄨ瘖鎯呭喌' 鍒嗙被,'鑷垂浜烘' 鍒1,mzjs.鑷垂浜烘 鍒1鍊,'鍖讳繚浜烘' 鍒2,cast(mzjs.鍖讳繚浜烘 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
106 '鏅氶棬璇婃暟' 鍒3,mzjs.鏅氶棬璇婁汉娆 鍒3鍊,'鐗圭梾浜烘' 鍒4,mzjs.鐗圭梾浜烘 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
107 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
108 left join #mzjs mzjs on jg.鏈烘瀯ID=mzjs.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
109 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
110 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
111 '浣忛櫌鎯呭喌' 鍒嗙被,'鍏ラ櫌鎬讳汉鏁' 鍒1,ry.鍏ラ櫌鎬讳汉鏁 鍒1鍊,'褰撳墠鍦ㄩ櫌鎬讳汉鏁' 鍒2,cast(zy.鍦ㄩ櫌鎬讳汉鏁 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
112 '鍑洪櫌鎬讳汉鏁' 鍒3,cy.鍑洪櫌鎬讳汉鏁 鍒3鍊,'缁撶畻鎬讳汉鏁' 鍒4,zyjs.缁撶畻鎬讳汉鏁 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
113 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
114 left join #ry ry on jg.鏈烘瀯ID=ry.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
115 left join #cy cy on jg.鏈烘瀯ID=cy.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
116 left join #zyjs zyjs on jg.鏈烘瀯ID=zyjs.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
117 left join #zy zy on jg.鏈烘瀯ID=zy.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
118 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
119 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
120 '浣忛櫌鎯呭喌' 鍒嗙被,'缁撶畻閲戦' 鍒1,zyjs.缁撶畻閲戦 鍒1鍊,'鑱屽伐閲戦' 鍒2,cast(zyjs.鑱屽伐閲戦 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
121 '灞呮皯閲戦' 鍒3,zyjs.灞呮皯閲戦 鍒3鍊,'鑷垂閲戦' 鍒4,zyjs.鑷垂閲戦 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
122 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
123 left join #zyjs zyjs on jg.鏈烘瀯ID=zyjs.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
124 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
125 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
126 '浣忛櫌鎯呭喌' 鍒嗙被,'棰勪氦鏀跺叆' 鍒1,zyyj.棰勪氦鏀跺叆 鍒1鍊,'鑽搧鏀跺叆' 鍒2,cast(zycf.鑽搧鏀跺叆 as nvarchar(10)) 鍒2鍊, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
127 '璇婄枟鏀跺叆' 鍒3,zycf.璇婄枟鏀跺叆 鍒3鍊,'鍖婚櫌鎵挎媴' 鍒4,zyjs.鍖婚櫌鎵挎媴 鍒4鍊 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
128 from #jg jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
129 left join #zyjs zyjs on jg.鏈烘瀯ID=zyjs.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
130 left join #zyyj zyyj on jg.鏈烘瀯ID=zyyj.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
131 left join #zycf zycf on jg.鏈烘瀯ID=zycf.鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
132 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
133 select null,'',null,'宸ヤ綔閲忔儏鍐(鍖婚櫌瀹為檯宸','浣滈噺鎯呭喌,涓庣粨绠','鏁版嵁鏃犲叧)',null,null,null |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
134 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
135 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
136 null,'鎬昏垂鐢',t.鎬婚噾棰,'鑽搧閲戦',cast(t.鑽搧閲戦 as nvarchar(10)) ,'璇婄枟閲戦',t.璇婄枟閲戦,null,null |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
137 from #gzl t |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
138 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
139 select null,'',null,'鍚勯」鏀跺叆椤圭洰璐圭敤鎯呭喌','(缁撶畻鏁版嵁)','',null,null,null |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
140 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
141 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
142 null,a.鏀跺叆椤圭洰,a.閲戦,b.鏀跺叆椤圭洰,cast(b.閲戦 as nvarchar(10)) ,c.鏀跺叆椤圭洰,c.閲戦,d.鏀跺叆椤圭洰,d.閲戦 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
143 from #a a |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
144 left join #b b on a.px+1=b.px |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
145 left join #c c on a.px+2=c.px |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
146 left join #d d on a.px+3=d.px |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
147 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
148 select null, '鍚堣' ,sum(t.閲戦),null,null,null,null,null,null |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
149 from #srxm t |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
150 ) t |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
151 ]]> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
152 </from> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
153 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
154 <with> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
155 <![CDATA[ |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
156 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
157 with t as ( |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
158 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
159 gh.鐧昏鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
160 count(distinct gh.妗fID) 鎸傚彿浜烘暟, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
161 count(distinct case when isnull(jzjl.鍒濊瘖,'鏄')='鏄' then jzjl.妗fID else null end) 棣栬瘖浜烘暟, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
162 count(distinct case when isnull(jzjl.鍒濊瘖,'鏄')='鍚' then jzjl.妗fID else null end) 澶嶈瘖浜烘暟, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
163 sum(js.閲戦) 鎸傚彿閲戦 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
164 from reg_鎸傚彿 gh |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
165 inner join opd_璁板綍 jzjl on gh.鎸傚彿ID=jzjl.鎸傚彿ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
166 inner join opc_璁板綍_缁撶畻 js on gh.缁撶畻ID=js.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
167 where gh.灏辫瘖鏃ユ湡 between ${鏃堕棿_START} and ${鏃堕棿_END} and gh.鐧昏鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
168 group by gh.鐧昏鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
169 ) |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
170 select * into #gh from t; |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
171 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
172 js.缁撶畻鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
173 count(distinct jl.妗fID+'-'+jl.寮鍗曞尰鐢烮D+'-'+convert(nvarchar(10),jl.鐧昏鏃堕棿,120)) 闂ㄨ瘖浜烘, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
174 sum(js.閲戦) 鎬婚噾棰, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
175 sum(js.鎶ラ攢閲戦) 鎶ラ攢閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
176 COUNT(DISTINCT (case when ybjs.缁撶畻ID IS NULL THEN jl.妗fID+'-'+jl.寮鍗曞尰鐢烮D+'-'+convert(nvarchar(10),jl.鐧昏鏃堕棿,120) ELSE NULL END)) 鑷垂浜烘, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
177 COUNT(DISTINCT (case when ybjs.缁撶畻ID IS NOT NULL THEN jl.妗fID+'-'+jl.寮鍗曞尰鐢烮D+'-'+convert(nvarchar(10),jl.鐧昏鏃堕棿,120) ELSE NULL END)) 鍖讳繚浜烘, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
178 count(distinct (case when jzlb.鍚嶇О in ('闂ㄨ瘖鎱㈢壒鐥') then jl.妗fID+'-'+jl.寮鍗曞尰鐢烮D+'-'+convert(nvarchar(10),jl.鐧昏鏃堕棿,120) else null end)) 鐗圭梾浜烘, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
179 count(distinct (case when jzlb.鍚嶇О not in ('闂ㄨ瘖鎱㈢壒鐥') then jl.妗fID+'-'+jl.寮鍗曞尰鐢烮D+'-'+convert(nvarchar(10),jl.鐧昏鏃堕棿,120) else null end)) 鏅氶棬璇婁汉娆 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
180 into #mzjs |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
181 from opc_璁板綍 jl |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
182 inner join opc_璁板綍_缁撶畻 js on jl.璁板綍ID=js.璁板綍ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
183 left join yb_灏辫瘖缁撶畻璁板綍 ybjs on js.缁撶畻ID=ybjs.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
184 left join bas_灏辫瘖绫诲埆 jzlb on jl.鍖荤枟绫诲埆ID=jzlb.鍖荤枟绫诲埆ID AND jl.灏辫瘖绫诲埆ID=jzlb.灏辫瘖绫诲埆ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
185 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
186 and jl.澶勬柟鏉ユ簮<>'闂ㄨ瘖鎸傚彿' |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
187 group by js.缁撶畻鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
188 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
189 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
190 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
191 js.缁撶畻鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
192 sum(case when zffs.鍚嶇О='鐜伴噾' then zf.鏀粯閲戦 else null end) 鐜伴噾鏀粯, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
193 sum(case when zffs.鍚嶇О!='鐜伴噾' then zf.鏀粯閲戦 else null end) 鍏朵粬鏀粯 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
194 into #mzzf |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
195 from opc_璁板綍_缁撶畻 js |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
196 inner join opc_璁板綍 jl on js.璁板綍ID=jl.璁板綍ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
197 inner join opc_璁板綍_缁撶畻_鏀粯 zf on js.缁撶畻ID=zf.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
198 inner join bas_鏀粯鏂瑰紡 zffs on zf.鏀粯鏂瑰紡ID=zffs.鏀粯鏂瑰紡ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
199 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
200 and jl.澶勬柟鏉ユ簮<>'闂ㄨ瘖鎸傚彿' |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
201 group by js.缁撶畻鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
202 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
203 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
204 --cf |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
205 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
206 js.缁撶畻鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
207 count(distinct fymx.澶勬柟ID) 澶勬柟鎬绘暟, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
208 sum(case when xm.绫诲埆ID in ('5','6','7','8') then mx.閲戦 else null end) 鑽搧閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
209 sum(case when xm.绫诲埆ID not in ('5','6','7','8') then mx.閲戦 else null end) 璇婄枟閲戦 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
210 into #mzcf |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
211 from opc_璁板綍_鏄庣粏 mx |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
212 inner join opc_璁板綍_缁撶畻 js on mx.缁撶畻ID=js.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
213 inner join bas_鏀惰垂椤圭洰 xm on mx.椤圭洰ID=xm.椤圭洰ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
214 left join opd_澶勬柟_鍖诲槺_璐圭敤 fymx on mx.鍖诲槺鏄庣粏ID=fymx.鏄庣粏ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
215 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} AND js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
216 group by js.缁撶畻鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
217 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
218 --浣忛櫌 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
219 select jl.鐧昏鏈烘瀯ID 鏈烘瀯ID, count(1) 鍏ラ櫌鎬讳汉鏁 into #ry |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
220 from ihm_璁板綍 jl |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
221 where jl.鍏ラ櫌鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} AND 鐧昏鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
222 group by jl.鐧昏鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
223 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
224 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
225 jl.鐧昏鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
226 count(1) 鍦ㄩ櫌鎬讳汉鏁 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
227 into #zy |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
228 from ihm_璁板綍 jl |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
229 where jl.鐘舵 in ('鍦ㄥ簥','寰呭垎') |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
230 group by jl.鐧昏鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
231 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
232 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
233 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
234 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
235 jl.鐧昏鏈烘瀯ID 鏈烘瀯ID, count(1) 鍑洪櫌鎬讳汉鏁 into #cy |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
236 from ihm_璁板綍 jl |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
237 where jl.鍑洪櫌鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
238 group by jl.鐧昏鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
239 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
240 select js.缁撶畻鏈烘瀯ID 鏈烘瀯ID,count(distinct 璁板綍ID) 缁撶畻鎬讳汉鏁, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
241 sum(js.閲戦) 缁撶畻閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
242 sum(case when ybjs.闄╃绫诲瀷='310' then js.閲戦 else null end) 鑱屽伐閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
243 sum(case when ybjs.闄╃绫诲瀷='390' then js.閲戦 else null end) 灞呮皯閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
244 sum(case when ybjs.缁撶畻ID is null then js.閲戦 else null end) 鑷垂閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
245 sum(js.鍖婚櫌鎵挎媴) 鍖婚櫌鎵挎媴 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
246 into #zyjs |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
247 from ihm_璁板綍_缁撶畻 js |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
248 left join yb_灏辫瘖缁撶畻璁板綍 ybjs on js.缁撶畻ID=ybjs.缁撶畻ID AND js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
249 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
250 group by js.缁撶畻鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
251 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
252 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
253 yj.鐧昏鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
254 sum(yj.閲戦) 棰勪氦鏀跺叆 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
255 into #zyyj |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
256 from ihm_璁板綍_棰勪氦 yj |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
257 where yj.鏀惰垂鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and yj.鐧昏鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
258 group by yj.鐧昏鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
259 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
260 select js.缁撶畻鏈烘瀯ID 鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
261 sum(case when xm.绫诲埆ID in ('5','6','7','8') then case when js.鐘舵='浣滃簾' then -mx.閲戦 else mx.閲戦 end else null end) 鑽搧鏀跺叆, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
262 sum(case when xm.绫诲埆ID not in ('5','6','7','8') then case when js.鐘舵='浣滃簾' then -mx.閲戦 else mx.閲戦 end else null end) 璇婄枟鏀跺叆 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
263 into #zycf |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
264 from ihm_璁板綍_缁撶畻 js |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
265 inner join ihm_璁板綍_缁撶畻_鏄庣粏 jsmx on js.缁撶畻ID=jsmx.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
266 inner join ihm_璁板綍_鏄庣粏 mx on jsmx.鏄庣粏ID=mx.鏄庣粏ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
267 inner join bas_鏀惰垂椤圭洰 xm on mx.椤圭洰ID=xm.椤圭洰ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
268 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
269 group by js.缁撶畻鏈烘瀯ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
270 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
271 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
272 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
273 sum(case when xm.绫诲埆ID in ('5','6','7','8') then mx.閲戦 else null end) 鑽搧閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
274 sum(case when xm.绫诲埆ID not in ('5','6','7','8') then mx.閲戦 else null end) 璇婄枟閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
275 sum(mx.閲戦) 鎬婚噾棰 into #mx |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
276 from opc_璁板綍_鏄庣粏 mx |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
277 inner join bas_鏀惰垂椤圭洰 xm on mx.椤圭洰ID=xm.椤圭洰ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
278 where mx.鐧昏鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and mx.鐧昏鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
279 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
280 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
281 sum(case when xm.绫诲埆ID in ('5','6','7','8') then mx.閲戦 else null end) 鑽搧閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
282 sum(case when xm.绫诲埆ID not in ('5','6','7','8') then mx.閲戦 else null end) 璇婄枟閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
283 sum(mx.閲戦) 鎬婚噾棰 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
284 from ihm_璁板綍_鏄庣粏 mx |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
285 inner join bas_鏀惰垂椤圭洰 xm on mx.椤圭洰ID=xm.椤圭洰ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
286 where mx.鐧昏鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and mx.鐧昏鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
287 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
288 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
289 sum(t.鎬婚噾棰) 鎬婚噾棰, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
290 sum(t.鑽搧閲戦) 鑽搧閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
291 sum(t.璇婄枟閲戦) 璇婄枟閲戦 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
292 into #gzl |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
293 from #mx t |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
294 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
295 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
296 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
297 js.缁撶畻鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
298 xm.鏀跺叆椤圭洰, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
299 sum(mx.閲戦) 閲戦 into #srxmmx |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
300 from opc_璁板綍_缁撶畻 js |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
301 inner join opc_璁板綍_鏄庣粏 mx on js.缁撶畻ID=mx.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
302 inner join bas_鏀惰垂椤圭洰 xm on mx.椤圭洰ID=xm.椤圭洰ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
303 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
304 group by js.缁撶畻鏈烘瀯ID,xm.鏀跺叆椤圭洰 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
305 union all |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
306 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
307 js.缁撶畻鏈烘瀯ID, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
308 xm.鏀跺叆椤圭洰, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
309 sum(case when js.鐘舵='浣滃簾' then -mx.閲戦 else mx.閲戦 end) 閲戦 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
310 from ihm_璁板綍_缁撶畻 js |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
311 inner join ihm_璁板綍_缁撶畻_鏄庣粏 jsmx on js.缁撶畻ID=jsmx.缁撶畻ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
312 inner join ihm_璁板綍_鏄庣粏 mx on jsmx.鏄庣粏ID=mx.鏄庣粏ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
313 inner join bas_鏀惰垂椤圭洰 xm on mx.椤圭洰ID=xm.椤圭洰ID |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
314 where js.缁撶畻鏃堕棿 between ${鏃堕棿_START} and ${鏃堕棿_END} and js.缁撶畻鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
315 group by js.缁撶畻鏈烘瀯ID,xm.鏀跺叆椤圭洰 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
316 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
317 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
318 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
319 select |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
320 t.缁撶畻鏈烘瀯ID,t.鏀跺叆椤圭洰,sum(t.閲戦) 閲戦, |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
321 ROW_NUMBER()over(order by t.鏀跺叆椤圭洰) px into #srxm |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
322 from #srxmmx t |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
323 group by t.缁撶畻鏈烘瀯ID,t.鏀跺叆椤圭洰 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
324 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
325 select 鏀跺叆椤圭洰,閲戦,px into #a from #srxm t where t.px%4=1 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
326 select 鏀跺叆椤圭洰,閲戦,px into #b from #srxm t where t.px%4=2 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
327 select 鏀跺叆椤圭洰,閲戦,px into #c from #srxm t where t.px%4=3 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
328 select 鏀跺叆椤圭洰,閲戦,px into #d from #srxm t where t.px%4=0 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
329 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
330 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
331 select jg.鏈烘瀯ID into #jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
332 from bas_鏈烘瀯 jg |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
333 where jg.鏈烘瀯ID=${缁熻鏈烘瀯} |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
334 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
335 ]]> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
336 </with> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
337 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
338 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
339 <where> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
340 <![CDATA[ |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
341 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
342 ]]> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
343 </where> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
344 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
345 <groups> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
346 <group> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
347 <group-col id="鍒嗙被" field-id="鍒嗙被" width="120" span="true" span-dep-col-id="鍒嗙被"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
348 <group-col id="鍒1" field-id="鍒1" width="120" /> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
349 <group-col id="鍒1鍊" field-id="鍒1鍊" width="80" /> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
350 <group-col id="鍒2" field-id="鍒2" width="170"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
351 <group-col id="鍒2鍊" field-id="鍒2鍊" width="125"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
352 <group-col id="鍒3" field-id="鍒3" width="120"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
353 <group-col id="鍒3鍊" field-id="鍒3鍊" width="80"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
354 <group-col id="鍒4" field-id="鍒4" width="120"/> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
355 <group-col id="鍒4鍊" field-id="鍒4鍊" width="80" /> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
356 </group> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
357 </groups> |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
358 |
be9328b4ea2d
Up:杩愯惀鎯呭喌姹囨; Fix锛欳lear initial commit
Schmit <liny.jii@nnsui.com>
parents:
diff
changeset
|
359 </report> |