修正统计SQL错误
This commit is contained in:
parent
243b5c3952
commit
1ae1576d35
@ -102,5 +102,5 @@ public interface BaseKnifeMapper {
|
||||
@Param("isLocked") Integer isLocked
|
||||
);
|
||||
|
||||
long countBaseKnife(Long mbbBdMrlId);
|
||||
long countBaseKnife(@Param("mbbBdMrlId") Long mbbBdMrlId);
|
||||
}
|
||||
|
@ -188,10 +188,9 @@
|
||||
, a.STANDARD_QUANTITY
|
||||
, a.AREA_CODE
|
||||
, a.KNIFE_LIFE
|
||||
, a.KNIFE_FINE_STATE
|
||||
a.RESET_COUNT,
|
||||
a.ITEM_OR_PRODUCT,
|
||||
a.PLAN_SHEET,
|
||||
, a.KNIFE_FINE_STATE a.RESET_COUNT, a.ITEM_OR_PRODUCT
|
||||
, a.PLAN_SHEET
|
||||
,
|
||||
, a.REMARK
|
||||
, a.ATTR1
|
||||
, a.ATTR2
|
||||
@ -203,7 +202,9 @@
|
||||
, a.UPDATE_TIME
|
||||
, a.IS_LOCKED
|
||||
, a.LOCKED_START_TIME
|
||||
, a.LOCKED_END_TIME, b.ITEM_ID as sub_ITEM_ID, b.ITEM_CODE as sub_ITEM_CODE
|
||||
, a.LOCKED_END_TIME
|
||||
, b.ITEM_ID as sub_ITEM_ID
|
||||
, b.ITEM_CODE as sub_ITEM_CODE
|
||||
, b.ITEM_NAME as sub_ITEM_NAME
|
||||
, b.SPECIFICATION as sub_SPECIFICATION
|
||||
, b.UNIT_OF_MEASURE as sub_UNIT_OF_MEASURE
|
||||
@ -513,15 +514,15 @@
|
||||
|
||||
<insert id="batchMdItem">
|
||||
insert into MD_ITEM(ITEM_ID, ITEM_CODE, ITEM_NAME, SPECIFICATION, UNIT_OF_MEASURE, ITEM_OR_PRODUCT,
|
||||
ITEM_TYPE_ID, ITEM_TYPE_CODE, ITEM_TYPE_NAME, ENABLE_FLAG, SAFE_STOCK_FLAG, MIN_STOCK,
|
||||
MAX_STOCK, REMARK, ATTR1, ATTR2, ATTR3, ATTR4, CREATE_BY, CREATE_TIME, UPDATE_BY,
|
||||
UPDATE_TIME, HIGH_VALUE, UNIT_NAME, MODEL_NUMBER, STANDARD_NUMBER) values
|
||||
ITEM_TYPE_ID, ITEM_TYPE_CODE, ITEM_TYPE_NAME, ENABLE_FLAG, SAFE_STOCK_FLAG, MIN_STOCK,
|
||||
MAX_STOCK, REMARK, ATTR1, ATTR2, ATTR3, ATTR4, CREATE_BY, CREATE_TIME, UPDATE_BY,
|
||||
UPDATE_TIME, HIGH_VALUE, UNIT_NAME, MODEL_NUMBER, STANDARD_NUMBER) values
|
||||
<foreach item="item" index="index" collection="list" separator=",">
|
||||
(#{item.itemId}, #{item.itemCode}, #{item.itemName}, #{item.specification}, #{item.unitOfMeasure},
|
||||
#{item.itemOrProduct}, #{item.itemTypeId}, #{item.itemTypeCode}, #{item.itemTypeName}, #{item.enableFlag},
|
||||
#{item.safeStockFlag}, #{item.minStock}, #{item.maxStock}, #{item.remark}, #{item.attr1}, #{item.attr2},
|
||||
#{item.attr3}, #{item.attr4}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime},
|
||||
#{item.highValue}, #{item.unitName}, #{item.modelNumber}, #{item.standardNumber})
|
||||
#{item.itemOrProduct}, #{item.itemTypeId}, #{item.itemTypeCode}, #{item.itemTypeName}, #{item.enableFlag},
|
||||
#{item.safeStockFlag}, #{item.minStock}, #{item.maxStock}, #{item.remark}, #{item.attr1}, #{item.attr2},
|
||||
#{item.attr3}, #{item.attr4}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime},
|
||||
#{item.highValue}, #{item.unitName}, #{item.modelNumber}, #{item.standardNumber})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
@ -566,7 +567,8 @@
|
||||
<select id="countBaseKnife" resultType="java.lang.Long">
|
||||
SELECT COUNT(*)
|
||||
FROM BASE_KNIFE BK
|
||||
WHERE MBB_BD_MRL_ID = #{mbbBdMrlId} AND KNIFE_FINE_STATE = 0 OR KNIFE_FINE_STATE = 1
|
||||
WHERE MBB_BD_MRL_ID = #{mbbBdMrlId}
|
||||
AND (KNIFE_FINE_STATE = 0 OR KNIFE_FINE_STATE = 1)
|
||||
</select>
|
||||
|
||||
<select id="selectScrapList" resultMap="BaseKnifeResult">
|
||||
|
Loading…
Reference in New Issue
Block a user