def _make_match_kwargs(self, schema, identifier): quoting = self.config.quoting if identifier is not None and quoting['identifier'] is False: identifier = identifier.lower() if schema is not None and quoting['schema'] is False: schema = schema.lower() return filter_null_values({'identifier': identifier, 'schema': schema})
def check_schema_exists(self, database, schema, model_name=None): """Check if a schema exists. The default implementation of this is potentially unnecessarily slow, and adapters should implement it if there is an optimized path (and there probably is) """ search = (s.lower() for s in self.list_schemas(database=database, model_name=model_name)) return schema.lower() in search
def _make_match_kwargs(cls, project_cfg, schema, identifier): if identifier is not None and \ project_cfg.get('quoting', {}).get('identifier') is False: identifier = identifier.lower() if schema is not None and \ project_cfg.get('quoting', {}).get('schema') is False: schema = schema.lower() return filter_null_values({'identifier': identifier, 'schema': schema})
def check_schema_exists(self, database, schema, model_name=None): """Check if a schema exists. The default implementation of this is potentially unnecessarily slow, and adapters should implement it if there is an optimized path (and there probably is) """ search = ( s.lower() for s in self.list_schemas(database=database, model_name=model_name) ) return schema.lower() in search
def _make_match_kwargs(self, database, schema, identifier): quoting = self.config.quoting if identifier is not None and quoting['identifier'] is False: identifier = identifier.lower() if schema is not None and quoting['schema'] is False: schema = schema.lower() if database is not None and quoting['schema'] is False: database = database.lower() return filter_null_values({ 'database': database, 'identifier': identifier, 'schema': schema, })