Open EDRossi opened 2 years ago
i tryed to use bigint ending with the same result
This is btw not just some ORM problem. I've just run into the same problem with raw SQL and had to transform the numbers into strings first:
File "/Users/hynek/Work/mailbox-usage-svc/src/mailbox_usage_svc/adapters/repositories.py", line 70, in update_mailbox
self.cursor.execute(
File "/Users/hynek/Work/mailbox-usage-svc/.venv/lib/python3.12/site-packages/sqlanydb.py", line 840, in execute
self.executemany(operation, [parameters])
File "/Users/hynek/Work/mailbox-usage-svc/.venv/lib/python3.12/site-packages/sqlanydb.py", line 814, in executemany
parms = [bind(k, col)
^^^^^^^^^^^^
File "/Users/hynek/Work/mailbox-usage-svc/.venv/lib/python3.12/site-packages/sqlanydb.py", line 803, in bind
(self.assign)(param, col)
File "/Users/hynek/Work/mailbox-usage-svc/.venv/lib/python3.12/site-packages/sqlanydb.py", line 437, in assign
buffer = create_string_buffer(pack(fmt, value))
^^^^^^^^^^^^^^^^^
struct.error: 'i' format requires -2147483648 <= number <= 2147483647
The type of the field is bigint
.
@DanCummins-SAP any chance of this being addressed? Not being able to insert big numbers into a database is kinda big deal.
@DanCummins-SAP any chance of this being addressed? Not being able to insert big numbers into a database is kinda big deal.
Hi Hynek, Thanks for the report, we have added it to our backlog. Dan
This is fixed in 1.0.14.
trying to use a Numeric(11) the package fail when trying to pack
sqlanydb.py line 430
i am using flask and sqlalchemy