mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-02-12 07:10:33 +03:00
Little improvements to DictRow.
This commit is contained in:
parent
48d8bd39a1
commit
10dc03462b
|
@ -23,6 +23,8 @@
|
||||||
|
|
||||||
2005-03-29 Federico Di Gregorio <fog@debian.org>
|
2005-03-29 Federico Di Gregorio <fog@debian.org>
|
||||||
|
|
||||||
|
* Applied patch to fix tuple count.
|
||||||
|
|
||||||
* psycopg/pqpath.c (pq_is_busy): Staring from bug report from
|
* psycopg/pqpath.c (pq_is_busy): Staring from bug report from
|
||||||
Jason Erickson fixed segfaults due to calling Python function
|
Jason Erickson fixed segfaults due to calling Python function
|
||||||
without holding the GIL.
|
without holding the GIL.
|
||||||
|
|
|
@ -70,6 +70,12 @@ class DictRow(list):
|
||||||
x = self._cursor.index[x]
|
x = self._cursor.index[x]
|
||||||
return list.__getitem__(self, x)
|
return list.__getitem__(self, x)
|
||||||
|
|
||||||
|
def items(self):
|
||||||
|
res = []
|
||||||
|
for n, v in self._cursor.index.items():
|
||||||
|
res.append((n, list.__getitem__(self, v)))
|
||||||
|
return res
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class SQL_IN(object):
|
class SQL_IN(object):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user