INSERT INTO BOOK_PRODUCT ( BOOK_ID, PRODUCT_ID, CHANNEL_ID, IS_SUPER,CREATED_USER, CREATED_DATE,PRODUCT_TYPE ) VALUES ( #{bookId, jdbcType=BIGINT}, #{productId, jdbcType=BIGINT}, #{channelId, jdbcType=BIGINT}, #{isSuper, jdbcType=TINYINT}, #{createdUser, jdbcType=BIGINT}, NOW(),#{productType, jdbcType=VARCHAR} )
DELETE FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId, jdbcType=BIGINT} AND PRODUCT_ID = #{productId, jdbcType=BIGINT} AND CHANNEL_ID = #{channelId, jdbcType=BIGINT} AND CREATED_USER = #{createdUser, jdbcType=BIGINT}
DELETE FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId, jdbcType=BIGINT}
DELETE FROM BOOK_PRODUCT WHERE BOOK_ID IN ${item}
SELECT BOOK_PRODUCT_ID, BOOK_ID, PRODUCT_ID, CHANNEL_ID,SOUND_ID,PRODUCT_TYPE,CREATED_USER FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId, jdbcType=BIGINT} AND CHANNEL_ID = #{channelId, jdbcType=BIGINT} AND CREATED_USER = #{createdUser, jdbcType=BIGINT}
DELETE FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId} AND CHANNEL_ID = #{channelId}
UPDATE BOOK_PRODUCT SET SOUND_ID = #{soundId} WHERE BOOK_ID = #{bookId} AND CHANNEL_ID = #{channelId} AND PRODUCT_ID = #{productId}
SELECT BOOK_PRODUCT_ID, BOOK_ID, PRODUCT_ID, CHANNEL_ID,SOUND_ID,PRODUCT_TYPE,CREATED_USER FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId, jdbcType=BIGINT} AND CHANNEL_ID = #{channelId, jdbcType=BIGINT} AND CREATED_USER = #{createdUser, jdbcType=BIGINT} AND PRODUCT_TYPE = #{productType}
UPDATE BOOK_PRODUCT SET SOUND_ID = null WHERE SOUND_ID = #{_parameter}
SELECT BOOK_PRODUCT_ID, BOOK_ID, PRODUCT_ID, CHANNEL_ID,CREATED_USER FROM BOOK_PRODUCT WHERE SOUND_ID = #{_parameter}
SELECT BOOK_PRODUCT_ID, BOOK_ID, PRODUCT_ID, CHANNEL_ID,CREATED_USER FROM BOOK_PRODUCT
UPDATE BOOK_PRODUCT SET PRODUCT_TYPE = #{item.productType} WHERE BOOK_PRODUCT_ID = #{item.bookProductId};
SELECT COUNT(1) FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId, jdbcType=BIGINT} AND CHANNEL_ID = #{channelId, jdbcType=BIGINT} AND CREATED_USER = #{adviserId, jdbcType=BIGINT} AND IS_SUPER = 1
SELECT COUNT(1) FROM BOOK_PRODUCT WHERE BOOK_ID = #{bookId, jdbcType=BIGINT} AND CHANNEL_ID = #{channelId, jdbcType=BIGINT} AND CREATED_USER = #{adviserId, jdbcType=BIGINT} AND IS_SUPER = 0