Rename Column

table = self._hc.get_table(tbl_name = self._table_name, database_name = self._database_name)  
fields_renaming = [  
    {"old_column_name_1": "new_column_name_1"},  
    {"old_column_name_2": "new_column_name_2"}  
result = table.rename_columns(fields_renaming = fields_renaming)  


This method will a Boolean value to represent whether this operation is successful. If the error pops up when renaming columns, “ValueError” exception will be raised.

Parameter description:

column_names (list)Field list to be renamedYes

Table 90 Rename Column (Python API)