diff options
| author | Daniele Varrazzo <daniele.varrazzo@gmail.com> | 2017-02-03 04:56:02 +0000 |
|---|---|---|
| committer | Daniele Varrazzo <daniele.varrazzo@gmail.com> | 2017-02-03 04:56:02 +0000 |
| commit | de8b335d80ecba0305e2b4796373a4064fd450b3 (patch) | |
| tree | 26a5fab1a9f022adda5d5ad2de78b816fe0350e1 /doc/src/cursor.rst | |
| parent | a8a3a298f8ade3b0430ff2df0a5d5ee1fe920e3d (diff) | |
| parent | ca42306d7916647448184907e03c77ff54ebd4f9 (diff) | |
| download | psycopg2-sql-compose.tar.gz | |
Merge branch 'master' into sql-composesql-compose
Diffstat (limited to 'doc/src/cursor.rst')
| -rw-r--r-- | doc/src/cursor.rst | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/doc/src/cursor.rst b/doc/src/cursor.rst index aee6b46..4161f2a 100644 --- a/doc/src/cursor.rst +++ b/doc/src/cursor.rst @@ -172,33 +172,38 @@ The ``cursor`` class .. method:: execute(operation [, parameters]) - + Prepare and execute a database operation (query or command). Parameters may be provided as sequence or mapping and will be bound to variables in the operation. Variables are specified either with positional (``%s``) or named (:samp:`%({name})s`) placeholders. See :ref:`query-parameters`. - + The method returns `!None`. If a query was executed, the returned values can be retrieved using |fetch*|_ methods. .. method:: executemany(operation, seq_of_parameters) - + Prepare a database operation (query or command) and then execute it against all parameter tuples or mappings found in the sequence `seq_of_parameters`. - + The function is mostly useful for commands that update the database: any result set returned by the query is discarded. - + Parameters are bounded to the query using the same rules described in the `~cursor.execute()` method. + .. warning:: + In its current implementation this method is not faster than + executing `~cursor.execute()` in a loop. For better performance + you can use the functions described in :ref:`fast-exec`. + .. method:: callproc(procname [, parameters]) - + Call a stored database procedure with the given name. The sequence of parameters must contain one entry for each argument that the procedure expects. Overloaded procedures are supported. Named parameters can be |
