pub struct Insert {Show 16 fields
pub or: Option<SqliteOnConflict>,
pub ignore: bool,
pub into: bool,
pub table_name: ObjectName,
pub table_alias: Option<Ident>,
pub columns: Vec<Ident>,
pub overwrite: bool,
pub source: Option<Box<Query>>,
pub partitioned: Option<Vec<Expr>>,
pub after_columns: Vec<Ident>,
pub table: bool,
pub on: Option<OnInsert>,
pub returning: Option<Vec<SelectItem>>,
pub replace_into: bool,
pub priority: Option<MysqlInsertPriority>,
pub insert_alias: Option<InsertAliases>,
}
Expand description
INSERT statement.
Fields§
§or: Option<SqliteOnConflict>
Only for Sqlite
ignore: bool
Only for mysql
into: bool
INTO - optional keyword
table_name: ObjectName
TABLE
table_alias: Option<Ident>
table_name as foo (for PostgreSQL)
columns: Vec<Ident>
COLUMNS
overwrite: bool
Overwrite (Hive)
source: Option<Box<Query>>
A SQL query that specifies what to insert
partitioned: Option<Vec<Expr>>
partitioned insert (Hive)
after_columns: Vec<Ident>
Columns defined after PARTITION
table: bool
whether the insert has the table keyword (Hive)
on: Option<OnInsert>
§returning: Option<Vec<SelectItem>>
RETURNING
replace_into: bool
Only for mysql
priority: Option<MysqlInsertPriority>
Only for mysql
insert_alias: Option<InsertAliases>
Only for mysql
Trait Implementations§
source§impl<'de> Deserialize<'de> for Insert
impl<'de> Deserialize<'de> for Insert
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for Insert
impl Ord for Insert
source§impl PartialEq for Insert
impl PartialEq for Insert
source§impl PartialOrd for Insert
impl PartialOrd for Insert
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl VisitMut for Insert
impl VisitMut for Insert
fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
impl Eq for Insert
impl StructuralPartialEq for Insert
Auto Trait Implementations§
impl Freeze for Insert
impl RefUnwindSafe for Insert
impl Send for Insert
impl Sync for Insert
impl Unpin for Insert
impl UnwindSafe for Insert
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