提交 63c00435 作者: ZhangJingKun

修改内关联为左关联

上级 9e4a279f
......@@ -22,7 +22,7 @@ public interface CharacterBasicInfoMapper extends BaseMapper<CharacterBasicInfo>
"a.id,a.uid,a.name,a.sex,a.birthplace,a.birthday,a.native_place,a.school,a.speciality,a.education,a.expert_occupation,a.head_sculpture,a.biographical_notes,a.category,a.award_records,a.part_time_job,a.research_field,a.evaluate,a.status," +
"b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time " +
"from character_basic_info a " +
"INNER JOIN character_change_info b " +
"LEFT JOIN character_change_info b " +
"on a.id = b.id " +
"LEFT JOIN character_category_structure c " +
"ON b.type_id = c.id " +
......@@ -33,7 +33,7 @@ public interface CharacterBasicInfoMapper extends BaseMapper<CharacterBasicInfo>
"a.id,a.uid,a.name,a.sex,a.birthplace,a.birthday,a.native_place,a.school,a.speciality,a.education,a.expert_occupation,a.head_sculpture,a.biographical_notes,a.category,a.award_records,a.part_time_job,a.research_field,a.evaluate,a.status," +
"b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time " +
"from character_basic_info a " +
"INNER JOIN character_change_info b " +
"LEFT JOIN character_change_info b " +
"on a.id = b.id " +
"LEFT JOIN character_category_structure c " +
"ON b.type_id = c.id " +
......@@ -50,7 +50,7 @@ public interface CharacterBasicInfoMapper extends BaseMapper<CharacterBasicInfo>
"a.id,a.uid,a.name,a.sex,a.birthplace,a.birthday,a.native_place,a.school,a.speciality,a.education,a.expert_occupation,a.head_sculpture,a.biographical_notes,a.category,a.award_records,a.part_time_job,a.research_field,a.evaluate,a.status," +
"b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time " +
"from character_basic_info a " +
"INNER JOIN character_change_info b " +
"LEFT JOIN character_change_info b " +
"on a.id = b.id " +
"LEFT JOIN character_category_structure c " +
"ON b.type_id = c.id " +
......@@ -64,7 +64,7 @@ public interface CharacterBasicInfoMapper extends BaseMapper<CharacterBasicInfo>
@Select("select count(1) " +
"from character_basic_info a " +
"INNER JOIN character_change_info b " +
"LEFT JOIN character_change_info b " +
"on a.id = b.id " +
"where 1=1 " +
"and b.duty = #{duty} " +
......@@ -78,7 +78,7 @@ public interface CharacterBasicInfoMapper extends BaseMapper<CharacterBasicInfo>
"b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time, " +
"COALESCE(b.take_office_time, b.create_time) AS order_time " +
"from character_basic_info a " +
"INNER JOIN character_change_info b " +
"LEFT JOIN character_change_info b " +
"on a.id = b.id " +
"LEFT JOIN character_category_structure c " +
"ON b.type_id = c.id " +
......
......@@ -9,7 +9,7 @@
select a.id,a.uid,a.name,a.sex,a.birthplace,a.birthday,a.native_place,a.school,a.speciality,a.education,a.expert_occupation,a.head_sculpture,a.biographical_notes,a.category,a.award_records,a.part_time_job,a.research_field,a.evaluate,a.status,d.tag_id,d.tag_name,
b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time
from character_basic_info a
INNER JOIN character_change_info b
LEFT JOIN character_change_info b
on a.id = b.id
LEFT JOIN character_category_structure c
ON b.type_id = c.id
......@@ -57,7 +57,7 @@
<select id="getCount" resultType="int">
SELECT count(1)
from character_basic_info a
INNER JOIN character_change_info b
LEFT JOIN character_change_info b
on a.id = b.id
where 1 = 1
and (b.status = 1 or b.status IS NULL)
......@@ -90,7 +90,7 @@
select a.id,a.uid,a.name,a.sex,a.birthplace,a.birthday,a.native_place,a.school,a.speciality,a.education,a.expert_occupation,a.head_sculpture,a.biographical_notes,a.category,a.award_records,a.part_time_job,a.research_field,a.evaluate,a.status,
b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time
from character_basic_info a
INNER JOIN character_change_info b
LEFT JOIN character_change_info b
on a.id = b.id
LEFT JOIN character_category_structure c
ON b.type_id = c.id
......
......@@ -8,7 +8,7 @@
select a.id,a.uid,a.name,a.sex,a.birthplace,a.birthday,a.native_place,a.school,a.speciality,a.education,a.expert_occupation,a.head_sculpture,a.biographical_notes,a.category,a.award_records,a.part_time_job,a.research_field,a.evaluate,a.status,d.tag_id,d.tag_name,
b.type_id,c.type_name,b.company_original,b.department_original,b.duty_original,b.company,b.department,b.duty,b.take_office_time,b.take_office_time_end,b.take_office_status,b.change_url,b.duties_update_time,b.duties_update_reason,b.check_status,b.check_result,b.article_id,b.article_index,b.update_desc,b.original_id,b.new_id,b.merge_status,a.create_by,a.create_time,a.update_by,a.update_time
from character_basic_info a
INNER JOIN character_change_info b
LEFT JOIN character_change_info b
on a.id = b.id
LEFT JOIN character_category_structure c
ON b.type_id = c.id
......@@ -32,7 +32,7 @@
<select id="getCharacterListByTagCount" resultType="int">
select count(1)
from character_basic_info a
INNER JOIN character_change_info b
LEFT JOIN character_change_info b
on a.id = b.id
LEFT JOIN character_category_structure c
ON b.type_id = c.id
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论