Skip to content

Commit

Permalink
Add feature flag option-sqlite-exact-column-type #708
Browse files Browse the repository at this point in the history
  • Loading branch information
tyt2y3 committed Dec 14, 2023
1 parent 256dee4 commit c9d683a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
### New Features

* Added feature flag `option-more-parentheses` to have more parentheses in expressions https://github.com/SeaQL/sea-query/pull/723
* Added feature flag `option-sqlite-exact-column-type` to only use `integer`

### Enhancements

* Add `from_clear` to allow emptying current from tables in select statement https://github.com/SeaQL/sea-query/pull/716

### Breaking Changes

Expand Down
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ all-types = [
"with-mac_address",
]
option-more-parentheses = []
option-sqlite-exact-column-type = []

[[test]]
name = "test-derive"
Expand Down
2 changes: 2 additions & 0 deletions src/backend/sqlite/table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,8 @@ impl SqliteQueryBuilder {
ColumnType::Integer | ColumnType::Unsigned => "integer".into(),
ColumnType::BigInteger | ColumnType::BigUnsigned => if is_auto_increment {
"integer"
} else if cfg!(feature = "option-sqlite-exact-column-type") {
"integer"
} else {
"bigint"
}
Expand Down

0 comments on commit c9d683a

Please sign in to comment.