Beispiel #1
0
 def _has_view(
     cls,
     conn: Connection,
     dialect: Dialect,
     view_name: str,
     schema: Optional[str] = None,
 ) -> bool:
     view_names: List[str] = []
     try:
         view_names = dialect.get_view_names(connection=conn, schema=schema)
     except Exception as ex:  # pylint: disable=broad-except
         logger.warning(ex)
     return view_name in view_names
Beispiel #2
0
 def load_dialect_impl(self, dialect: Dialect):
     if dialect.name == "mysql":
         return dialect.type_descriptor(mysql.BIGINT(unsigned=True))
     return self.impl
Beispiel #3
0
 def load_dialect_impl(self, dialect: Dialect) -> Any:
     if dialect.name == "postgresql":
         return dialect.type_descriptor(PostgresUUID())
     else:
         return dialect.type_descriptor(CHAR(32))