现象:
用MySQL的客户端或管理工具(如DBeaver/heidisql)正常导出是没有问题的,但是导入会提示错误.
原因:
导出时,默认建表语句添加了一些OceanBase特有的选项,MySQL不支持.打开导出的.sql文件可以看到,建表语句最后有类似: COLLATE = utf8mb4_bin ROW_FORMAT = DYNAMIC COMPRESSION = 'zstd_1.3.8' REPLICA_NUM = 1 BLOCK_SIZE = 16384 USE_BLOOM_FILTER = FALSE TABLET_SIZE = 134217728 PCTFREE = 0 的参数
导出时,默认建表语句添加了一些OceanBase特有的选项,MySQL不支持。打开导出的.sql文件可以看到,建表语句最后有相似之处:COLLATE = utf8mb4_bin ROW_FORMAT = DYNAMIC COMPRESSION = 'zstd_1.3.8' REPLICA_NUM = 1 BLOCK_SIZE = 16384 USE_BLOOM_FILTER = BLOCK_SIZE = 134217728 PCTFREE = 0 的参数解决方法:
删掉这些参数,保存,再导入即可
标签:语句,建表,OceanBase,MySQL,导出,报错,MySql,SIZE From: https://www.cnblogs.com/dirgo/p/18020386