mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-10-24 02:07:08 +02:00
fix: map BOOLEAN/BOOL column types to int affinity in column_affinity()
This commit is contained in:
parent
85b1be10c8
commit
26ca4cef71
2 changed files with 21 additions and 0 deletions
|
|
@ -182,6 +182,8 @@ def column_affinity(column_type: str) -> type:
|
|||
return bytes
|
||||
if "REAL" in column_type or "FLOA" in column_type or "DOUB" in column_type:
|
||||
return float
|
||||
if "BOOL" in column_type:
|
||||
return int
|
||||
if column_type == "ANY":
|
||||
return ANY
|
||||
# Default is 'NUMERIC', which we currently also treat as float
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue