OceanBase Developer Center 阿里数据使用的坑,由Mysql转为oceanBase注意避坑

说明:最近项目上说使用新的数据阿里的oceanBase,结果一步一个坑;

因为这个oceanBase在Navicat 上使用不了,无法操作表设计,所以只能下载OceanBase Developer Center  工具;

使用文档:https://www.oceanbase.com/docs/community-observer-cn-10000000000901363

目前主要遇到以下问题:

1、不能直接在建表的时候点一下创建主健;

2、字段类型错了,修改超级麻烦,如以下示例,创建字段的时候是字符串类型想改为bigint类型,改不了,工具改不了,sql改不了,只能删了重建;

执行以下 SQL 失败

ALTER TABLE t_voice MODIFY device_imei BIGINT(20)

失败原因:

ErrorCode = 1235, SQLState = 0A000, Details = Alter non string type not supported

3、oceanBase没有主健索引一说,反正在说明文档上没有找到,工具上也没有

4、2023.9.1 使用版本是5.7.25-OceanBase_CE-v4.2.0.0

OceanBase数据库 使用mybatisplus的updateBatchById方法报错;Not supported feature or function

控制台打印:

报错异常如下:

Error flushing statements. Cause: java.sql.SQLException: Not supported feature or function

Cause: java.sql.SQLException: Not supported feature or function

; uncategorized SQLException; SQL state [0A000]; error code [1235]; Not supported feature or function; nested exception is java.sql.SQLException: Not supported feature or function

这个问题已经找到解决方案:

在Jdbc url配置上,加上 &rewriteBatchedStatements=true&allowMultiQueries=true
之前只配置了前面那个

其他的坑遇到了接着补充完善.

评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值