MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / _can_create_table

Method _can_create_table

lib/sqlalchemy/sql/ddl.py:924–931  ·  view source on GitHub ↗
(self, table)

Source from the content-addressed store, hash-verified

922 self.memo = {}
923
924 def _can_create_table(self, table):
925 self.dialect.validate_identifier(table.name)
926 effective_schema = self.connection.schema_for_object(table)
927 if effective_schema:
928 self.dialect.validate_identifier(effective_schema)
929 return not self.checkfirst or not self.dialect.has_table(
930 self.connection, table.name, schema=effective_schema
931 )
932
933 def _can_create_index(self, index):
934 effective_schema = self.connection.schema_for_object(index.table)

Callers 2

visit_metadataMethod · 0.95
visit_tableMethod · 0.95

Calls 3

validate_identifierMethod · 0.45
schema_for_objectMethod · 0.45
has_tableMethod · 0.45

Tested by

no test coverage detected