pub enum AlterTypeAction<'a> {
OwnerTo {
owner_to_span: Span,
new_owner: AlterTableOwner<'a>,
},
RenameTo {
rename_to_span: Span,
new_name: Identifier<'a>,
},
SetSchema {
set_schema_span: Span,
new_schema: QualifiedName<'a>,
},
RenameAttribute {
rename_attribute_span: Span,
attribute_name: Identifier<'a>,
to_span: Span,
new_attribute_name: Identifier<'a>,
cascade_or_restrict: Option<CascadeOrRestrict>,
},
AddValue {
add_value_span: Span,
if_not_exists_span: Option<Span>,
new_enum_value: SString<'a>,
placement: Option<(Span, SString<'a>)>,
},
RenameValue {
rename_value_span: Span,
existing_enum_value: SString<'a>,
to_span: Span,
new_enum_value: SString<'a>,
},
Attributes {
items: Vec<AttributeAction<'a>>,
},
SetProperties {
set_span: Span,
properties: Vec<(Identifier<'a>, Expression<'a>)>,
},
}Expand description
ALTER TYPE actions
Variants§
OwnerTo
OWNER TO new_owner
RenameTo
RENAME TO new_name
SetSchema
SET SCHEMA new_schema
RenameAttribute
RENAME ATTRIBUTE attribute_name TO new_attribute_name [ CASCADE | RESTRICT ]
Fields
§
attribute_name: Identifier<'a>§
new_attribute_name: Identifier<'a>§
cascade_or_restrict: Option<CascadeOrRestrict>AddValue
ADD VALUE [ IF NOT EXISTS ] new_enum_value [ { BEFORE | AFTER } neighbor_enum_value ]
Fields
RenameValue
RENAME VALUE existing_enum_value TO new_enum_value
Fields
Attributes
ADD ATTRIBUTE attribute_name data_type [ COLLATE collation ] [ CASCADE | RESTRICT ] DROP ATTRIBUTE [ IF EXISTS ] attribute_name [ CASCADE | RESTRICT ] ALTER ATTRIBUTE attribute_name [ SET DATA ] TYPE data_type [ COLLATE collation ] [ CASCADE | RESTRICT ]
Fields
§
items: Vec<AttributeAction<'a>>SetProperties
SET ( property = value [, … ] )
Trait Implementations§
Source§impl<'a> Clone for AlterTypeAction<'a>
impl<'a> Clone for AlterTypeAction<'a>
Source§fn clone(&self) -> AlterTypeAction<'a>
fn clone(&self) -> AlterTypeAction<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for AlterTypeAction<'a>
impl<'a> Debug for AlterTypeAction<'a>
Auto Trait Implementations§
impl<'a> Freeze for AlterTypeAction<'a>
impl<'a> RefUnwindSafe for AlterTypeAction<'a>
impl<'a> Send for AlterTypeAction<'a>
impl<'a> Sync for AlterTypeAction<'a>
impl<'a> Unpin for AlterTypeAction<'a>
impl<'a> UnsafeUnpin for AlterTypeAction<'a>
impl<'a> UnwindSafe for AlterTypeAction<'a>
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