diff --git a/awswrangler/mysql.py b/awswrangler/mysql.py index 898e78d3b..77c8a0268 100644 --- a/awswrangler/mysql.py +++ b/awswrangler/mysql.py @@ -168,7 +168,7 @@ def connect( attrs: _db_utils.ConnectionAttributes = _db_utils.get_connection_attributes( connection=connection, secret_id=secret_id, catalog_id=catalog_id, dbname=dbname, boto3_session=boto3_session ) - if attrs.kind != "mysql": + if attrs.kind not in ("mysql", "aurora-mysql"): raise exceptions.InvalidDatabaseType(f"Invalid connection type ({attrs.kind}. It must be a MySQL connection.)") return pymysql.connect( user=attrs.user, diff --git a/awswrangler/postgresql.py b/awswrangler/postgresql.py index 2715220cd..3561bbc15 100644 --- a/awswrangler/postgresql.py +++ b/awswrangler/postgresql.py @@ -225,7 +225,7 @@ def connect( attrs: _db_utils.ConnectionAttributes = _db_utils.get_connection_attributes( connection=connection, secret_id=secret_id, catalog_id=catalog_id, dbname=dbname, boto3_session=boto3_session ) - if attrs.kind not in ("postgresql", "postgres"): + if attrs.kind not in ("postgresql", "postgres", "aurora-postgresql"): raise exceptions.InvalidDatabaseType( f"Invalid connection type ({attrs.kind}. It must be a postgresql connection.)" )