mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-06-22 14:03:04 +03:00
Fixed precision and scale.
This commit is contained in:
parent
bfe5b8fe6b
commit
ac5a747e95
|
@ -561,7 +561,7 @@ _pq_fetch_tuples(cursorObject *curs)
|
||||||
/* 4,5/ scale and precision */
|
/* 4,5/ scale and precision */
|
||||||
if (ftype == NUMERICOID) {
|
if (ftype == NUMERICOID) {
|
||||||
PyTuple_SET_ITEM(dtitem, 4, PyInt_FromLong((fmod >> 16) & 0xFFFF));
|
PyTuple_SET_ITEM(dtitem, 4, PyInt_FromLong((fmod >> 16) & 0xFFFF));
|
||||||
PyTuple_SET_ITEM(dtitem, 5, PyInt_FromLong((fmod & 0xFFFF) - 4));
|
PyTuple_SET_ITEM(dtitem, 5, PyInt_FromLong(fmod & 0xFFFF));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Py_INCREF(Py_None);
|
Py_INCREF(Py_None);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user