Skip to content
This repository has been archived by the owner on Nov 24, 2023. It is now read-only.

Syncer convert binlog event to sql bit column error #874

Closed
sultan8252 opened this issue Aug 7, 2020 · 1 comment · Fixed by #876
Closed

Syncer convert binlog event to sql bit column error #874

sultan8252 opened this issue Aug 7, 2020 · 1 comment · Fixed by #876
Labels
help wanted This issue wanted some help from contributor severity/major type/bug This issue is a bug report

Comments

@sultan8252
Copy link

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do? If possible, provide a recipe for reproducing the error.

  2. What did you expect to see?

  3. What did you see instead?
    image

  4. Versions of the cluster

  5. current status of DM cluster (execute query-status in dmctl)

  6. Operation logs

    • Table schema
      CREATE TABLE `cash_withdraw_request` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `amount` decimal(12,2) NOT NULL COMMENT '提现申请金额', `applyTime` datetime NOT NULL COMMENT '提现申请时间', `fee` decimal(8,2) NOT NULL COMMENT '手续费', `handleTime` datetime DEFAULT NULL COMMENT '处理此请求的时间', `resultTIme` datetime DEFAULT NULL COMMENT '请求处理后接收时间', `bankCardNo` varchar(25) NOT NULL COMMENT '申请提现的银行卡号', `bankCardBranch` varchar(64) NOT NULL COMMENT '申请提现的银行卡的发卡行', `userId` int(10) unsigned NOT NULL COMMENT '申请用户id', `status` smallint(5) unsigned NOT NULL COMMENT '状态 UserDef.CASH_WITHDRAW_*', `operationComment` varchar(64) DEFAULT NULL COMMENT '操作注释,供后台人员使用', `bankCode` varchar(5) DEFAULT NULL COMMENT '申请提现的银行卡所在银行的代码,见bank_code.sql', `accountBankCity` varchar(64) DEFAULT NULL COMMENT '开户行城市', `accountBankId` varchar(12) DEFAULT NULL COMMENT '开户行行号,如001121004527', `isOutput` bit(1) DEFAULT b'0' COMMENT '是否已制表导出,默认是false(未导出)', `runUpAccount` decimal(14,2) unsigned NOT NULL DEFAULT 0.00 COMMENT '挂账金额', `freeWithdrawQuota` decimal(14,2) unsigned NOT NULL DEFAULT 0.00 COMMENT '免费提现配额', `withdrawCoupon` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否已发放提现红包', `handleRealname` varchar(20) DEFAULT NULL, `withdrawChannel` varchar(10) DEFAULT NULL, `refundedAmount` decimal(12,2) NOT NULL DEFAULT 0.00 COMMENT '原卡原退202状态下,已退款金额', PRIMARY KEY (`id`), KEY `idx_cash_withdraw_request_applyTime` (`applyTime`), KEY `fk_cash_withdraw_request_userId` (`userId`,`status`), KEY `idx_cash_withdraw_request_status` (`status`,`handleTime`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_bin AUTO_INCREMENT=13348699 COMMENT='提现申请表';

    • success query

REPLACE INTO `fuscent`.`cash_withdraw_request` (`id`,`amount`,`applyTime`,`fee`,`handleTime`,`resultTIme`,`bankCardNo`,`bankCardBranch`,`userId`,`status`,`operationComment`,`bankCode`,`accountBankCity`,`accountBankId`,`isOutput`,`runUpAccount`,`freeWithdrawQuota`,`withdrawCoupon`,`handleRealname`,`withdrawChannel`,`refundedAmount`) VALUES (13318698 ,1097.71 ,'2020-08-05 20:17:30' ,0.00 ,'2020-08-05 20:17:39' ,NULL ,'6222031804000066821' ,'中国工商银行' ,203258 ,160 ,NULL ,'102' ,NULL ,NULL ,b'0' ,0.00 ,1097.71 ,0 ,NULL ,'存管出金' ,0.00);

  • failed query

REPLACE INTO `fuscent`.`cash_withdraw_request` (`id`,`amount`,`applyTime`,`fee`,`handleTime`,`resultTIme`,`bankCardNo`,`bankCardBranch`,`userId`,`status`,`operationComment`,`bankCode`,`accountBankCity`,`accountBankId`,`isOutput`,`runUpAccount`,`freeWithdrawQuota`,`withdrawCoupon`,`handleRealname`,`withdrawChannel`,`refundedAmount`) VALUES (13318698 ,1097.71 ,'2020-08-05 20:17:30' ,0.00 ,'2020-08-05 20:17:39' ,NULL ,'6222031804000066821' ,'中国工商银行' ,203258 ,160 ,NULL ,'102' ,NULL ,NULL ,'0' ,0.00 ,1097.71 ,0 ,NULL ,'存管出金' ,0.00);

  • other image
    image
@csuzhangxc csuzhangxc added help wanted This issue wanted some help from contributor type/bug This issue is a bug report labels Aug 7, 2020
@lance6716
Copy link
Collaborator

seems caused by

return strconv.FormatUint(uint64(v), 10)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
help wanted This issue wanted some help from contributor severity/major type/bug This issue is a bug report
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants