fix: 修复SQL语句与实际表名大小写不一致的问题

This commit is contained in:
BugKing 2021-07-09 10:26:45 +08:00 committed by jianxing
parent d6d0682e96
commit cb01577851
2 changed files with 5 additions and 5 deletions

View File

@ -2,7 +2,7 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="io.metersphere.base.mapper.ext.ExtApiDocumentMapper">
<select id="findApiDocumentSimpleInfoByRequest" resultType="io.metersphere.api.dto.document.ApiDocumentInfoDTO">
SELECT api.id,api.name FROM Api_definition api WHERE api.protocol = 'HTTP'
SELECT api.id,api.name FROM api_definition api WHERE api.protocol = 'HTTP'
<if test="request.trashEnable == true">
AND api.status = 'Trash'
</if>

View File

@ -155,7 +155,7 @@
</select>
<select id="planList" resultMap="BaseResultMap"
parameterType="io.metersphere.track.request.testcase.QueryTestPlanRequest">
SELECT * FROM TEST_PLAN p LEFT JOIN test_plan_project t ON t.test_plan_id=p.ID
SELECT * FROM test_plan p LEFT JOIN test_plan_project t ON t.test_plan_id=p.ID
<where>
<if test="request.workspaceId != null">
AND p.workspace_id = #{request.workspaceId}
@ -186,7 +186,7 @@
</select>
<select id="selectByIds" resultMap="BaseResultMap" parameterType="java.util.List">
SELECT * FROM TEST_PLAN p where p.id in
SELECT * FROM test_plan p where p.id in
<foreach collection="list" item="planId" open="(" close=")" separator=",">
#{planId}
</foreach>
@ -215,7 +215,7 @@
</select>
<select id="selectTestPlanByRelevancy" resultMap="BaseResultMap" parameterType="io.metersphere.track.request.testcase.QueryTestPlanRequest">
SELECT * FROM TEST_PLAN p LEFT JOIN test_plan_project t ON t.test_plan_id=p.id
SELECT * FROM test_plan p LEFT JOIN test_plan_project t ON t.test_plan_id=p.id
<where>
AND (t.project_id = #{request.projectId} or p.project_id = #{request.projectId})
<if test="request.scenarioId != null">
@ -230,7 +230,7 @@
</where>
</select>
<select id="findTestProjectNameByTestPlanID" resultType="java.lang.String">
SELECT p.name FROM TEST_PLAN tp INNER JOIN project p ON p.id =tp.project_id
SELECT p.name FROM test_plan tp INNER JOIN project p ON p.id =tp.project_id
WHERE tp.id = #{0} limit 1;
</select>
<select id="findScheduleCreateUserById" resultType="java.lang.String">