From 386d8847b3304e8f80ac334f73f39477ca4467e6 Mon Sep 17 00:00:00 2001 From: Chris Tsang Date: Wed, 5 Aug 2026 20:47:38 +0100 Subject: [PATCH 1/4] Mark u64 as unsupported on SQLite in column-types table --- SeaORM/docs/04-generate-entity/03-column-types.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/SeaORM/docs/04-generate-entity/03-column-types.md b/SeaORM/docs/04-generate-entity/03-column-types.md index 1c02885ae44..f9f74815434 100644 --- a/SeaORM/docs/04-generate-entity/03-column-types.md +++ b/SeaORM/docs/04-generate-entity/03-column-types.md @@ -23,12 +23,14 @@ For the mappings of Rust primitive data types: | `i32` | Integer | integer | int | integer | | `u32` | Unsigned | integer | int unsigned | N/A | | `i64` | BigInteger | integer | bigint | bigint | -| `u64` | BigUnsigned | integer | bigint unsigned | N/A | +| `u64` | BigUnsigned | unsupported¹ | bigint unsigned | N/A | | `f32` | Float | float | float | real | | `f64` | Double | double | double | double precision | | `bool` | Boolean | boolean | bool | bool | | `Vec` | Binary | blob | blob | bytea | +> ¹ `u64` is not supported on SQLite. SQLite stores only 64-bit *signed* integers, and the underlying `sqlx` SQLite driver does not encode `u64` (values above `i64::MAX` cannot be represented). Use `i64`, or store large unsigned values as `String` / `Vec`. See [#1400](https://github.com/SeaQL/sea-orm/issues/1400). + For the mappings of Rust non-primitive data types. You can check [`entity/prelude.rs`](https://github.com/SeaQL/sea-orm/blob/master/src/entity/prelude.rs) for all of the reexported types. | Rust type | Database Type
([`ColumnType`](https://docs.rs/sea-orm/2.0.0/sea_orm/entity/enum.ColumnType.html)) | SQLite
datatype | MySQL
datatype | PostgreSQL
datatype | From 797f550d4760cf9ed464e676d82b80cd45b832d4 Mon Sep 17 00:00:00 2001 From: Chris Tsang Date: Wed, 5 Aug 2026 20:52:20 +0100 Subject: [PATCH 2/4] Mark u64 as unsupported on SQLite (zh-CN) --- .../current/04-generate-entity/03-column-types.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md b/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md index 53936fe8641..a6c991debb0 100644 --- a/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md +++ b/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md @@ -23,12 +23,14 @@ Rust 基本数据类型的映射: | `i32` | Integer | integer | int | integer | | `u32` | Unsigned | integer | int unsigned | N/A | | `i64` | BigInteger | integer | bigint | bigint | -| `u64` | BigUnsigned | integer | bigint unsigned | N/A | +| `u64` | BigUnsigned | 不支持¹ | bigint unsigned | N/A | | `f32` | Float | float | float | real | | `f64` | Double | double | double | double precision | | `bool` | Boolean | boolean | bool | bool | | `Vec` | Binary | blob | blob | bytea | +> ¹ SQLite 不支持 `u64`。SQLite 仅存储 64 位*有符号*整数,且底层 `sqlx` SQLite 驱动无法编码 `u64`(无法表示大于 `i64::MAX` 的值)。请改用 `i64`,或将较大的无符号值存储为 `String` / `Vec`。参见 [#1400](https://github.com/SeaQL/sea-orm/issues/1400)。 + Rust 非基本数据类型的映射。你可以查看 [`entity/prelude.rs`](https://github.com/SeaQL/sea-orm/blob/master/src/entity/prelude.rs) 了解所有重新导出的类型。 | Rust type | Database Type
([`ColumnType`](https://docs.rs/sea-orm/2.0.0-rc.25/sea_orm/entity/enum.ColumnType.html)) | SQLite
datatype | MySQL
datatype | PostgreSQL
datatype | From f07e9c7311cc66392e66ece9201d557252c33553 Mon Sep 17 00:00:00 2001 From: Chris Tsang Date: Wed, 5 Aug 2026 20:54:07 +0100 Subject: [PATCH 3/4] Use native GFM footnote syntax (EN) --- SeaORM/docs/04-generate-entity/03-column-types.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SeaORM/docs/04-generate-entity/03-column-types.md b/SeaORM/docs/04-generate-entity/03-column-types.md index f9f74815434..91bdad80c89 100644 --- a/SeaORM/docs/04-generate-entity/03-column-types.md +++ b/SeaORM/docs/04-generate-entity/03-column-types.md @@ -23,13 +23,13 @@ For the mappings of Rust primitive data types: | `i32` | Integer | integer | int | integer | | `u32` | Unsigned | integer | int unsigned | N/A | | `i64` | BigInteger | integer | bigint | bigint | -| `u64` | BigUnsigned | unsupported¹ | bigint unsigned | N/A | +| `u64` | BigUnsigned | unsupported[^u64-sqlite] | bigint unsigned | N/A | | `f32` | Float | float | float | real | | `f64` | Double | double | double | double precision | | `bool` | Boolean | boolean | bool | bool | | `Vec` | Binary | blob | blob | bytea | -> ¹ `u64` is not supported on SQLite. SQLite stores only 64-bit *signed* integers, and the underlying `sqlx` SQLite driver does not encode `u64` (values above `i64::MAX` cannot be represented). Use `i64`, or store large unsigned values as `String` / `Vec`. See [#1400](https://github.com/SeaQL/sea-orm/issues/1400). +[^u64-sqlite]: `u64` is not supported on SQLite. SQLite stores only 64-bit *signed* integers, and the underlying `sqlx` SQLite driver does not encode `u64` (values above `i64::MAX` cannot be represented). Use `i64`, or store large unsigned values as `String` / `Vec`. See [#1400](https://github.com/SeaQL/sea-orm/issues/1400). For the mappings of Rust non-primitive data types. You can check [`entity/prelude.rs`](https://github.com/SeaQL/sea-orm/blob/master/src/entity/prelude.rs) for all of the reexported types. From 3b6642f0d3413db04c1352784a6c9343485f89d6 Mon Sep 17 00:00:00 2001 From: Chris Tsang Date: Wed, 5 Aug 2026 20:54:08 +0100 Subject: [PATCH 4/4] Use native GFM footnote syntax (zh-CN) --- .../current/04-generate-entity/03-column-types.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md b/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md index a6c991debb0..22d77d262ba 100644 --- a/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md +++ b/SeaORM/i18n/zh-CN/docusaurus-plugin-content-docs/current/04-generate-entity/03-column-types.md @@ -23,13 +23,13 @@ Rust 基本数据类型的映射: | `i32` | Integer | integer | int | integer | | `u32` | Unsigned | integer | int unsigned | N/A | | `i64` | BigInteger | integer | bigint | bigint | -| `u64` | BigUnsigned | 不支持¹ | bigint unsigned | N/A | +| `u64` | BigUnsigned | 不支持[^u64-sqlite] | bigint unsigned | N/A | | `f32` | Float | float | float | real | | `f64` | Double | double | double | double precision | | `bool` | Boolean | boolean | bool | bool | | `Vec` | Binary | blob | blob | bytea | -> ¹ SQLite 不支持 `u64`。SQLite 仅存储 64 位*有符号*整数,且底层 `sqlx` SQLite 驱动无法编码 `u64`(无法表示大于 `i64::MAX` 的值)。请改用 `i64`,或将较大的无符号值存储为 `String` / `Vec`。参见 [#1400](https://github.com/SeaQL/sea-orm/issues/1400)。 +[^u64-sqlite]: SQLite 不支持 `u64`。SQLite 仅存储 64 位*有符号*整数,且底层 `sqlx` SQLite 驱动无法编码 `u64`(无法表示大于 `i64::MAX` 的值)。请改用 `i64`,或将较大的无符号值存储为 `String` / `Vec`。参见 [#1400](https://github.com/SeaQL/sea-orm/issues/1400)。 Rust 非基本数据类型的映射。你可以查看 [`entity/prelude.rs`](https://github.com/SeaQL/sea-orm/blob/master/src/entity/prelude.rs) 了解所有重新导出的类型。