From 2d9abb06614bacf48cd8815094ac0717dccf30f7 Mon Sep 17 00:00:00 2001 From: Beto Dealmeida Date: Tue, 21 Mar 2023 11:46:51 -0700 Subject: [PATCH] Remove ondelete --- superset/connectors/sqla/models.py | 2 +- superset/models/slice.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/superset/connectors/sqla/models.py b/superset/connectors/sqla/models.py index 36aa5e4fe0e08..b76e423caf441 100644 --- a/superset/connectors/sqla/models.py +++ b/superset/connectors/sqla/models.py @@ -520,7 +520,7 @@ def data(self) -> Dict[str, Any]: metadata, Column("id", Integer, primary_key=True), Column("user_id", Integer, ForeignKey("ab_user.id")), - Column("table_id", Integer, ForeignKey("tables.id", ondelete="CASCADE")), + Column("table_id", Integer, ForeignKey("tables.id")), ) diff --git a/superset/models/slice.py b/superset/models/slice.py index 12e9ac404e4b4..9ab4039a93d52 100644 --- a/superset/models/slice.py +++ b/superset/models/slice.py @@ -59,7 +59,7 @@ metadata, Column("id", Integer, primary_key=True), Column("user_id", Integer, ForeignKey("ab_user.id")), - Column("slice_id", Integer, ForeignKey("slices.id", ondelete="CASCADE")), + Column("slice_id", Integer, ForeignKey("slices.id")), ) logger = logging.getLogger(__name__)