We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MYSQL 版本 8.0.23 表中包含一binary的列,报如下错误: Traceback (most recent call last): File "binlog2sql.py", line 150, in binlog2sql.process_binlog() File "binlog2sql.py", line 106, in process_binlog sql = concat_sql_from_binlog_event(cursor=cursor, binlog_event=binlog_event, no_pk=self.no_pk, File "/opt/binlog2sql/binlog2sql/binlog2sql_util.py", line 177, in concat_sql_from_binlog_event pattern = generate_sql_pattern(binlog_event, row=row, flashback=flashback, no_pk=no_pk) File "/opt/binlog2sql/binlog2sql/binlog2sql_util.py", line 241, in generate_sql_pattern return {'template': template, 'values': list(values)} File "/opt/binlog2sql/binlog2sql/binlog2sql_util.py", line 142, in fix_object return value.decode('utf-8') UnicodeDecodeError: 'utf-8' codec can't decode byte 0xeb in position 1: invalid continuation byte
The text was updated successfully, but these errors were encountered:
binary 列转成十六进制就行
Sorry, something went wrong.
可以将 blob 转成十六进制值,我改了一版,已经支持了,你可以试试: https://github.com/michael-liumh/binlog2sql.git
收到回复后,第一时间测试了下,可以恢复了,感谢
No branches or pull requests
MYSQL 版本 8.0.23
表中包含一binary的列,报如下错误:
Traceback (most recent call last):
File "binlog2sql.py", line 150, in
binlog2sql.process_binlog()
File "binlog2sql.py", line 106, in process_binlog
sql = concat_sql_from_binlog_event(cursor=cursor, binlog_event=binlog_event, no_pk=self.no_pk,
File "/opt/binlog2sql/binlog2sql/binlog2sql_util.py", line 177, in concat_sql_from_binlog_event
pattern = generate_sql_pattern(binlog_event, row=row, flashback=flashback, no_pk=no_pk)
File "/opt/binlog2sql/binlog2sql/binlog2sql_util.py", line 241, in generate_sql_pattern
return {'template': template, 'values': list(values)}
File "/opt/binlog2sql/binlog2sql/binlog2sql_util.py", line 142, in fix_object
return value.decode('utf-8')
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xeb in position 1: invalid continuation byte
The text was updated successfully, but these errors were encountered: