pub enum Error {
Show 67 variants
DataType {
data_type: Box<DataType>,
},
ColumnOption {
option: Box<ColumnOption>,
},
OnDeleteConstrait {
referential_action: ReferentialAction,
},
PrimaryKey {
reason: &'static str,
},
PrimaryKeyWithExpression {
expr: Box<Expr>,
},
ForeignKey {
reason: &'static str,
},
TableConstraint {
constraint: Box<TableConstraint>,
},
CompoundIdentifier {
length: usize,
},
SelectionValue {
value: Box<Value>,
},
SelectionInList {
selection: Box<Selection>,
},
SelectionFromExpr {
expr: Box<Expr>,
},
InsertSourceExpression {
expr: Box<Expr>,
},
InsertSourceValue {
value: Box<Value>,
},
UpdateExpression {
expr: Box<Expr>,
},
UpdateValue {
value: Box<Value>,
},
BinaryOperator {
op: BinaryOperator,
},
Keyword {
keyword: &'static str,
},
JoinConstraint {
constraint: Box<JoinConstraint>,
},
JoinOperator {
op: Box<JoinOperator>,
},
TableAlias,
TableValuedFunctions,
TableWithHints,
TableVersioning,
TableWithOrdinality,
TableWithPartitions,
TableWithJsonPath,
TableWithSampleModifier,
TableWithIndexHints,
TableFactor {
factor: Box<TableFactor>,
},
TableJoins {
table_joins: Vec<TableWithJoins>,
},
Drop {
reason: &'static str,
object_type: Option<ObjectType>,
},
AlterTable {
reason: &'static str,
},
AlterTableOp {
op: Box<AlterTableOperation>,
},
ObjectName {
reason: &'static str,
},
CreateTable {
reason: &'static str,
},
FunctionArguments {
reason: &'static str,
arguments: Box<FunctionArguments>,
},
FunctionArgument {
reason: &'static str,
argument: Box<FunctionArg>,
},
CreateIndex {
reason: &'static str,
},
CreateIndexColumn {
column: Box<IndexColumn>,
},
CTE,
Fetch,
Limit,
Locks,
For,
Select {
set_expr: Box<SetExpr>,
},
Top,
EmptyProjections,
Count {
reason: &'static str,
args: Vec<FunctionArg>,
},
Function {
name: String,
},
Projection {
select_item: Box<SelectItem>,
},
OrderBy {
reason: &'static str,
},
GroupBy {
reason: &'static str,
},
Insert {
reason: &'static str,
},
InsertSourceEmpty,
InsertTableObject,
InsertSource {
set_expr: Box<SetExpr>,
},
Update {
reason: &'static str,
},
UpdateTableType {
table_factor: Box<TableFactor>,
},
UpdateAssignmentTarget {
target: Box<AssignmentTarget>,
},
Delete {
reason: &'static str,
},
DeleteToSql {
reason: &'static str,
},
DropIndex {
reason: &'static str,
},
Statement {
statement: Box<Statement>,
},
Serial,
Io(Error),
Parser(ParserError),
Utf8(FromUtf8Error),
}Variants§
DataType
ColumnOption
Fields
§
option: Box<ColumnOption>OnDeleteConstrait
Fields
§
referential_action: ReferentialActionPrimaryKey
PrimaryKeyWithExpression
ForeignKey
TableConstraint
Fields
§
constraint: Box<TableConstraint>CompoundIdentifier
SelectionValue
SelectionInList
SelectionFromExpr
InsertSourceExpression
InsertSourceValue
UpdateExpression
UpdateValue
BinaryOperator
Fields
§
op: BinaryOperatorKeyword
JoinConstraint
Fields
§
constraint: Box<JoinConstraint>JoinOperator
Fields
§
op: Box<JoinOperator>TableAlias
TableValuedFunctions
Postgre + MSSQL
TableWithHints
MSSQL-specific WITH (...) hints such as NOLOCK.
TableVersioning
Table time-travel, as supported by BigQuery and MSSQL.
TableWithOrdinality
Postgres.
TableWithPartitions
Mysql
TableWithJsonPath
Optional PartiQL JsonPath: https://partiql.org/dql/from.html
TableWithSampleModifier
Optional table sample modifier See: https://jakewheat.github.io/sql-overview/sql-2016-foundation-grammar.html#sample-clause
TableWithIndexHints
Optional index hints(mysql) See: https://dev.mysql.com/doc/refman/8.4/en/index-hints.html
TableFactor
Fields
§
factor: Box<TableFactor>TableJoins
Fields
§
table_joins: Vec<TableWithJoins>Drop
AlterTable
AlterTableOp
Fields
§
op: Box<AlterTableOperation>ObjectName
CreateTable
FunctionArguments
FunctionArgument
CreateIndex
CreateIndexColumn
Fields
§
column: Box<IndexColumn>CTE
Fetch
Limit
Locks
For
Select
Top
EmptyProjections
Count
Function
Projection
Fields
§
select_item: Box<SelectItem>OrderBy
GroupBy
Insert
InsertSourceEmpty
InsertTableObject
InsertSource
Update
UpdateTableType
Fields
§
table_factor: Box<TableFactor>UpdateAssignmentTarget
Fields
§
target: Box<AssignmentTarget>Delete
DeleteToSql
DropIndex
Statement
Serial
Io(Error)
Parser(ParserError)
Utf8(FromUtf8Error)
Trait Implementations§
Source§impl Error for Error
impl Error for Error
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<FromUtf8Error> for Error
impl From<FromUtf8Error> for Error
Source§fn from(err: FromUtf8Error) -> Self
fn from(err: FromUtf8Error) -> Self
Converts to this type from the input type.
Source§impl From<ParserError> for Error
impl From<ParserError> for Error
Source§fn from(err: ParserError) -> Self
fn from(err: ParserError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Error
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
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