diff --git a/sandbox/grist/table.py b/sandbox/grist/table.py index 975da063..ceca65fd 100644 --- a/sandbox/grist/table.py +++ b/sandbox/grist/table.py @@ -342,8 +342,9 @@ class Table(object): _updateSummary.is_private = True col_id = summary_table._summary_helper_col_id if self.has_column(col_id): - # Column type may have changed, replace completely - self.delete_column(self.get_column(col_id)) + # If type changed between Reference/ReferenceList, replace completely. + if type(self.get_column(col_id).type_obj) != type(_updateSummary.grist_type): + self.delete_column(self.get_column(col_id)) col_obj = self._create_or_update_col(col_id, _updateSummary) self._special_cols[col_id] = col_obj self.all_columns[col_id] = col_obj