From cf22e65f19e007ce8a76768c9c5857c0996ab054 Mon Sep 17 00:00:00 2001 From: kannes Date: Wed, 16 Jan 2019 16:01:03 +0100 Subject: [PATCH] add executemany example with multiple parameters --- doc/src/cursor.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/src/cursor.rst b/doc/src/cursor.rst index e0580c76..f0d3bcd6 100644 --- a/doc/src/cursor.rst +++ b/doc/src/cursor.rst @@ -200,6 +200,9 @@ The ``cursor`` class >>> nums = [[1],[5],[10]] >>> cur.executemany("INSERT INTO test (num) VALUES (%s)", nums) + + >>> tuples = ((123,"foo"), (42,"bar"), (23,"baz")) + >>> cur.executemany("INSERT INTO test (num, data) VALUES (%s, %s)", tuples) .. warning:: In its current implementation this method is not faster than