mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-02-07 12:50:32 +03:00
.executemany() fix (closes: #116).
This commit is contained in:
parent
ba1e5389c8
commit
23112a763d
|
@ -1,5 +1,8 @@
|
||||||
2006-09-01 Federico Di Gregorio <fog@initd.org>
|
2006-09-01 Federico Di Gregorio <fog@initd.org>
|
||||||
|
|
||||||
|
* psycopg/cursor_type.c: applied patch from intgr (#116) to
|
||||||
|
fix bad keyword naming and segfault in .executemany().
|
||||||
|
|
||||||
* ZPsycopgDA/DA.py: applied ImageFile patch from Charlie
|
* ZPsycopgDA/DA.py: applied ImageFile patch from Charlie
|
||||||
Clark.
|
Clark.
|
||||||
|
|
||||||
|
|
|
@ -434,7 +434,7 @@ psyco_curs_execute(cursorObject *self, PyObject *args, PyObject *kwargs)
|
||||||
}
|
}
|
||||||
|
|
||||||
#define psyco_curs_executemany_doc \
|
#define psyco_curs_executemany_doc \
|
||||||
"executemany(query, vars_list=(), async=0) -- Execute many queries with bound vars."
|
"executemany(query, vars_list) -- Execute many queries with bound vars."
|
||||||
|
|
||||||
static PyObject *
|
static PyObject *
|
||||||
psyco_curs_executemany(cursorObject *self, PyObject *args, PyObject *kwargs)
|
psyco_curs_executemany(cursorObject *self, PyObject *args, PyObject *kwargs)
|
||||||
|
@ -442,9 +442,9 @@ psyco_curs_executemany(cursorObject *self, PyObject *args, PyObject *kwargs)
|
||||||
PyObject *operation = NULL, *vars = NULL;
|
PyObject *operation = NULL, *vars = NULL;
|
||||||
PyObject *v, *iter = NULL;
|
PyObject *v, *iter = NULL;
|
||||||
|
|
||||||
static char *kwlist[] = {"query", "vars", NULL};
|
static char *kwlist[] = {"query", "vars_list", NULL};
|
||||||
|
|
||||||
if (!PyArg_ParseTupleAndKeywords(args, kwargs, "O|O", kwlist,
|
if (!PyArg_ParseTupleAndKeywords(args, kwargs, "OO", kwlist,
|
||||||
&operation, &vars)) {
|
&operation, &vars)) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user