MCPcopy Index your code
hub / github.com/MagicStack/asyncpg / executemany

Method executemany

asyncpg/prepared_stmt.py:236–252  ·  view source on GitHub ↗

Execute the statement for each sequence of arguments in *args*. :param args: An iterable containing sequences of arguments. :param float timeout: Optional timeout value in seconds. :return None: This method discards the results of the operations. .. versionadded:: 0

(self, args, *, timeout: typing.Optional[float]=None)

Source from the content-addressed store, hash-verified

234
235 @connresource.guarded
236 async def executemany(self, args, *, timeout: typing.Optional[float]=None):
237 """Execute the statement for each sequence of arguments in *args*.
238
239 :param args: An iterable containing sequences of arguments.
240 :param float timeout: Optional timeout value in seconds.
241 :return None: This method discards the results of the operations.
242
243 .. versionadded:: 0.22.0
244 """
245 return await self.__do_execute(
246 lambda protocol: protocol.bind_execute_many(
247 self._state,
248 args,
249 portal_name='',
250 timeout=timeout,
251 return_rows=False,
252 ))
253
254 async def __do_execute(self, executor):
255 protocol = self._connection._protocol

Callers

nothing calls this directly

Calls 1

__do_executeMethod · 0.95

Tested by

no test coverage detected