Java多商戶在平臺編輯優(yōu)惠券協(xié)議的時候報錯:"nested exception is org.apache.ibatis.exceptions.TooManyResultsException: Expected one result (or null) to be returned by selectOne(), but found: 3"
根據(jù)報錯可以看出這個異常表明在執(zhí)行查詢時返回了3個結(jié)果,但是預(yù)期的是只返回一個結(jié)果或者返回 null,
根據(jù)這個報錯去數(shù)據(jù)庫查看數(shù)據(jù),發(fā)現(xiàn)優(yōu)惠券協(xié)議確實是有3條記錄,只需要刪除任意兩條數(shù)據(jù)就可以了
在eb_system_config這個表中找couponAgreement