diff --git a/README.es-ES.md b/README.es-ES.md
index 6e9d9b0..ddf14e4 100644
--- a/README.es-ES.md
+++ b/README.es-ES.md
@@ -33,6 +33,7 @@ SQL Chat esta construido en [Next.js](https://nextjs.org/), admite las siguiente
- PostgreSQL
- MSSQL
- TiDB Cloud
+- OceanBase
## Privacidad de la Data
diff --git a/README.md b/README.md
index 34be030..b3c66b5 100644
--- a/README.md
+++ b/README.md
@@ -33,6 +33,7 @@ SQL Chat is built by [Next.js](https://nextjs.org/), it supports the following d
- PostgreSQL
- MSSQL
- TiDB Cloud
+- OceanBase
## [sqlchat.ai](https://sqlchat.ai)
diff --git a/README.zh-CN.md b/README.zh-CN.md
index ac531e4..2a83e10 100644
--- a/README.zh-CN.md
+++ b/README.zh-CN.md
@@ -30,6 +30,7 @@ SQL Chat 是由 [Next.js](https://nextjs.org/) 构建的,它支持以下数据
- PostgreSQL
- MSSQL
- TiDB Cloud
+- OceanBase
## [sqlchat.ai](https://sqlchat.ai)
diff --git a/docs/docker-connection-setting.webp b/docs/docker-connection-setting.webp
index 5b6bca4..eeb88d0 100644
Binary files a/docs/docker-connection-setting.webp and b/docs/docker-connection-setting.webp differ
diff --git a/public/db-oceanbase.png b/public/db-oceanbase.png
new file mode 100644
index 0000000..be49a76
Binary files /dev/null and b/public/db-oceanbase.png differ
diff --git a/src/components/CreateConnectionModal.tsx b/src/components/CreateConnectionModal.tsx
index ca86643..e0844ab 100644
--- a/src/components/CreateConnectionModal.tsx
+++ b/src/components/CreateConnectionModal.tsx
@@ -59,6 +59,11 @@ const engines = [
name: "TiDB Serverless",
defaultPort: "4000",
},
+ {
+ type: Engine.OceanBase,
+ name: "OceanBase",
+ defaultPort: "2881",
+ },
// {
// type: Engine.Snowflake,
// name: "Snowflake",
diff --git a/src/components/EngineIcon.tsx b/src/components/EngineIcon.tsx
index 197643a..e1587f4 100644
--- a/src/components/EngineIcon.tsx
+++ b/src/components/EngineIcon.tsx
@@ -17,6 +17,8 @@ const EngineIcon = (props: Props) => {
return
;
} else if (engine === Engine.TiDB) {
return
;
+ } else if (engine === Engine.OceanBase) {
+ return
;
} else {
return ;
}
diff --git a/src/lib/connectors/index.ts b/src/lib/connectors/index.ts
index a80708b..c883598 100644
--- a/src/lib/connectors/index.ts
+++ b/src/lib/connectors/index.ts
@@ -18,6 +18,8 @@ export const newConnector = (connection: Connection): Connector => {
return postgres(connection);
case Engine.MSSQL:
return mssql(connection);
+ case Engine.OceanBase:
+ return mysql(connection);
default:
throw new Error("Unsupported engine type.");
}
diff --git a/src/types/connection.ts b/src/types/connection.ts
index 22e38ed..627f4bc 100644
--- a/src/types/connection.ts
+++ b/src/types/connection.ts
@@ -7,6 +7,7 @@ export enum Engine {
TiDB = "TiDB",
Snowflake = "SNOWFLAKE",
Hive = "HIVE",
+ OceanBase = "OCEANBASE"
}
export interface SSLOptions {