pub enum AlterTableOperation<'until_build, 'post_build> {
RenameTo {
name: String,
},
RenameColumnTo {
column_name: String,
new_column_name: String,
},
AddColumn {
operation: CreateColumnImpl<'until_build, 'post_build>,
},
DropColumn {
name: String,
},
AlterColumn {
name: &'until_build str,
operation: AlterColumnOperation,
},
}Expand description
Representation of operations to execute in the context of an ALTER TABLE statement.
Variants§
RenameTo
Use this operation to rename a table
RenameColumnTo
Use this operation to rename a column within a table
AddColumn
Use this operation to add a column to an existing table.
Fields
§
operation: CreateColumnImpl<'until_build, 'post_build>Operation to use for adding the column
DropColumn
Use this operation to drop an existing column.
AlterColumn
Use this operation to change an existing column in place, preserving its data.
Which change to make is decided by the caller: this operation renders the single statement it is given and nothing else.
Fields
§
operation: AlterColumnOperationThe change to apply to it
Trait Implementations§
Auto Trait Implementations§
impl<'until_build, 'post_build> !UnwindSafe for AlterTableOperation<'until_build, 'post_build>
impl<'until_build, 'post_build> Freeze for AlterTableOperation<'until_build, 'post_build>
impl<'until_build, 'post_build> RefUnwindSafe for AlterTableOperation<'until_build, 'post_build>
impl<'until_build, 'post_build> Send for AlterTableOperation<'until_build, 'post_build>
impl<'until_build, 'post_build> Sync for AlterTableOperation<'until_build, 'post_build>
impl<'until_build, 'post_build> Unpin for AlterTableOperation<'until_build, 'post_build>
impl<'until_build, 'post_build> UnsafeUnpin for AlterTableOperation<'until_build, 'post_build>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more