risingwave_meta::controller::rename

Function alter_relation_rename

source
pub fn alter_relation_rename(definition: &str, new_name: &str) -> String
Expand description

alter_relation_rename renames a relation to a new name in its Create statement, and returns the updated definition raw sql. Note that the definition must be a Create statement and the new_name must be a valid identifier, it should be validated before calling this function. To update all relations that depend on the renamed one, use alter_relation_rename_refs.