MCPcopy Create free account
hub / github.com/MagicStack/asyncpg / _format_copy_where

Method _format_copy_where

asyncpg/connection.py:1153–1163  ·  view source on GitHub ↗
(self, where)

Source from the content-addressed store, hash-verified

1151 copy_stmt, None, None, records, intro_ps._state, timeout)
1152
1153 def _format_copy_where(self, where):
1154 if where and not self._server_caps.sql_copy_from_where:
1155 raise exceptions.UnsupportedServerFeatureError(
1156 'the `where` parameter requires PostgreSQL 12 or later')
1157
1158 if where:
1159 where_clause = 'WHERE ' + where
1160 else:
1161 where_clause = ''
1162
1163 return where_clause
1164
1165 def _format_copy_opts(self, *, format=None, oids=None, freeze=None,
1166 delimiter=None, null=None, header=None, quote=None,

Callers 2

copy_to_tableMethod · 0.95
copy_records_to_tableMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected