Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hg-smart
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
platform
hg-smart
Commits
a2f7702f
Commit
a2f7702f
authored
Jul 06, 2024
by
wuwenlong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
iplat/eplat to schema
parent
1cd2b399
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
88 additions
and
88 deletions
+88
-88
tveci002.xml
src/main/java/com/baosight/hggp/demo/sql/tveci002.xml
+6
-6
HGBI001.xml
src/main/java/com/baosight/hggp/hg/bi/sql/HGBI001.xml
+81
-81
HGBI003.xml
src/main/java/com/baosight/hggp/hg/bi/sql/HGBI003.xml
+1
-1
No files found.
src/main/java/com/baosight/hggp/demo/sql/tveci002.xml
View file @
a2f7702f
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
<!-- table information
<!-- table information
Generate time : 2024-01-08 18:33:20
Generate time : 2024-01-08 18:33:20
Version : 1.0
Version : 1.0
tableName :
eplat.tveci002
tableName :
${eplatSchema}..tveci002
RES_ID VARCHAR NOT NULL primarykey,
RES_ID VARCHAR NOT NULL primarykey,
RES_CLASS VARCHAR NOT NULL primarykey,
RES_CLASS VARCHAR NOT NULL primarykey,
HTML_CODE VARCHAR,
HTML_CODE VARCHAR,
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
REC_REVISOR as "recRevisor",
<!-- 更新人员 -->
REC_REVISOR as "recRevisor",
<!-- 更新人员 -->
REC_REVISE_TIME as "recReviseTime",
<!-- 更新时间 -->
REC_REVISE_TIME as "recReviseTime",
<!-- 更新时间 -->
DEPENDENCIES as "dependencies"
<!-- js依赖 -->
DEPENDENCIES as "dependencies"
<!-- js依赖 -->
FROM
eplat
.tveci002 WHERE 1=1
FROM
${eplatSchema}.
.tveci002 WHERE 1=1
<isNotEmpty
prepend=
" AND "
property=
"resId"
>
<isNotEmpty
prepend=
" AND "
property=
"resId"
>
RES_ID = #resId#
RES_ID = #resId#
</isNotEmpty>
</isNotEmpty>
...
@@ -50,7 +50,7 @@
...
@@ -50,7 +50,7 @@
</select>
</select>
<select
id=
"count"
resultClass=
"int"
>
<select
id=
"count"
resultClass=
"int"
>
SELECT COUNT(*) FROM
eplat
.tveci002 WHERE 1=1
SELECT COUNT(*) FROM
${eplatSchema}.
.tveci002 WHERE 1=1
<isNotEmpty
prepend=
" AND "
property=
"resId"
>
<isNotEmpty
prepend=
" AND "
property=
"resId"
>
RES_ID = #resId#
RES_ID = #resId#
</isNotEmpty>
</isNotEmpty>
...
@@ -93,7 +93,7 @@
...
@@ -93,7 +93,7 @@
-->
-->
<insert
id=
"insert"
>
<insert
id=
"insert"
>
INSERT INTO
eplat
.tveci002 (RES_ID,
<!-- 资源ID -->
INSERT INTO
${eplatSchema}.
.tveci002 (RES_ID,
<!-- 资源ID -->
RES_CLASS,
<!-- 资源类型 -->
RES_CLASS,
<!-- 资源类型 -->
HTML_CODE,
<!-- html代码 -->
HTML_CODE,
<!-- html代码 -->
CSS_CODE,
<!-- 样式代码 -->
CSS_CODE,
<!-- 样式代码 -->
...
@@ -108,13 +108,13 @@
...
@@ -108,13 +108,13 @@
</insert>
</insert>
<delete
id=
"delete"
>
<delete
id=
"delete"
>
DELETE FROM
eplat.tveci002 WHERE
DELETE FROM
${eplatSchema}..tveci002 WHERE
RES_ID = #resId# AND
RES_ID = #resId# AND
RES_CLASS = #resClass#
RES_CLASS = #resClass#
</delete>
</delete>
<update
id=
"update"
>
<update
id=
"update"
>
UPDATE
eplat.tveci002
UPDATE
${eplatSchema}..tveci002
SET
SET
HTML_CODE = #htmlCode#,
<!-- html代码 -->
HTML_CODE = #htmlCode#,
<!-- html代码 -->
CSS_CODE = #cssCode#,
<!-- 样式代码 -->
CSS_CODE = #cssCode#,
<!-- 样式代码 -->
...
...
src/main/java/com/baosight/hggp/hg/bi/sql/HGBI001.xml
View file @
a2f7702f
...
@@ -29,10 +29,10 @@
...
@@ -29,10 +29,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
...
@@ -65,10 +65,10 @@
...
@@ -65,10 +65,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
...
@@ -105,10 +105,10 @@
...
@@ -105,10 +105,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
...
@@ -145,10 +145,10 @@
...
@@ -145,10 +145,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
...
@@ -186,10 +186,10 @@
...
@@ -186,10 +186,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
) C ON C.FACTORY_CODE=B.FACTORY_CODE AND C.GROUP_ID = B.ORG_NO
...
@@ -242,10 +242,10 @@
...
@@ -242,10 +242,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -274,10 +274,10 @@
...
@@ -274,10 +274,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -306,10 +306,10 @@
...
@@ -306,10 +306,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -348,10 +348,10 @@
...
@@ -348,10 +348,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -384,10 +384,10 @@
...
@@ -384,10 +384,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -416,10 +416,10 @@
...
@@ -416,10 +416,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -448,10 +448,10 @@
...
@@ -448,10 +448,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -490,10 +490,10 @@
...
@@ -490,10 +490,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -526,10 +526,10 @@
...
@@ -526,10 +526,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -558,10 +558,10 @@
...
@@ -558,10 +558,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -590,10 +590,10 @@
...
@@ -590,10 +590,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -632,10 +632,10 @@
...
@@ -632,10 +632,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -679,10 +679,10 @@
...
@@ -679,10 +679,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -718,10 +718,10 @@
...
@@ -718,10 +718,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -757,10 +757,10 @@
...
@@ -757,10 +757,10 @@
JOIN (
JOIN (
SELECT
SELECT
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
A.ORG_ID AS FACTORY_CODE, C.ORG_ID AS GROUP_ID,COUNT(*) AS NUM
FROM
iplat
.TXSOG01 A
FROM
${platSchema}
.TXSOG01 A
JOIN
iplat
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
${platSchema}
.TXSOG01 B ON A.ORG_ID = B.PARENT_ORG_ID
JOIN
iplat
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
${platSchema}
.TXSOG02 C ON B.ORG_ID = C.ORG_ID
JOIN
iplat
.XS_USER D ON C.USER_ID = D.USER_ID
JOIN
${platSchema}
.XS_USER D ON C.USER_ID = D.USER_ID
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
WHERE A.ORG_TYPE = 'factory' AND B.ORG_TYPE = 'prodGroup'
GROUP BY A.ORG_ID ,C.ORG_ID
GROUP BY A.ORG_ID ,C.ORG_ID
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
) B ON B.FACTORY_CODE=B.FACTORY_CODE AND B.GROUP_ID = A.ORG_NO
...
@@ -774,7 +774,7 @@
...
@@ -774,7 +774,7 @@
<select
id=
"queryCompanyCode"
parameterClass=
"java.util.HashMap"
<select
id=
"queryCompanyCode"
parameterClass=
"java.util.HashMap"
resultClass=
"java.util.HashMap"
>
resultClass=
"java.util.HashMap"
>
select COMPANY_CODE from
iplat
.XS_USER where 1=1
select COMPANY_CODE from
${platSchema}
.XS_USER where 1=1
<isNotEmpty
prepend=
" AND "
property=
"loginName"
>
<isNotEmpty
prepend=
" AND "
property=
"loginName"
>
LOGIN_NAME = #loginName#
LOGIN_NAME = #loginName#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/bi/sql/HGBI003.xml
View file @
a2f7702f
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
when c.LOG_VALUE = 6 then '二级报警状态'
when c.LOG_VALUE = 6 then '二级报警状态'
else '异常状态' end as STATUS_DESC
else '异常状态' end as STATUS_DESC
from hpjx.t_hpsb003 a
from hpjx.t_hpsb003 a
join
iplat
.TXSOG01 b on a.GROUP_CODE = b.ORG_ID and b.IS_DELETED = 0
join
${platSchema}
.TXSOG01 b on a.GROUP_CODE = b.ORG_ID and b.IS_DELETED = 0
join hpjx.t_hpsb002 c on a.DEVICE_CODE=c.EQUIPMENT_CODE
join hpjx.t_hpsb002 c on a.DEVICE_CODE=c.EQUIPMENT_CODE
where a.DELETE_FLAG = 0 and DEVICE_STATUS = 1 and c.EQUIPMENT_TYPE = 'STARUS_TYPE'
where a.DELETE_FLAG = 0 and DEVICE_STATUS = 1 and c.EQUIPMENT_TYPE = 'STARUS_TYPE'
and a.COMPANY_CODE = #companyCode#
and a.COMPANY_CODE = #companyCode#
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment