mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-02-07 12:50:32 +03:00
Fixed list adaptation.
This commit is contained in:
parent
9577f4e2a6
commit
a9045916f2
|
@ -1,5 +1,8 @@
|
||||||
2006-06-11 Federico Di Gregorio <fog@initd.org>
|
2006-06-11 Federico Di Gregorio <fog@initd.org>
|
||||||
|
|
||||||
|
* Applied patch to adapt an empty list into an empty array
|
||||||
|
and not to NULL (from iGGy, closes: #108).
|
||||||
|
|
||||||
* Applied patch from wkv to avoid under-allocating query
|
* Applied patch from wkv to avoid under-allocating query
|
||||||
space when the parameters are not of the right type
|
space when the parameters are not of the right type
|
||||||
(Closes: #110).
|
(Closes: #110).
|
||||||
|
|
|
@ -46,7 +46,7 @@ list_quote(listObject *self)
|
||||||
|
|
||||||
/* empty arrays are converted to NULLs (still searching for a way to
|
/* empty arrays are converted to NULLs (still searching for a way to
|
||||||
insert an empty array in postgresql */
|
insert an empty array in postgresql */
|
||||||
if (len == 0) return PyString_FromString("NULL");
|
if (len == 0) return PyString_FromString("{}");
|
||||||
|
|
||||||
tmp = PyTuple_New(len);
|
tmp = PyTuple_New(len);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user