pub enum SqlError {
StatementCount(usize),
UnsupportedStatement,
UnsupportedFeature(&'static str),
UnknownTable(String),
UnknownColumn(String),
AmbiguousColumn(String),
TypeMismatch(String),
QueryTooLarge {
len: usize,
limit: usize,
},
QueryTooComplex {
nodes: usize,
limit: usize,
},
Parse(ParserError),
}Expand description
Errors surfaced by the SQL parsing, lowering, and validation passes.
Variants§
StatementCount(usize)
More than one statement was supplied where exactly one was
expected (subscriptions accept a single SELECT).
UnsupportedStatement
The supplied statement was not a SELECT.
UnsupportedFeature(&'static str)
The supplied query uses a SQL feature outside the v1 surface.
UnknownTable(String)
Referenced table is not in the catalog.
UnknownColumn(String)
Referenced column is not present on the resolved table.
AmbiguousColumn(String)
Column name resolves to multiple sources without a qualifier.
TypeMismatch(String)
Expression failed type-checking against the catalog.
QueryTooLarge
Parser input exceeded the configured byte budget. Surfaces as a 4xx-equivalent on the gRPC wire so a runaway client cannot exhaust the parser by submitting megabyte-scale SQL strings.
QueryTooComplex
Lowered MIR exceeded the configured node-count budget. Same
rationale as QueryTooLarge, but for cases where the SQL itself
is short yet expands (set ops, joins, CTEs) into a large graph.
Parse(ParserError)
Wrapped underlying parser failure.
Trait Implementations§
Source§impl Error for SqlError
impl Error for SqlError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()