From d17a4f6a6fc91254155aa3330a3efe85cb2a7be8 Mon Sep 17 00:00:00 2001 From: galogm Date: Wed, 10 Sep 2025 18:37:49 +0800 Subject: [PATCH] fix: unable to connect table_1.column_1 (category dtype) to table_2.column_2 (primary_key dtype) --- models/autog/action.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/autog/action.py b/models/autog/action.py index 3e3f85b..37e2a87 100644 --- a/models/autog/action.py +++ b/models/autog/action.py @@ -277,7 +277,7 @@ def connect_two_columns(dbb, table_1_name, table_1_col_name, table_2_name, table # import ipdb; ipdb.set_trace() if type_of_col1 == 'foreign_key' and type_of_col2 == 'foreign_key' and columninfo_dict[f'{table_1_name}.{table_1_col_name}'].link_to == columninfo_dict[f'{table_2_name}.{table_2_col_name}'].link_to: return dbb - if type_of_col1 != type_of_col2: + if type_of_col1 != type_of_col2 and type_of_col2 not in ['primary_key', 'foreign_key']: return dbb ## two non key types with the same type