查询逻辑修改
This commit is contained in:
@@ -61,5 +61,18 @@
|
||||
from course_details
|
||||
where course_id = #{courseId}
|
||||
</select>
|
||||
<select id="countByCourseId" resultType="com.sqx.modules.course.entity.CourseDetails">
|
||||
SELECT
|
||||
course_id as courseId,
|
||||
COUNT(*) AS courseDetailsCount
|
||||
FROM
|
||||
course_details
|
||||
where course_details_id in
|
||||
<foreach collection="detailIdList" item="ids" open="(" separator="," close=")">
|
||||
#{ids}
|
||||
</foreach>
|
||||
GROUP BY
|
||||
course_id
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
||||
Reference in New Issue
Block a user