fix(系统): 修复达梦数据库 SQL 别名缺少双引号导致的兼容性问题

This commit is contained in:
wanghao
2026-03-19 14:30:51 +08:00
parent 86190b949f
commit 96e82801e0
2 changed files with 5 additions and 5 deletions
@@ -38,10 +38,10 @@
order by tian asc order by tian asc
</if> </if>
<if test="dbType == 'oracle' || dbType == 'oracle12c' || dbType == 'dm'"> <if test="dbType == 'oracle' || dbType == 'oracle12c' || dbType == 'dm'">
select count(*) as visit select count(*) as "visit"
,count(distinct(ip)) as ip ,count(distinct(ip)) as "ip"
,to_char(create_time, 'yyyy-mm-dd') as tian ,to_char(create_time, 'yyyy-mm-dd') as "tian"
,to_char(create_time, 'mm-dd') as type ,to_char(create_time, 'mm-dd') as "type"
from QH_SYS_LOG from QH_SYS_LOG
where log_type = 1 and create_time &gt;= #{dayStart} and create_time &lt; #{dayEnd} where log_type = 1 and create_time &gt;= #{dayStart} and create_time &lt; #{dayEnd}
group by to_char(create_time, 'yyyy-mm-dd'),to_char(create_time, 'mm-dd') group by to_char(create_time, 'yyyy-mm-dd'),to_char(create_time, 'mm-dd')
@@ -403,7 +403,7 @@
where INSTR(',' || #{userIds} || ',', ',' || id || ',') > 0 where INSTR(',' || #{userIds} || ',', ',' || id || ',') > 0
</select> </select>
<select id="getUserNumByOrgCodeList" resultType="java.util.HashMap"> <select id="getUserNumByOrgCodeList" resultType="java.util.HashMap">
SELECT org_code as orgCode, count(org_code) as num SELECT org_code as "orgCode", count(org_code) as "num"
FROM QH_SYS_USER FROM QH_SYS_USER
WHERE org_code LIKE WHERE org_code LIKE
<foreach collection="orgCodeList" item="orgCode" separator=" OR " open="(" close=")"> <foreach collection="orgCodeList" item="orgCode" separator=" OR " open="(" close=")">