File tree Expand file tree Collapse file tree 1 file changed +3
-9
lines changed
Expand file tree Collapse file tree 1 file changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -356,16 +356,10 @@ def drop_relation(self, relation: BaseRelation) -> None:
356356 self .engine_adapter .drop_table (self ._normalize (self ._relation_to_table (relation )))
357357
358358 def rename_relation (self , from_relation : BaseRelation , to_relation : BaseRelation ) -> None :
359- old_table_name = None
360- if from_relation .schema is not None and from_relation .identifier is not None :
361- old_table_name = self ._normalize (self ._relation_to_table (from_relation ))
359+ old_table_name = self ._normalize (self ._relation_to_table (from_relation ))
360+ new_table_name = self ._normalize (self ._relation_to_table (to_relation ))
362361
363- new_table_name = None
364- if to_relation .schema is not None and to_relation .identifier is not None :
365- new_table_name = self ._normalize (self ._relation_to_table (to_relation ))
366-
367- if old_table_name and new_table_name :
368- self .engine_adapter .rename_table (old_table_name , new_table_name )
362+ self .engine_adapter .rename_table (old_table_name , new_table_name )
369363
370364 def execute (
371365 self , sql : str , auto_begin : bool = False , fetch : bool = False
You can’t perform that action at this time.
0 commit comments