diff --git a/src/meta/api/src/txn_backoff.rs b/src/meta/api/src/txn_backoff.rs index 95e33284a50d..ecc636ff72b7 100644 --- a/src/meta/api/src/txn_backoff.rs +++ b/src/meta/api/src/txn_backoff.rs @@ -155,7 +155,7 @@ mod tests { let elapsed = now.elapsed().as_secs_f64(); println!("elapsed: {elapsed}"); assert!( - (0.041..0.080).contains(&elapsed), + (0.041..0.090).contains(&elapsed), "{} is expected to be 2 + 5 + 10 + 14 + 20 milliseconds", elapsed ); diff --git a/src/query/ast/src/ast/common.rs b/src/query/ast/src/ast/common.rs index a0d7a527d868..e9ce8ebc5d87 100644 --- a/src/query/ast/src/ast/common.rs +++ b/src/query/ast/src/ast/common.rs @@ -29,7 +29,16 @@ pub struct Identifier { pub span: Span, pub name: String, pub quote: Option, - pub is_hole: bool, + #[drive(skip)] + pub ident_type: IdentifierType, +} + +#[derive(Debug, Copy, Clone, PartialEq, Eq, Default)] +pub enum IdentifierType { + #[default] + None, + Hole, + Variable, } impl Identifier { @@ -37,12 +46,20 @@ impl Identifier { self.quote.is_some() } + pub fn is_hole(&self) -> bool { + self.ident_type == IdentifierType::Hole + } + + pub fn is_variable(&self) -> bool { + self.ident_type == IdentifierType::Variable + } + pub fn from_name(span: Span, name: impl Into) -> Self { Self { span, name: name.into(), quote: None, - is_hole: false, + ident_type: IdentifierType::None, } } @@ -51,15 +68,17 @@ impl Identifier { span, name: name.into(), quote, - is_hole: false, + ident_type: IdentifierType::None, } } } impl Display for Identifier { fn fmt(&self, f: &mut Formatter) -> std::fmt::Result { - if self.is_hole { + if self.is_hole() { write!(f, "IDENTIFIER(:{})", self.name) + } else if self.is_variable() { + write!(f, "IDENTIFIER(${})", self.name) } else if let Some(quote) = self.quote { write!(f, "{}", QuotedIdent(&self.name, quote)) } else { diff --git a/src/query/ast/src/parser/common.rs b/src/query/ast/src/parser/common.rs index 93bb6bf407ec..7ca81fa5643f 100644 --- a/src/query/ast/src/parser/common.rs +++ b/src/query/ast/src/parser/common.rs @@ -27,6 +27,7 @@ use crate::ast::quote::QuotedIdent; use crate::ast::ColumnID; use crate::ast::DatabaseRef; use crate::ast::Identifier; +use crate::ast::IdentifierType; use crate::ast::SetType; use crate::ast::TableRef; use crate::parser::input::Input; @@ -127,7 +128,7 @@ fn plain_identifier( span: transform_span(&[token.clone()]), name: token.text().to_string(), quote: None, - is_hole: false, + ident_type: IdentifierType::None, }, )(i) } @@ -152,7 +153,7 @@ fn quoted_identifier(i: Input) -> IResult { span: transform_span(&[token.clone()]), name: ident, quote: Some(quote), - is_hole: false, + ident_type: IdentifierType::None, })) } else { Err(nom::Err::Error(Error::from_error_kind( @@ -166,17 +167,31 @@ fn quoted_identifier(i: Input) -> IResult { fn identifier_hole(i: Input) -> IResult { check_template_mode(map( consumed(rule! { - IDENTIFIER ~ ^"(" ~ ^#template_hole ~ ^")" + IDENTIFIER ~ ^"(" ~ #template_hole ~ ^")" }), - |(span, (_, _, (_, name), _))| Identifier { + |(span, (_, _, name, _))| Identifier { span: transform_span(span.tokens), name, quote: None, - is_hole: true, + ident_type: IdentifierType::Hole, }, ))(i) } +fn identifier_variable(i: Input) -> IResult { + map( + consumed(rule! { + IDENTIFIER ~ ^"(" ~ ^#variable_ident ~ ^")" + }), + |(span, (_, _, name, _))| Identifier { + span: transform_span(span.tokens), + name, + quote: None, + ident_type: IdentifierType::Variable, + }, + )(i) +} + fn non_reserved_identifier( is_reserved_keyword: fn(&TokenKind) -> bool, ) -> impl FnMut(Input) -> IResult { @@ -185,6 +200,7 @@ fn non_reserved_identifier( #plain_identifier(is_reserved_keyword) | #quoted_identifier | #identifier_hole + | #identifier_variable )(i) } } @@ -277,11 +293,11 @@ pub fn column_id(i: Input) -> IResult { ))(i) } -pub fn variable_ident(i: Input) -> IResult { - map(rule! { VariableAccess }, |token| { - let name = token.text().to_string(); - Identifier::from_name(Some(token.span), &name[1..]) - })(i) +pub fn variable_ident(i: Input) -> IResult { + map( + rule! { "$" ~ ^#plain_identifier(|token| token.is_reserved_ident(false)) }, + |(_, name)| name.name, + )(i) } /// Parse one to two idents separated by a dot, fulfilling from the right. @@ -564,12 +580,12 @@ where F: nom::Parser, O, Error<'a>> { } } -pub fn template_hole(i: Input) -> IResult<(Span, String)> { +pub fn template_hole(i: Input) -> IResult { check_template_mode(map( - consumed(rule! { + rule! { ":" ~ ^#plain_identifier(|token| token.is_reserved_ident(false)) - }), - |(span, (_, ident))| (transform_span(span.tokens), ident.name), + }, + |(_, name)| name.name, ))(i) } diff --git a/src/query/ast/src/parser/expr.rs b/src/query/ast/src/parser/expr.rs index 583077ef752d..a106ee40c9fa 100644 --- a/src/query/ast/src/parser/expr.rs +++ b/src/query/ast/src/parser/expr.rs @@ -104,7 +104,7 @@ pub fn subexpr(min_precedence: u32) -> impl FnMut(Input) -> IResult { ExprElement::MapAccess { accessor: MapAccessor::Colon { key }, } => { - if !key.is_quoted() && !key.is_hole { + if !key.is_quoted() && !key.is_hole() { *elem = ExprElement::Hole { name: key.to_string(), }; @@ -182,7 +182,7 @@ pub enum ExprElement { UnaryOp { op: UnaryOperator, }, - VariableAccess(Identifier), + VariableAccess(String), /// `CAST` expression, like `CAST(expr AS target_type)` Cast { expr: Box, @@ -650,7 +650,7 @@ impl<'a, I: Iterator>> PrattParser for ExprP name: Identifier::from_name(transform_span(elem.span.tokens), "getvariable"), args: vec![Expr::Literal { span: transform_span(elem.span.tokens), - value: Literal::String(name.to_string()), + value: Literal::String(name), }], params: vec![], window: None, diff --git a/src/query/ast/src/parser/token.rs b/src/query/ast/src/parser/token.rs index 277b111f6d02..29e16192ff93 100644 --- a/src/query/ast/src/parser/token.rs +++ b/src/query/ast/src/parser/token.rs @@ -149,9 +149,6 @@ pub enum TokenKind { #[regex(r#"\$[0-9]+"#)] ColumnPosition, - #[regex(r#"\$[_a-zA-Z][_$a-zA-Z0-9]*"#)] - VariableAccess, - #[regex(r#"`[^`]*`"#)] #[regex(r#""([^"\\]|\\.|"")*""#)] #[regex(r#"'([^'\\]|\\.|'')*'"#)] @@ -239,6 +236,8 @@ pub enum TokenKind { LBrace, #[token("}")] RBrace, + #[token("$")] + Dollar, #[token("->")] RArrow, #[token("->>")] @@ -1376,6 +1375,7 @@ impl TokenKind { | Factorial | LBrace | RBrace + | Dollar | RArrow | LongRArrow | HashRArrow diff --git a/src/query/ast/tests/it/parser.rs b/src/query/ast/tests/it/parser.rs index 8c73fdcb760b..da202cbaff1c 100644 --- a/src/query/ast/tests/it/parser.rs +++ b/src/query/ast/tests/it/parser.rs @@ -91,7 +91,7 @@ fn run_parser_with_dialect( #[test] fn test_statement() { let mut mint = Mint::new("tests/it/testdata"); - let file = &mut mint.new_goldenfile("statement.txt").unwrap(); + let file = &mut mint.new_goldenfile("stmt.txt").unwrap(); let cases = &[ r#"show databases"#, r#"show databases format TabSeparatedWithNamesAndTypes;"#, @@ -580,6 +580,7 @@ fn test_statement() { r#"SHOW GRANTS OF SHARE t;"#, r#"UPDATE db1.tb1 set a = a + 1, b = 2 WHERE c > 3;"#, r#"select $abc + 3"#, + r#"select IDENTIFIER($abc)"#, r#"SET max_threads = 10;"#, r#"SET max_threads = 10*2;"#, r#"SET global (max_threads, max_memory_usage) = (10*2, 10*4);"#, @@ -864,7 +865,7 @@ fn test_statement() { #[test] fn test_statement_error() { let mut mint = Mint::new("tests/it/testdata"); - let file = &mut mint.new_goldenfile("statement-error.txt").unwrap(); + let file = &mut mint.new_goldenfile("stmt-error.txt").unwrap(); let cases = &[ r#"create table a.b (c integer not null 1, b float(10))"#, diff --git a/src/query/ast/tests/it/testdata/dialect.txt b/src/query/ast/tests/it/testdata/dialect.txt index 1a3dc10e93f4..f21e334b21ca 100644 --- a/src/query/ast/tests/it/testdata/dialect.txt +++ b/src/query/ast/tests/it/testdata/dialect.txt @@ -34,7 +34,7 @@ ColumnRef { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -62,7 +62,7 @@ ColumnRef { quote: Some( '`', ), - is_hole: false, + ident_type: None, }, ), }, @@ -165,7 +165,7 @@ ColumnRef { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -193,7 +193,7 @@ ColumnRef { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -221,7 +221,7 @@ ColumnRef { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -262,7 +262,7 @@ ColumnRef { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -320,7 +320,7 @@ ColumnRef { quote: Some( '`', ), - is_hole: false, + ident_type: None, }, ), }, @@ -496,7 +496,7 @@ ColumnRef { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -520,7 +520,7 @@ FunctionCall { ), name: "add", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -537,7 +537,7 @@ FunctionCall { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -556,7 +556,7 @@ FunctionCall { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -586,7 +586,7 @@ FunctionCall { ), name: "add", quote: None, - is_hole: false, + ident_type: None, }, args: [ FunctionCall { @@ -601,7 +601,7 @@ FunctionCall { ), name: "sub", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -618,7 +618,7 @@ FunctionCall { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -637,7 +637,7 @@ FunctionCall { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -662,7 +662,7 @@ FunctionCall { ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -692,7 +692,7 @@ FunctionCall { ), name: "add", quote: None, - is_hole: false, + ident_type: None, }, args: [ FunctionCall { @@ -707,7 +707,7 @@ FunctionCall { ), name: "sub", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -724,7 +724,7 @@ FunctionCall { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -743,7 +743,7 @@ FunctionCall { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -768,7 +768,7 @@ FunctionCall { ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -830,7 +830,7 @@ BinaryOp { ), name: "k1", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -854,7 +854,7 @@ FunctionCall { ), name: "plus", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -898,7 +898,7 @@ FunctionCall { ), name: "add", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -940,7 +940,7 @@ FunctionCall { ), name: "k1", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -969,7 +969,7 @@ FunctionCall { ), name: "array_map", quote: None, - is_hole: false, + ident_type: None, }, args: [ FunctionCall { @@ -984,7 +984,7 @@ FunctionCall { ), name: "array_filter", quote: None, - is_hole: false, + ident_type: None, }, args: [ Array { @@ -1030,7 +1030,7 @@ FunctionCall { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -1057,7 +1057,7 @@ FunctionCall { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1096,7 +1096,7 @@ FunctionCall { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -1118,7 +1118,7 @@ FunctionCall { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ), }, diff --git a/src/query/ast/tests/it/testdata/expr.txt b/src/query/ast/tests/it/testdata/expr.txt index 2398ed6e63a2..3411e8072846 100644 --- a/src/query/ast/tests/it/testdata/expr.txt +++ b/src/query/ast/tests/it/testdata/expr.txt @@ -17,7 +17,7 @@ ColumnRef { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -71,7 +71,7 @@ FunctionCall { ), name: "char", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -786,7 +786,7 @@ FunctionCall { ), name: "typeof", quote: None, - is_hole: false, + ident_type: None, }, args: [ BinaryOp { @@ -1037,7 +1037,7 @@ BinaryOp { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1055,7 +1055,7 @@ BinaryOp { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -1065,7 +1065,7 @@ BinaryOp { ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1098,7 +1098,7 @@ BinaryOp { ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1143,7 +1143,7 @@ MapAccess { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -1155,7 +1155,7 @@ MapAccess { ), name: "k1", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -1166,7 +1166,7 @@ MapAccess { ), name: "k2", quote: None, - is_hole: false, + ident_type: None, }, }, } @@ -1205,7 +1205,7 @@ MapAccess { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -1217,7 +1217,7 @@ MapAccess { ), name: "k1", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -1228,7 +1228,7 @@ MapAccess { ), name: "k2", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -1261,7 +1261,7 @@ MapAccess { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1323,7 +1323,7 @@ Between { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1365,7 +1365,7 @@ FunctionCall { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -1382,7 +1382,7 @@ FunctionCall { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1414,7 +1414,7 @@ FunctionCall { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -1441,7 +1441,7 @@ FunctionCall { ), name: "random", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -1468,7 +1468,7 @@ FunctionCall { ), name: "covar_samp", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -1485,7 +1485,7 @@ FunctionCall { ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1504,7 +1504,7 @@ FunctionCall { ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1540,7 +1540,7 @@ Cast { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1573,7 +1573,7 @@ TryCast { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1605,7 +1605,7 @@ TryCast { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1679,7 +1679,7 @@ Extract { ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1711,7 +1711,7 @@ DatePart { ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1750,7 +1750,7 @@ Position { ), name: "str", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1781,7 +1781,7 @@ Substring { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1800,7 +1800,7 @@ Substring { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1820,7 +1820,7 @@ Substring { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1852,7 +1852,7 @@ Substring { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1871,7 +1871,7 @@ Substring { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1891,7 +1891,7 @@ Substring { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1923,7 +1923,7 @@ Cast { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1964,7 +1964,7 @@ MapAccess { ), name: "arr", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1987,7 +1987,7 @@ MapAccess { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -1998,7 +1998,7 @@ MapAccess { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, } @@ -2031,7 +2031,7 @@ MapAccess { ), name: "arr", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2064,7 +2064,7 @@ MapAccess { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -2097,7 +2097,7 @@ BinaryOp { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2185,7 +2185,7 @@ BinaryOp { ), name: "G", quote: None, - is_hole: false, + ident_type: None, }, ), table: Some( @@ -2195,7 +2195,7 @@ BinaryOp { ), name: "E", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2205,7 +2205,7 @@ BinaryOp { ), name: "B", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2230,7 +2230,7 @@ BinaryOp { ), name: "col1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2249,7 +2249,7 @@ BinaryOp { ), name: "col2", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2286,7 +2286,7 @@ BinaryOp { ), name: "col3", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2304,7 +2304,7 @@ BinaryOp { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -2321,7 +2321,7 @@ BinaryOp { ), name: "col4", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2360,7 +2360,7 @@ BinaryOp { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ Case { @@ -2387,7 +2387,7 @@ BinaryOp { ), name: "n2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2397,7 +2397,7 @@ BinaryOp { ), name: "n_name", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2427,7 +2427,7 @@ BinaryOp { ), name: "ol_amount", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2473,7 +2473,7 @@ BinaryOp { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -2490,7 +2490,7 @@ BinaryOp { ), name: "ol_amount", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2534,7 +2534,7 @@ BinaryOp { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -2551,7 +2551,7 @@ BinaryOp { ), name: "ol_amount", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2632,7 +2632,7 @@ BinaryOp { ), name: "p_partkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2651,7 +2651,7 @@ BinaryOp { ), name: "l_partkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2676,7 +2676,7 @@ BinaryOp { ), name: "p_brand", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2709,7 +2709,7 @@ BinaryOp { ), name: "p_container", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2770,7 +2770,7 @@ BinaryOp { ), name: "l_quantity", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2811,7 +2811,7 @@ BinaryOp { ), name: "l_quantity", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2865,7 +2865,7 @@ BinaryOp { ), name: "p_size", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2921,7 +2921,7 @@ BinaryOp { ), name: "l_shipmode", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2966,7 +2966,7 @@ BinaryOp { ), name: "l_shipinstruct", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3000,7 +3000,7 @@ FunctionCall { ), name: "nullif", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -3044,7 +3044,7 @@ FunctionCall { ), name: "nullif", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3061,7 +3061,7 @@ FunctionCall { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3080,7 +3080,7 @@ FunctionCall { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3110,7 +3110,7 @@ FunctionCall { ), name: "coalesce", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -3162,7 +3162,7 @@ FunctionCall { ), name: "coalesce", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3179,7 +3179,7 @@ FunctionCall { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3198,7 +3198,7 @@ FunctionCall { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3217,7 +3217,7 @@ FunctionCall { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3247,7 +3247,7 @@ FunctionCall { ), name: "ifnull", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -3291,7 +3291,7 @@ FunctionCall { ), name: "ifnull", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3308,7 +3308,7 @@ FunctionCall { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3327,7 +3327,7 @@ FunctionCall { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3392,7 +3392,7 @@ IsDistinctFrom { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3411,7 +3411,7 @@ IsDistinctFrom { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3504,7 +3504,7 @@ FunctionCall { ), name: "ROW_NUMBER", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -3531,7 +3531,7 @@ FunctionCall { ), name: "salary", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3569,7 +3569,7 @@ FunctionCall { ), name: "SUM", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3586,7 +3586,7 @@ FunctionCall { ), name: "salary", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3628,7 +3628,7 @@ FunctionCall { ), name: "AVG", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3645,7 +3645,7 @@ FunctionCall { ), name: "salary", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3673,7 +3673,7 @@ FunctionCall { ), name: "department", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3707,7 +3707,7 @@ FunctionCall { ), name: "SUM", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3724,7 +3724,7 @@ FunctionCall { ), name: "salary", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3752,7 +3752,7 @@ FunctionCall { ), name: "department", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3774,7 +3774,7 @@ FunctionCall { ), name: "salary", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3820,7 +3820,7 @@ FunctionCall { ), name: "AVG", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3837,7 +3837,7 @@ FunctionCall { ), name: "salary", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3865,7 +3865,7 @@ FunctionCall { ), name: "department", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3887,7 +3887,7 @@ FunctionCall { ), name: "hire_date", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3940,7 +3940,7 @@ FunctionCall { ), name: "COUNT", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -3967,7 +3967,7 @@ FunctionCall { ), name: "hire_date", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4026,7 +4026,7 @@ FunctionCall { ), name: "COUNT", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -4053,7 +4053,7 @@ FunctionCall { ), name: "hire_date", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4097,7 +4097,7 @@ FunctionCall { ), name: "COUNT", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -4124,7 +4124,7 @@ FunctionCall { ), name: "hire_date", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4166,7 +4166,7 @@ FunctionCall { ), name: "COUNT", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -4193,7 +4193,7 @@ FunctionCall { ), name: "hire_date", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4246,7 +4246,7 @@ FunctionCall { ), name: "ARRAY_APPLY", quote: None, - is_hole: false, + ident_type: None, }, args: [ Array { @@ -4292,7 +4292,7 @@ FunctionCall { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -4314,7 +4314,7 @@ FunctionCall { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4351,7 +4351,7 @@ FunctionCall { ), name: "ARRAY_FILTER", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -4368,7 +4368,7 @@ FunctionCall { ), name: "col", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4385,7 +4385,7 @@ FunctionCall { ), name: "y", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -4412,7 +4412,7 @@ FunctionCall { ), name: "y", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4463,7 +4463,7 @@ Tuple { ), name: "current_timestamp", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -4483,7 +4483,7 @@ Tuple { ), name: "current_timestamp", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -4503,7 +4503,7 @@ Tuple { ), name: "now", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -4532,7 +4532,7 @@ FunctionCall { ), name: "ARRAY_REDUCE", quote: None, - is_hole: false, + ident_type: None, }, args: [ Array { @@ -4578,7 +4578,7 @@ FunctionCall { ), name: "acc", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -4586,7 +4586,7 @@ FunctionCall { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -4608,7 +4608,7 @@ FunctionCall { ), name: "acc", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -4627,7 +4627,7 @@ FunctionCall { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, ), }, diff --git a/src/query/ast/tests/it/testdata/query.txt b/src/query/ast/tests/it/testdata/query.txt index a725d60b0f6c..d32fb67159a7 100644 --- a/src/query/ast/tests/it/testdata/query.txt +++ b/src/query/ast/tests/it/testdata/query.txt @@ -34,7 +34,7 @@ Query { ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -49,7 +49,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), Star( @@ -67,7 +67,7 @@ Query { ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -75,7 +75,7 @@ Query { ), name: "c3", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -83,7 +83,7 @@ Query { ), name: "c4", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -117,7 +117,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -136,7 +136,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -155,7 +155,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -176,7 +176,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -248,7 +248,7 @@ Query { ), name: "_t", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -268,7 +268,7 @@ Query { ), name: "_t", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -304,7 +304,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], expr: BinaryOp { @@ -324,7 +324,7 @@ Query { ), name: "length", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -341,7 +341,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -379,7 +379,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -446,7 +446,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: Some( @@ -546,7 +546,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: Some( @@ -562,7 +562,7 @@ Query { ), name: "s", quote: None, - is_hole: false, + ident_type: None, }, }, end_point: None, @@ -598,7 +598,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -621,7 +621,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -679,7 +679,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: Some( TableAlias { @@ -689,7 +689,7 @@ Query { ), name: "s", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -765,7 +765,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -786,7 +786,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -862,7 +862,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -883,7 +883,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -966,7 +966,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -985,7 +985,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1004,7 +1004,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1025,7 +1025,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1108,7 +1108,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1127,7 +1127,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1146,7 +1146,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1167,7 +1167,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1259,7 +1259,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1278,7 +1278,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1297,7 +1297,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1318,7 +1318,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1412,7 +1412,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1433,7 +1433,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1504,7 +1504,7 @@ Query { ), name: "id", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -1527,7 +1527,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1548,7 +1548,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1571,7 +1571,7 @@ Query { ), name: "detail", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1624,7 +1624,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -1633,7 +1633,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -1667,7 +1667,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1688,7 +1688,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1737,7 +1737,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -1747,7 +1747,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1768,7 +1768,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1797,7 +1797,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -1807,7 +1807,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1862,7 +1862,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -1871,7 +1871,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -1905,7 +1905,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1926,7 +1926,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1975,7 +1975,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -1985,7 +1985,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2006,7 +2006,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2035,7 +2035,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2045,7 +2045,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2100,7 +2100,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -2134,7 +2134,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2155,7 +2155,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2204,7 +2204,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2214,7 +2214,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2235,7 +2235,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2264,7 +2264,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2274,7 +2274,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2329,7 +2329,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -2338,7 +2338,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -2372,7 +2372,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2393,7 +2393,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2427,7 +2427,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -2470,7 +2470,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2504,7 +2504,7 @@ Query { ), name: "t4", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -2538,7 +2538,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2559,7 +2559,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2589,7 +2589,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2642,7 +2642,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2652,7 +2652,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2673,7 +2673,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2683,7 +2683,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2704,7 +2704,7 @@ Query { ), name: "t4", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2714,7 +2714,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2735,7 +2735,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2756,7 +2756,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2777,7 +2777,7 @@ Query { ), name: "t4", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2806,7 +2806,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -2816,7 +2816,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2871,7 +2871,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -2880,7 +2880,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -2921,7 +2921,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2942,7 +2942,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2983,7 +2983,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3004,7 +3004,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -3055,7 +3055,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -3065,7 +3065,7 @@ Query { ), name: "tt", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3086,7 +3086,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -3137,7 +3137,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -3146,7 +3146,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -3154,7 +3154,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -3253,7 +3253,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -3263,7 +3263,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3284,7 +3284,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -3294,7 +3294,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3315,7 +3315,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -3388,7 +3388,7 @@ Query { ), name: "c_count", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3400,7 +3400,7 @@ Query { ), name: "cc", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3418,7 +3418,7 @@ Query { ), name: "custdist", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3435,7 +3435,7 @@ Query { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3452,7 +3452,7 @@ Query { ), name: "c_acctbal", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3470,7 +3470,7 @@ Query { ), name: "totacctbal", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3488,7 +3488,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -3509,7 +3509,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: Some( TableAlias { @@ -3519,7 +3519,7 @@ Query { ), name: "ODS", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -3564,7 +3564,7 @@ Query { ), name: "c_custkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3584,7 +3584,7 @@ Query { ), name: "count", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -3601,7 +3601,7 @@ Query { ), name: "o_orderkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3647,7 +3647,7 @@ Query { ), name: "c_custkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3666,7 +3666,7 @@ Query { ), name: "o_custkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3691,7 +3691,7 @@ Query { ), name: "o_comment", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3719,7 +3719,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -3740,7 +3740,7 @@ Query { ), name: "orders", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -3770,7 +3770,7 @@ Query { ), name: "c_custkey", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3796,7 +3796,7 @@ Query { ), name: "c_orders", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -3821,7 +3821,7 @@ Query { ), name: "c_count", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3850,7 +3850,7 @@ Query { ), name: "custdist", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3877,7 +3877,7 @@ Query { ), name: "c_count", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3902,7 +3902,7 @@ Query { ), name: "totacctbal", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3936,7 +3936,7 @@ Query { ), name: "totacctbal", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3997,7 +3997,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4047,7 +4047,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4123,7 +4123,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4173,7 +4173,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4256,7 +4256,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4306,7 +4306,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4358,7 +4358,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4441,7 +4441,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4491,7 +4491,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4543,7 +4543,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4619,7 +4619,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4676,7 +4676,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4726,7 +4726,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4811,7 +4811,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4861,7 +4861,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4913,7 +4913,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -4989,7 +4989,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5046,7 +5046,7 @@ Query { ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5096,7 +5096,7 @@ Query { ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5243,7 +5243,7 @@ Query { ), name: "foo", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -5383,7 +5383,7 @@ Query { ), name: "foo", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -5478,7 +5478,7 @@ Query { ), name: "xyu", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5511,7 +5511,7 @@ Query { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5534,7 +5534,7 @@ Query { ), name: "y", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5555,7 +5555,7 @@ Query { ), name: "xyu", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -5619,7 +5619,7 @@ Query { ), name: "monthly_sales", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5638,7 +5638,7 @@ Query { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -5655,7 +5655,7 @@ Query { ), name: "amount", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5672,7 +5672,7 @@ Query { ), name: "month", quote: None, - is_hole: false, + ident_type: None, }, values: [ Literal { @@ -5737,7 +5737,7 @@ Query { ), name: "empid", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5795,7 +5795,7 @@ Query { ), name: "monthly_sales_1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5809,7 +5809,7 @@ Query { ), name: "sales", quote: None, - is_hole: false, + ident_type: None, }, column_name: Identifier { span: Some( @@ -5817,7 +5817,7 @@ Query { ), name: "month", quote: None, - is_hole: false, + ident_type: None, }, names: [ Identifier { @@ -5826,7 +5826,7 @@ Query { ), name: "jan", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -5834,7 +5834,7 @@ Query { ), name: "feb", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -5842,7 +5842,7 @@ Query { ), name: "mar", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -5850,7 +5850,7 @@ Query { ), name: "april", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -5881,7 +5881,7 @@ Query { ), name: "empid", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5938,7 +5938,7 @@ Query { ), name: "range", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -6009,7 +6009,7 @@ Query { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -6026,7 +6026,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6044,7 +6044,7 @@ Query { ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -6069,7 +6069,7 @@ Query { ), name: "customer", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6091,7 +6091,7 @@ Query { ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, spec: WindowSpec { existing_window_name: None, @@ -6110,7 +6110,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6132,7 +6132,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6190,7 +6190,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6210,7 +6210,7 @@ Query { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -6227,7 +6227,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6245,7 +6245,7 @@ Query { ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -6269,7 +6269,7 @@ Query { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -6286,7 +6286,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6304,7 +6304,7 @@ Query { ), name: "w1", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -6328,7 +6328,7 @@ Query { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -6345,7 +6345,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6363,7 +6363,7 @@ Query { ), name: "w2", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -6388,7 +6388,7 @@ Query { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6410,7 +6410,7 @@ Query { ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, spec: WindowSpec { existing_window_name: None, @@ -6429,7 +6429,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6446,7 +6446,7 @@ Query { ), name: "w2", quote: None, - is_hole: false, + ident_type: None, }, spec: WindowSpec { existing_window_name: Some( @@ -6456,7 +6456,7 @@ Query { ), name: "w1", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -6477,7 +6477,7 @@ Query { ), name: "w1", quote: None, - is_hole: false, + ident_type: None, }, spec: WindowSpec { existing_window_name: Some( @@ -6487,7 +6487,7 @@ Query { ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -6507,7 +6507,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6540,7 +6540,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6629,7 +6629,7 @@ Query { ), name: "xyu", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6662,7 +6662,7 @@ Query { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6685,7 +6685,7 @@ Query { ), name: "y", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6706,7 +6706,7 @@ Query { ), name: "xyu", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -6838,7 +6838,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -6847,7 +6847,7 @@ Query { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -6855,7 +6855,7 @@ Query { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ], }, @@ -6961,7 +6961,7 @@ Query { ), name: "col0", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7044,7 +7044,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7205,7 +7205,7 @@ Query { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7225,7 +7225,7 @@ Query { ), name: "flatten", quote: None, - is_hole: false, + ident_type: None, }, params: [], named_params: [ @@ -7236,7 +7236,7 @@ Query { ), name: "input", quote: None, - is_hole: false, + ident_type: None, }, ColumnRef { span: Some( @@ -7251,7 +7251,7 @@ Query { ), name: "u", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7261,7 +7261,7 @@ Query { ), name: "col", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7276,7 +7276,7 @@ Query { ), name: "f", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -7340,7 +7340,7 @@ Query { ), name: "flatten", quote: None, - is_hole: false, + ident_type: None, }, params: [], named_params: [ @@ -7351,7 +7351,7 @@ Query { ), name: "input", quote: None, - is_hole: false, + ident_type: None, }, FunctionCall { span: Some( @@ -7365,7 +7365,7 @@ Query { ), name: "parse_json", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -7390,7 +7390,7 @@ Query { ), name: "outer", quote: None, - is_hole: false, + ident_type: None, }, Literal { span: Some( diff --git a/src/query/ast/tests/it/testdata/raw-insert.txt b/src/query/ast/tests/it/testdata/raw-insert.txt index e0159b91af26..be3226a37491 100644 --- a/src/query/ast/tests/it/testdata/raw-insert.txt +++ b/src/query/ast/tests/it/testdata/raw-insert.txt @@ -15,7 +15,7 @@ Insert( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -24,7 +24,7 @@ Insert( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -32,7 +32,7 @@ Insert( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ], source: RawValues { @@ -61,7 +61,7 @@ Insert( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -70,7 +70,7 @@ Insert( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -78,7 +78,7 @@ Insert( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ], source: RawValues { @@ -107,7 +107,7 @@ Insert( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [], source: Select { @@ -149,7 +149,7 @@ Insert( ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, diff --git a/src/query/ast/tests/it/testdata/script.txt b/src/query/ast/tests/it/testdata/script.txt index acb9cedcbd76..e2914191f3ec 100644 --- a/src/query/ast/tests/it/testdata/script.txt +++ b/src/query/ast/tests/it/testdata/script.txt @@ -14,7 +14,7 @@ LetVar { ), name: "cost", quote: None, - is_hole: false, + ident_type: None, }, default: Literal { span: Some( @@ -46,7 +46,7 @@ LetStatement { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, stmt: Query( Query { @@ -86,7 +86,7 @@ LetStatement { ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -135,7 +135,7 @@ Assign { ), name: "profit", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -156,7 +156,7 @@ Assign { ), name: "revenue", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -175,7 +175,7 @@ Assign { ), name: "cost", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -222,7 +222,7 @@ Return { ), name: "profit", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -249,7 +249,7 @@ Return { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, ), ), @@ -305,7 +305,7 @@ Return { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -352,7 +352,7 @@ ForLoop { ), name: "i", quote: None, - is_hole: false, + ident_type: None, }, is_reverse: true, lower_bound: Literal { @@ -377,7 +377,7 @@ ForLoop { ), name: "maximum_count", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -393,7 +393,7 @@ ForLoop { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -414,7 +414,7 @@ ForLoop { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -437,7 +437,7 @@ ForLoop { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), } @@ -462,7 +462,7 @@ ForInSet { ), name: "rec", quote: None, - is_hole: false, + ident_type: None, }, resultset: Identifier { span: Some( @@ -470,7 +470,7 @@ ForInSet { ), name: "resultset", quote: None, - is_hole: false, + ident_type: None, }, body: [ Continue { @@ -487,7 +487,7 @@ ForInSet { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), } @@ -514,7 +514,7 @@ ForInStatement { ), name: "rec", quote: None, - is_hole: false, + ident_type: None, }, stmt: Query( Query { @@ -554,7 +554,7 @@ ForInStatement { ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -599,7 +599,7 @@ ForInStatement { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), } @@ -637,7 +637,7 @@ WhileLoop { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -656,7 +656,7 @@ WhileLoop { ), name: "maximum_count", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -674,7 +674,7 @@ WhileLoop { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -686,7 +686,7 @@ WhileLoop { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), } @@ -734,7 +734,7 @@ RepeatLoop { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -753,7 +753,7 @@ RepeatLoop { ), name: "maximum_count", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -766,7 +766,7 @@ RepeatLoop { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), } @@ -797,7 +797,7 @@ Loop { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -809,7 +809,7 @@ Loop { ), name: "label1", quote: None, - is_hole: false, + ident_type: None, }, ), } @@ -859,7 +859,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -892,7 +892,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -919,7 +919,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -940,7 +940,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -967,7 +967,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -988,7 +988,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1017,7 +1017,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1038,7 +1038,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1096,7 +1096,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1132,7 +1132,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1153,7 +1153,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1180,7 +1180,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1201,7 +1201,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1230,7 +1230,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1251,7 +1251,7 @@ Case { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1312,7 +1312,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1345,7 +1345,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1372,7 +1372,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1393,7 +1393,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1420,7 +1420,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1441,7 +1441,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1470,7 +1470,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, value: BinaryOp { span: Some( @@ -1491,7 +1491,7 @@ If { ), name: "counter", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1559,7 +1559,7 @@ Loop { ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1581,7 +1581,7 @@ Loop { ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1602,7 +1602,7 @@ Loop { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1632,7 +1632,7 @@ Loop { ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1769,7 +1769,7 @@ RunStatement { ), name: "b", quote: None, - is_hole: true, + ident_type: Hole, }, ), }, @@ -1836,7 +1836,7 @@ RunStatement { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Some( @@ -1846,7 +1846,7 @@ RunStatement { ), name: "b", quote: None, - is_hole: true, + ident_type: Hole, }, ), column: Name( @@ -1856,7 +1856,7 @@ RunStatement { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1873,7 +1873,7 @@ RunStatement { ), name: "minus", quote: None, - is_hole: false, + ident_type: None, }, args: [ Hole { @@ -1982,7 +1982,7 @@ ScriptBlock { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, default: Literal { span: Some( @@ -2006,7 +2006,7 @@ ScriptBlock { ), name: "y", quote: None, - is_hole: false, + ident_type: None, }, is_reverse: false, lower_bound: ColumnRef { @@ -2023,7 +2023,7 @@ ScriptBlock { ), name: "x", quote: None, - is_hole: false, + ident_type: None, }, ), }, diff --git a/src/query/ast/tests/it/testdata/statement-error.txt b/src/query/ast/tests/it/testdata/stmt-error.txt similarity index 99% rename from src/query/ast/tests/it/testdata/statement-error.txt rename to src/query/ast/tests/it/testdata/stmt-error.txt index 9c117cc1df11..3af1308ed33c 100644 --- a/src/query/ast/tests/it/testdata/statement-error.txt +++ b/src/query/ast/tests/it/testdata/stmt-error.txt @@ -883,7 +883,7 @@ error: --> SQL:1:23 | 1 | drop table IDENTIFIER(a) - | ---- ^ unexpected `a`, expecting `:` + | ---- ^ unexpected `a`, expecting `$` or `:` | | | while parsing `DROP TABLE [IF EXISTS] [.]` diff --git a/src/query/ast/tests/it/testdata/statement.txt b/src/query/ast/tests/it/testdata/stmt.txt similarity index 95% rename from src/query/ast/tests/it/testdata/statement.txt rename to src/query/ast/tests/it/testdata/stmt.txt index 024927b4f771..7a80b161848c 100644 --- a/src/query/ast/tests/it/testdata/statement.txt +++ b/src/query/ast/tests/it/testdata/stmt.txt @@ -105,7 +105,7 @@ ShowDropTables( ), name: "name", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -162,7 +162,7 @@ DescribeTable( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, }, ) @@ -185,7 +185,7 @@ DescribeTable( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, }, ) @@ -222,7 +222,7 @@ ShowTables( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), full: true, @@ -246,7 +246,7 @@ ShowTables( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Some( @@ -256,7 +256,7 @@ ShowTables( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), full: true, @@ -281,7 +281,7 @@ ShowColumns( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -290,7 +290,7 @@ ShowColumns( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, full: true, limit: None, @@ -312,7 +312,7 @@ ShowColumns( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Some( @@ -322,7 +322,7 @@ ShowColumns( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -331,7 +331,7 @@ ShowColumns( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, full: false, limit: None, @@ -354,7 +354,7 @@ ShowColumns( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -363,7 +363,7 @@ ShowColumns( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, full: true, limit: Some( @@ -425,7 +425,7 @@ ShowProcessList { ), name: "database", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -464,7 +464,7 @@ ShowCreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -473,7 +473,7 @@ ShowCreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -494,7 +494,7 @@ ShowCreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -503,7 +503,7 @@ ShowCreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -529,7 +529,7 @@ Replace( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, on_conflict_columns: [ Identifier { @@ -538,7 +538,7 @@ Replace( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ], columns: [], @@ -570,7 +570,7 @@ Replace( ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -587,7 +587,7 @@ Replace( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -605,7 +605,7 @@ Replace( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -623,7 +623,7 @@ Replace( ), name: "source", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -651,7 +651,7 @@ Replace( ), name: "v", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -713,7 +713,7 @@ Explain { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -734,7 +734,7 @@ Explain { ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -779,7 +779,7 @@ Explain { ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, on_conflict_columns: [ Identifier { @@ -788,7 +788,7 @@ Explain { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ], columns: [], @@ -820,7 +820,7 @@ Explain { ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -837,7 +837,7 @@ Explain { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -855,7 +855,7 @@ Explain { ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -873,7 +873,7 @@ Explain { ), name: "source", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -901,7 +901,7 @@ Explain { ), name: "v", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -964,7 +964,7 @@ Explain { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -985,7 +985,7 @@ Explain { ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1062,7 +1062,7 @@ Explain { ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1092,7 +1092,7 @@ Explain { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1137,7 +1137,7 @@ DescribeTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -1158,7 +1158,7 @@ DescribeTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -1183,7 +1183,7 @@ CreateIndex( ), name: "idx1", quote: None, - is_hole: false, + ident_type: None, }, query: Query { span: Some( @@ -1212,7 +1212,7 @@ CreateIndex( ), name: "SUM", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -1229,7 +1229,7 @@ CreateIndex( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1257,7 +1257,7 @@ CreateIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1278,7 +1278,7 @@ CreateIndex( ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1308,7 +1308,7 @@ CreateIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1340,7 +1340,7 @@ CreateIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1378,7 +1378,7 @@ CreateIndex( ), name: "idx1", quote: None, - is_hole: false, + ident_type: None, }, query: Query { span: Some( @@ -1407,7 +1407,7 @@ CreateIndex( ), name: "SUM", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -1424,7 +1424,7 @@ CreateIndex( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1452,7 +1452,7 @@ CreateIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1473,7 +1473,7 @@ CreateIndex( ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -1503,7 +1503,7 @@ CreateIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1535,7 +1535,7 @@ CreateIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -1572,7 +1572,7 @@ CreateInvertedIndex( ), name: "idx2", quote: None, - is_hole: false, + ident_type: None, }, catalog: None, database: None, @@ -1582,7 +1582,7 @@ CreateInvertedIndex( ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -1591,7 +1591,7 @@ CreateInvertedIndex( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -1599,7 +1599,7 @@ CreateInvertedIndex( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ], sync_creation: true, @@ -1624,7 +1624,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -1636,7 +1636,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Decimal { precision: 38, @@ -1675,7 +1675,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -1687,7 +1687,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Decimal { precision: 38, @@ -1726,7 +1726,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -1738,7 +1738,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Decimal { precision: 38, @@ -1777,7 +1777,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -1789,7 +1789,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: UInt32, expr: None, @@ -1825,7 +1825,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -1834,7 +1834,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -1846,7 +1846,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int32, @@ -1872,7 +1872,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -1908,7 +1908,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -1917,7 +1917,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -1929,7 +1929,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int32, @@ -1955,7 +1955,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -2008,7 +2008,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -2052,7 +2052,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2061,7 +2061,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2073,7 +2073,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Tuple { fields_name: Some( @@ -2084,7 +2084,7 @@ CreateTable( ), name: "m", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -2092,7 +2092,7 @@ CreateTable( ), name: "n", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -2111,7 +2111,7 @@ CreateTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, data_type: Tuple { fields_name: None, @@ -2153,7 +2153,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2165,7 +2165,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: Tuple { fields_name: Some( @@ -2178,7 +2178,7 @@ CreateTable( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -2188,7 +2188,7 @@ CreateTable( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ], ), @@ -2230,7 +2230,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2239,7 +2239,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2251,7 +2251,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -2264,7 +2264,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -2277,7 +2277,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: Some( @@ -2294,7 +2294,7 @@ CreateTable( ), name: "concat", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -2311,7 +2311,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2338,7 +2338,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2383,7 +2383,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2392,7 +2392,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2404,7 +2404,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -2417,7 +2417,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -2430,7 +2430,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: Some( @@ -2454,7 +2454,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2473,7 +2473,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -2513,7 +2513,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2522,7 +2522,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2534,7 +2534,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -2547,7 +2547,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -2563,7 +2563,7 @@ CreateTable( ), name: "idx1", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -2572,7 +2572,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -2580,7 +2580,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ], sync_creation: true, @@ -2618,7 +2618,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2627,7 +2627,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Like { @@ -2639,7 +2639,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2648,7 +2648,7 @@ CreateTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -2678,7 +2678,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Like { @@ -2690,7 +2690,7 @@ CreateTable( ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -2722,7 +2722,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2731,7 +2731,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2743,7 +2743,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -2796,7 +2796,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2805,7 +2805,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -2817,7 +2817,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -2867,7 +2867,7 @@ TruncateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -2890,7 +2890,7 @@ TruncateTable( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2899,7 +2899,7 @@ TruncateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -2921,7 +2921,7 @@ DropTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, all: false, }, @@ -2944,7 +2944,7 @@ DropTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -2955,7 +2955,7 @@ DropTable( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, all: false, }, @@ -2976,7 +2976,7 @@ UseDatabase { quote: Some( '"', ), - is_hole: false, + ident_type: None, }, } @@ -3033,7 +3033,7 @@ CreateDatabase( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, engine: None, @@ -3058,7 +3058,7 @@ CreateDatabase( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Identifier { @@ -3067,7 +3067,7 @@ CreateDatabase( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, engine: Some( @@ -3094,7 +3094,7 @@ CreateDatabase( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, engine: Some( @@ -3123,7 +3123,7 @@ CreateTable( quote: Some( '`', ), - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -3135,7 +3135,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int32, @@ -3150,7 +3150,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int32, @@ -3165,7 +3165,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int32, @@ -3207,7 +3207,7 @@ CreateDatabase( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, engine: None, @@ -3231,7 +3231,7 @@ DropDatabase( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Identifier { @@ -3240,7 +3240,7 @@ DropDatabase( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -3261,7 +3261,7 @@ DropDatabase( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -3283,7 +3283,7 @@ CreateTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -3295,7 +3295,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( Timestamp, @@ -3310,7 +3310,7 @@ CreateTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: Timestamp, expr: None, @@ -3346,7 +3346,7 @@ CreateView( ), name: "v", quote: None, - is_hole: false, + ident_type: None, }, columns: [], query: Query { @@ -3383,7 +3383,7 @@ CreateView( ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3404,7 +3404,7 @@ CreateView( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3421,7 +3421,7 @@ CreateView( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -3469,7 +3469,7 @@ AlterView( ), name: "v", quote: None, - is_hole: false, + ident_type: None, }, columns: [], query: Query { @@ -3506,7 +3506,7 @@ AlterView( ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3527,7 +3527,7 @@ AlterView( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3544,7 +3544,7 @@ AlterView( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -3593,7 +3593,7 @@ DropView( ), name: "v", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -3615,7 +3615,7 @@ CreateView( ), name: "v1", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -3624,7 +3624,7 @@ CreateView( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ], query: Query { @@ -3661,7 +3661,7 @@ CreateView( ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3682,7 +3682,7 @@ CreateView( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3699,7 +3699,7 @@ CreateView( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -3748,7 +3748,7 @@ CreateView( ), name: "v1", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -3757,7 +3757,7 @@ CreateView( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ], query: Query { @@ -3794,7 +3794,7 @@ CreateView( ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3815,7 +3815,7 @@ CreateView( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3832,7 +3832,7 @@ CreateView( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -3880,7 +3880,7 @@ AlterView( ), name: "v1", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -3889,7 +3889,7 @@ AlterView( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ], query: Query { @@ -3926,7 +3926,7 @@ AlterView( ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3947,7 +3947,7 @@ AlterView( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -3964,7 +3964,7 @@ AlterView( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -4064,7 +4064,7 @@ ShowViews( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), full: true, @@ -4088,7 +4088,7 @@ ShowViews( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Some( @@ -4098,7 +4098,7 @@ ShowViews( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), full: true, @@ -4124,7 +4124,7 @@ CreateStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4133,7 +4133,7 @@ CreateStream( ), name: "s1", quote: None, - is_hole: false, + ident_type: None, }, table_database: Some( Identifier { @@ -4142,7 +4142,7 @@ CreateStream( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4151,7 +4151,7 @@ CreateStream( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, travel_point: None, append_only: false, @@ -4176,7 +4176,7 @@ CreateStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4185,7 +4185,7 @@ CreateStream( ), name: "s2", quote: None, - is_hole: false, + ident_type: None, }, table_database: Some( Identifier { @@ -4194,7 +4194,7 @@ CreateStream( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4203,7 +4203,7 @@ CreateStream( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, travel_point: Some( Stream { @@ -4215,7 +4215,7 @@ CreateStream( ), name: "test1", quote: None, - is_hole: false, + ident_type: None, }, ), name: Identifier { @@ -4224,7 +4224,7 @@ CreateStream( ), name: "s1", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -4252,7 +4252,7 @@ CreateStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4261,7 +4261,7 @@ CreateStream( ), name: "s3", quote: None, - is_hole: false, + ident_type: None, }, table_database: Some( Identifier { @@ -4270,7 +4270,7 @@ CreateStream( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4279,7 +4279,7 @@ CreateStream( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, travel_point: Some( Timestamp( @@ -4322,7 +4322,7 @@ CreateStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4331,7 +4331,7 @@ CreateStream( ), name: "s3", quote: None, - is_hole: false, + ident_type: None, }, table_database: Some( Identifier { @@ -4340,7 +4340,7 @@ CreateStream( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4349,7 +4349,7 @@ CreateStream( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, travel_point: Some( Snapshot( @@ -4378,7 +4378,7 @@ CreateStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4387,7 +4387,7 @@ CreateStream( ), name: "s1", quote: None, - is_hole: false, + ident_type: None, }, table_database: Some( Identifier { @@ -4396,7 +4396,7 @@ CreateStream( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4405,7 +4405,7 @@ CreateStream( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, travel_point: None, append_only: false, @@ -4428,7 +4428,7 @@ ShowStreams( ), name: "default", quote: None, - is_hole: false, + ident_type: None, }, ), database: Some( @@ -4438,7 +4438,7 @@ ShowStreams( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), full: true, @@ -4466,7 +4466,7 @@ DescribeStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4475,7 +4475,7 @@ DescribeStream( ), name: "s2", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -4497,7 +4497,7 @@ DropStream( ), name: "test2", quote: None, - is_hole: false, + ident_type: None, }, ), stream: Identifier { @@ -4506,7 +4506,7 @@ DropStream( ), name: "s2", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -4528,7 +4528,7 @@ RenameTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4537,7 +4537,7 @@ RenameTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, new_catalog: None, new_database: Some( @@ -4547,7 +4547,7 @@ RenameTable( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, ), new_table: Identifier { @@ -4556,7 +4556,7 @@ RenameTable( ), name: "s", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -4577,7 +4577,7 @@ TruncateTable( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -4598,7 +4598,7 @@ TruncateTable( ), name: "test_db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -4607,7 +4607,7 @@ TruncateTable( ), name: "test", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -4629,7 +4629,7 @@ DropTable( ), name: "table1", quote: None, - is_hole: false, + ident_type: None, }, all: false, }, @@ -4652,7 +4652,7 @@ DropTable( ), name: "table1", quote: None, - is_hole: false, + ident_type: None, }, all: false, }, @@ -4675,7 +4675,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -4687,7 +4687,7 @@ CreateTable( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( Int32, @@ -4702,7 +4702,7 @@ CreateTable( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( Int64, @@ -4717,7 +4717,7 @@ CreateTable( ), name: "c3", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( String, @@ -4755,7 +4755,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -4767,7 +4767,7 @@ CreateTable( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int32, @@ -4782,7 +4782,7 @@ CreateTable( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Int64, @@ -4797,7 +4797,7 @@ CreateTable( ), name: "c3", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( String, @@ -4835,7 +4835,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -4847,7 +4847,7 @@ CreateTable( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, data_type: Binary, expr: None, @@ -4860,7 +4860,7 @@ CreateTable( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, data_type: Binary, expr: None, @@ -4896,7 +4896,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -4908,7 +4908,7 @@ CreateTable( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: Some( @@ -4955,7 +4955,7 @@ CreateTable( ), name: "abc", quote: None, - is_hole: false, + ident_type: None, }, source: None, engine: None, @@ -5001,7 +5001,7 @@ CreateTable( ), name: "xyz", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5282,7 +5282,7 @@ DropDatabase( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -5323,7 +5323,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5353,7 +5353,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5388,7 +5388,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5426,7 +5426,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5454,7 +5454,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5479,7 +5479,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5507,7 +5507,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -5578,7 +5578,7 @@ Query( ), name: "t4", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5649,7 +5649,7 @@ Query( ), name: "t4", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5718,7 +5718,7 @@ Query( ), name: "aa", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -5727,7 +5727,7 @@ Query( ), name: "bb", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5796,7 +5796,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5817,7 +5817,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5838,7 +5838,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5907,7 +5907,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5928,7 +5928,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5949,7 +5949,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -5982,7 +5982,7 @@ Query( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), table: Some( @@ -5994,7 +5994,7 @@ Query( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6006,7 +6006,7 @@ Query( quote: Some( '"', ), - is_hole: false, + ident_type: None, }, ), }, @@ -6079,7 +6079,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6089,7 +6089,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6107,7 +6107,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6117,7 +6117,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6136,7 +6136,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6157,7 +6157,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6241,7 +6241,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6251,7 +6251,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6269,7 +6269,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6279,7 +6279,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6298,7 +6298,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6319,7 +6319,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6403,7 +6403,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6413,7 +6413,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6431,7 +6431,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6441,7 +6441,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6460,7 +6460,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6481,7 +6481,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6565,7 +6565,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6575,7 +6575,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6593,7 +6593,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6603,7 +6603,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6622,7 +6622,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6643,7 +6643,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6727,7 +6727,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6737,7 +6737,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6755,7 +6755,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6765,7 +6765,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6784,7 +6784,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6805,7 +6805,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6889,7 +6889,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6899,7 +6899,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6917,7 +6917,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -6927,7 +6927,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -6946,7 +6946,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -6967,7 +6967,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7051,7 +7051,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7061,7 +7061,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7079,7 +7079,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7089,7 +7089,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7108,7 +7108,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7129,7 +7129,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7213,7 +7213,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7223,7 +7223,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7241,7 +7241,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7251,7 +7251,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7270,7 +7270,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7291,7 +7291,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7375,7 +7375,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7385,7 +7385,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7403,7 +7403,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7413,7 +7413,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7432,7 +7432,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7453,7 +7453,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7537,7 +7537,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7547,7 +7547,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7565,7 +7565,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7575,7 +7575,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7594,7 +7594,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7615,7 +7615,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7699,7 +7699,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7709,7 +7709,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7727,7 +7727,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -7737,7 +7737,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -7756,7 +7756,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7777,7 +7777,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7850,7 +7850,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -7866,7 +7866,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7887,7 +7887,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7960,7 +7960,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -7976,7 +7976,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -7997,7 +7997,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8070,7 +8070,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -8086,7 +8086,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8107,7 +8107,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8180,7 +8180,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], ), @@ -8196,7 +8196,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8217,7 +8217,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8288,7 +8288,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8317,7 +8317,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8327,7 +8327,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8367,7 +8367,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8377,7 +8377,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8398,7 +8398,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8481,7 +8481,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8510,7 +8510,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8520,7 +8520,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8560,7 +8560,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8570,7 +8570,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8591,7 +8591,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8674,7 +8674,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8703,7 +8703,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8713,7 +8713,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8753,7 +8753,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8763,7 +8763,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8784,7 +8784,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8867,7 +8867,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -8896,7 +8896,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8906,7 +8906,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8944,7 +8944,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -8954,7 +8954,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -8975,7 +8975,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -9058,7 +9058,7 @@ Query( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -9170,7 +9170,7 @@ Query( ), name: "read_parquet", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -9206,7 +9206,7 @@ Query( ), name: "prune_page", quote: None, - is_hole: false, + ident_type: None, }, Literal { span: Some( @@ -9224,7 +9224,7 @@ Query( ), name: "refresh_meta_cache", quote: None, - is_hole: false, + ident_type: None, }, Literal { span: Some( @@ -9510,7 +9510,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -9535,7 +9535,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -9599,7 +9599,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -9723,7 +9723,7 @@ Query( ), name: "t1", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -9733,7 +9733,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -9764,7 +9764,7 @@ Query( ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -9774,7 +9774,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -9792,7 +9792,7 @@ Query( ), name: "t3", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -9802,7 +9802,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -9877,7 +9877,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -9953,7 +9953,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -10029,7 +10029,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -10105,7 +10105,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -10180,7 +10180,7 @@ Query( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -10262,7 +10262,7 @@ Query( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -10344,7 +10344,7 @@ Query( ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -10400,7 +10400,7 @@ Insert( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -10409,7 +10409,7 @@ Insert( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -10417,7 +10417,7 @@ Insert( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ], source: Values { @@ -10482,7 +10482,7 @@ Insert( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [ Identifier { @@ -10491,7 +10491,7 @@ Insert( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -10499,7 +10499,7 @@ Insert( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ], source: Values { @@ -10546,7 +10546,7 @@ Insert( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [], source: Select { @@ -10588,7 +10588,7 @@ Insert( ), name: "t2", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -10657,7 +10657,7 @@ Query( ), name: "parse_json", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -10681,7 +10681,7 @@ Query( ), name: "k1", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -10748,7 +10748,7 @@ Query( ), name: "avg", quote: None, - is_hole: false, + ident_type: None, }, args: [ Cast { @@ -10774,7 +10774,7 @@ Query( ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -11304,7 +11304,7 @@ OptimizeTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, action: Compact { target: Segment, @@ -11331,7 +11331,7 @@ OptimizeTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, action: Compact { target: Block, @@ -11358,7 +11358,7 @@ OptimizeTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, action: Purge { before: Some( @@ -11389,7 +11389,7 @@ OptimizeTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, action: Purge { before: Some( @@ -11439,7 +11439,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11464,7 +11464,7 @@ AlterTable( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -11495,7 +11495,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11531,7 +11531,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11565,7 +11565,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11596,7 +11596,7 @@ AlterTable( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -11639,7 +11639,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11656,7 +11656,7 @@ AlterTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( Int32, @@ -11690,7 +11690,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11707,7 +11707,7 @@ AlterTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( Int32, @@ -11741,7 +11741,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11758,7 +11758,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Float32, expr: Some( @@ -11805,7 +11805,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11822,7 +11822,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: Some( @@ -11846,7 +11846,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -11874,7 +11874,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11890,7 +11890,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, new_column: Identifier { span: Some( @@ -11898,7 +11898,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -11925,7 +11925,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11941,7 +11941,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -11968,7 +11968,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -11984,7 +11984,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -12011,7 +12011,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12028,7 +12028,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, "mask", ), @@ -12057,7 +12057,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12074,7 +12074,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -12102,7 +12102,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12121,7 +12121,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: Some( @@ -12145,7 +12145,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: Float32, expr: None, @@ -12178,7 +12178,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12197,7 +12197,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Nullable( Int32, @@ -12223,7 +12223,7 @@ AlterTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: NotNull( Float32, @@ -12260,7 +12260,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12279,7 +12279,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -12312,7 +12312,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12331,7 +12331,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -12364,7 +12364,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12381,7 +12381,7 @@ AlterTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -12409,7 +12409,7 @@ AlterTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -12443,7 +12443,7 @@ AlterDatabase( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Identifier { @@ -12452,7 +12452,7 @@ AlterDatabase( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, action: RenameDatabase { new_db: Identifier { @@ -12461,7 +12461,7 @@ AlterDatabase( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -12483,7 +12483,7 @@ AlterDatabase( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, action: RenameDatabase { new_db: Identifier { @@ -12492,7 +12492,7 @@ AlterDatabase( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -12514,7 +12514,7 @@ AlterDatabase( ), name: "ctl", quote: None, - is_hole: false, + ident_type: None, }, ), database: Identifier { @@ -12523,7 +12523,7 @@ AlterDatabase( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, action: RenameDatabase { new_db: Identifier { @@ -12532,7 +12532,7 @@ AlterDatabase( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, }, @@ -12554,7 +12554,7 @@ VacuumTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, option: VacuumTableOption { dry_run: None, @@ -12578,7 +12578,7 @@ VacuumTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, option: VacuumTableOption { dry_run: Some( @@ -12604,7 +12604,7 @@ VacuumTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, option: VacuumTableOption { dry_run: Some( @@ -12685,7 +12685,7 @@ VacuumDropTable( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), option: VacuumDropTableOption { @@ -12711,7 +12711,7 @@ VacuumDropTable( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), option: VacuumDropTableOption { @@ -12740,7 +12740,7 @@ CreateTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -12752,7 +12752,7 @@ CreateTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -13561,7 +13561,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -13614,7 +13614,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -13690,7 +13690,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -13766,7 +13766,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -13846,7 +13846,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -13926,7 +13926,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -13994,7 +13994,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14049,7 +14049,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14103,7 +14103,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14168,7 +14168,7 @@ CopyIntoLocation( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -14227,7 +14227,7 @@ CopyIntoLocation( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -14270,7 +14270,7 @@ CopyIntoLocation( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -14346,7 +14346,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14412,7 +14412,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14478,7 +14478,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14544,7 +14544,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14620,7 +14620,7 @@ CopyIntoTable( ), name: "mytable", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14699,7 +14699,7 @@ CopyIntoTable( ), name: "books", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -14806,7 +14806,7 @@ ShowSettings { ), name: "name", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -14880,7 +14880,7 @@ ShowFunctions { ), name: "name", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -14954,7 +14954,7 @@ ShowEngines { ), name: "engine", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -15028,7 +15028,7 @@ ShowMetrics { ), name: "metric", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -15102,7 +15102,7 @@ ShowTableFunctions { ), name: "name", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -15176,7 +15176,7 @@ ShowIndexes { ), name: "name", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -15405,7 +15405,7 @@ CreateShareEndpoint( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, url: UriLocation { protocol: "http", @@ -15446,7 +15446,7 @@ CreateShareEndpoint( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, url: UriLocation { protocol: "http", @@ -15487,7 +15487,7 @@ CreateShare( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, comment: Some( "share comment", @@ -15510,7 +15510,7 @@ CreateShare( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, comment: None, }, @@ -15531,7 +15531,7 @@ DropShare( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -15551,7 +15551,7 @@ DropShare( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -15570,7 +15570,7 @@ GrantShareObject( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, object: Database( Identifier { @@ -15579,7 +15579,7 @@ GrantShareObject( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, ), privilege: Usage, @@ -15600,7 +15600,7 @@ GrantShareObject( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, object: Table( Identifier { @@ -15609,7 +15609,7 @@ GrantShareObject( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -15617,7 +15617,7 @@ GrantShareObject( ), name: "tb1", quote: None, - is_hole: false, + ident_type: None, }, ), privilege: Select, @@ -15835,7 +15835,7 @@ RevokeShareObject( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, object: Database( Identifier { @@ -15844,7 +15844,7 @@ RevokeShareObject( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, ), privilege: Usage, @@ -15865,7 +15865,7 @@ RevokeShareObject( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, object: Table( Identifier { @@ -15874,7 +15874,7 @@ RevokeShareObject( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -15882,7 +15882,7 @@ RevokeShareObject( ), name: "tb1", quote: None, - is_hole: false, + ident_type: None, }, ), privilege: Select, @@ -15903,7 +15903,7 @@ AlterShareTenants( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, if_exists: false, tenants: [ @@ -15913,7 +15913,7 @@ AlterShareTenants( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -15921,7 +15921,7 @@ AlterShareTenants( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ], is_add: true, @@ -15942,7 +15942,7 @@ AlterShareTenants( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, if_exists: true, tenants: [ @@ -15952,7 +15952,7 @@ AlterShareTenants( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -15960,7 +15960,7 @@ AlterShareTenants( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ], is_add: true, @@ -15981,7 +15981,7 @@ AlterShareTenants( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, if_exists: true, tenants: [ @@ -15991,7 +15991,7 @@ AlterShareTenants( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -15999,7 +15999,7 @@ AlterShareTenants( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ], is_add: false, @@ -16020,7 +16020,7 @@ DescShare( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -16039,7 +16039,7 @@ DescShare( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -16130,7 +16130,7 @@ Update( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -16139,7 +16139,7 @@ Update( ), name: "tb1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -16156,7 +16156,7 @@ Update( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, expr: BinaryOp { span: Some( @@ -16177,7 +16177,7 @@ Update( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -16199,7 +16199,7 @@ Update( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, expr: Literal { span: Some( @@ -16231,7 +16231,7 @@ Update( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -16289,7 +16289,7 @@ Query( ), name: "getvariable", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -16334,6 +16334,65 @@ Query( ) +---------- Input ---------- +select IDENTIFIER($abc) +---------- Output --------- +SELECT IDENTIFIER($abc) +---------- AST ------------ +Query( + Query { + span: Some( + 0..23, + ), + with: None, + body: Select( + SelectStmt { + span: Some( + 0..23, + ), + hints: None, + distinct: false, + top_n: None, + select_list: [ + AliasedExpr { + expr: ColumnRef { + span: Some( + 7..23, + ), + column: ColumnRef { + database: None, + table: None, + column: Name( + Identifier { + span: Some( + 7..23, + ), + name: "abc", + quote: None, + ident_type: Variable, + }, + ), + }, + }, + alias: None, + }, + ], + from: [], + selection: None, + group_by: None, + having: None, + window_list: None, + qualify: None, + }, + ), + order_by: [], + limit: [], + offset: None, + ignore_result: false, + }, +) + + ---------- Input ---------- SET max_threads = 10; ---------- Output --------- @@ -16348,7 +16407,7 @@ SetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, ], values: Expr( @@ -16380,7 +16439,7 @@ SetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, ], values: Expr( @@ -16426,7 +16485,7 @@ SetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -16434,7 +16493,7 @@ SetStmt { ), name: "max_memory_usage", quote: None, - is_hole: false, + ident_type: None, }, ], values: Expr( @@ -16502,7 +16561,7 @@ UnSetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, ], } @@ -16522,7 +16581,7 @@ UnSetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, ], } @@ -16542,7 +16601,7 @@ UnSetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -16550,7 +16609,7 @@ UnSetStmt { ), name: "sql_dialect", quote: None, - is_hole: false, + ident_type: None, }, ], } @@ -16570,7 +16629,7 @@ UnSetStmt { ), name: "max_threads", quote: None, - is_hole: false, + ident_type: None, }, Identifier { span: Some( @@ -16578,7 +16637,7 @@ UnSetStmt { ), name: "sql_dialect", quote: None, - is_hole: false, + ident_type: None, }, ], } @@ -16598,7 +16657,7 @@ SetStmt { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], values: Expr( @@ -16630,7 +16689,7 @@ SetStmt { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], values: Query( @@ -16691,7 +16750,7 @@ SetStmt { ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ], values: Expr( @@ -16728,7 +16787,7 @@ SetStmt { ), name: "max", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -16745,7 +16804,7 @@ SetStmt { ), name: "number", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -16771,7 +16830,7 @@ SetStmt { ), name: "numbers", quote: None, - is_hole: false, + ident_type: None, }, params: [ Literal { @@ -16915,7 +16974,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -16925,7 +16984,7 @@ Query( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -16962,7 +17021,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -17020,7 +17079,7 @@ Query( ), name: "table0", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -17030,7 +17089,7 @@ Query( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17051,7 +17110,7 @@ Query( ), name: "table1", quote: None, - is_hole: false, + ident_type: None, }, ), column: Name( @@ -17061,7 +17120,7 @@ Query( ), name: "c2", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17105,7 +17164,7 @@ Query( ), name: "table0", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -17123,7 +17182,7 @@ Query( ), name: "table1", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -17185,7 +17244,7 @@ Query( ), name: "c1", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17228,7 +17287,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -17369,7 +17428,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -17398,7 +17457,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17419,7 +17478,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17440,7 +17499,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17461,7 +17520,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17527,7 +17586,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -17556,7 +17615,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17577,7 +17636,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17598,7 +17657,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17617,7 +17676,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17683,7 +17742,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -17712,7 +17771,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17731,7 +17790,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17752,7 +17811,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17773,7 +17832,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17792,7 +17851,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17858,7 +17917,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -17887,7 +17946,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17906,7 +17965,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17928,7 +17987,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -17947,7 +18006,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18013,7 +18072,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -18041,7 +18100,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18060,7 +18119,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18079,7 +18138,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18144,7 +18203,7 @@ Query( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -18172,7 +18231,7 @@ Query( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18191,7 +18250,7 @@ Query( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18210,7 +18269,7 @@ Query( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18270,7 +18329,7 @@ CreateDatamaskPolicy( ), name: "current_role", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -18306,7 +18365,7 @@ CreateDatamaskPolicy( ), name: "VAL", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18370,7 +18429,7 @@ CreateDatamaskPolicy( ), name: "current_role", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -18406,7 +18465,7 @@ CreateDatamaskPolicy( ), name: "VAL", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18472,7 +18531,7 @@ CreateVirtualColumn( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, virtual_columns: [ MapAccess { @@ -18497,7 +18556,7 @@ CreateVirtualColumn( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18546,7 +18605,7 @@ CreateVirtualColumn( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18594,7 +18653,7 @@ CreateVirtualColumn( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, virtual_columns: [ MapAccess { @@ -18619,7 +18678,7 @@ CreateVirtualColumn( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18668,7 +18727,7 @@ CreateVirtualColumn( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18716,7 +18775,7 @@ AlterVirtualColumn( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, virtual_columns: [ MapAccess { @@ -18741,7 +18800,7 @@ AlterVirtualColumn( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18790,7 +18849,7 @@ AlterVirtualColumn( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -18838,7 +18897,7 @@ DropVirtualColumn( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -18859,7 +18918,7 @@ RefreshVirtualColumn( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -18964,7 +19023,7 @@ CreateDynamicTable( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -18973,7 +19032,7 @@ CreateDynamicTable( ), name: "MyDynamic", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Like { @@ -18985,7 +19044,7 @@ CreateDynamicTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -19041,7 +19100,7 @@ CreateDynamicTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -19091,7 +19150,7 @@ CreateDynamicTable( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -19100,7 +19159,7 @@ CreateDynamicTable( ), name: "MyDynamic", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -19112,7 +19171,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -19125,7 +19184,7 @@ CreateDynamicTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -19187,7 +19246,7 @@ CreateDynamicTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -19237,7 +19296,7 @@ CreateDynamicTable( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -19246,7 +19305,7 @@ CreateDynamicTable( ), name: "MyDynamic", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -19258,7 +19317,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -19271,7 +19330,7 @@ CreateDynamicTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -19296,7 +19355,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19343,7 +19402,7 @@ CreateDynamicTable( ), name: "c", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19365,7 +19424,7 @@ CreateDynamicTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19386,7 +19445,7 @@ CreateDynamicTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -19433,7 +19492,7 @@ CreateDynamicTable( ), name: "MyDynamic", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -19445,7 +19504,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -19458,7 +19517,7 @@ CreateDynamicTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -19483,7 +19542,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19525,7 +19584,7 @@ CreateDynamicTable( ), name: "avg", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -19542,7 +19601,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19570,7 +19629,7 @@ CreateDynamicTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19591,7 +19650,7 @@ CreateDynamicTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -19619,7 +19678,7 @@ CreateDynamicTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19663,7 +19722,7 @@ CreateDynamicTable( ), name: "MyDynamic", quote: None, - is_hole: false, + ident_type: None, }, source: Some( Columns( @@ -19675,7 +19734,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int32, expr: None, @@ -19688,7 +19747,7 @@ CreateDynamicTable( ), name: "b", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -19713,7 +19772,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19753,7 +19812,7 @@ CreateDynamicTable( ), name: "avg", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -19770,7 +19829,7 @@ CreateDynamicTable( ), name: "a", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19798,7 +19857,7 @@ CreateDynamicTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -19819,7 +19878,7 @@ CreateDynamicTable( ), name: "db", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -19828,7 +19887,7 @@ CreateDynamicTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -19856,7 +19915,7 @@ CreateDynamicTable( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -20130,7 +20189,7 @@ CreateTask( ), name: "SYSTEM$GET_PREDECESSOR_RETURN_VALUE", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -20630,7 +20689,7 @@ AlterTask( ), name: "SYSTEM$GET_PREDECESSOR_RETURN_VALUE", quote: None, - is_hole: false, + ident_type: None, }, args: [ Literal { @@ -20723,7 +20782,7 @@ CreateConnection( ), name: "my_conn", quote: None, - is_hole: false, + ident_type: None, }, storage_type: "s3", storage_params: {}, @@ -20745,7 +20804,7 @@ CreateConnection( ), name: "my_conn", quote: None, - is_hole: false, + ident_type: None, }, storage_type: "s3", storage_params: { @@ -20769,7 +20828,7 @@ CreateConnection( ), name: "my_conn", quote: None, - is_hole: false, + ident_type: None, }, storage_type: "s3", storage_params: { @@ -20794,7 +20853,7 @@ DropConnection( ), name: "my_conn", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -20813,7 +20872,7 @@ DescribeConnection( ), name: "my_conn", quote: None, - is_hole: false, + ident_type: None, }, }, ) @@ -20869,7 +20928,7 @@ CreatePipe( ), name: "MyTable1", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -20924,7 +20983,7 @@ CreatePipe( ), name: "db1", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -20933,7 +20992,7 @@ CreatePipe( ), name: "MyTable1", quote: None, - is_hole: false, + ident_type: None, }, }, dst_columns: None, @@ -21402,7 +21461,7 @@ Query( ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -21419,7 +21478,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -21438,7 +21497,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -21467,7 +21526,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -21525,7 +21584,7 @@ Query( ), name: "first_value", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -21542,7 +21601,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -21561,7 +21620,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -21590,7 +21649,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -21648,7 +21707,7 @@ Query( ), name: "first_value", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -21665,7 +21724,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -21686,7 +21745,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -21715,7 +21774,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -21773,7 +21832,7 @@ Query( ), name: "first_value", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -21790,7 +21849,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -21811,7 +21870,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -21840,7 +21899,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -21898,7 +21957,7 @@ Query( ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -21915,7 +21974,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -21936,7 +21995,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, ), partition_by: [], @@ -21965,7 +22024,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -22023,7 +22082,7 @@ Query( ), name: "sum", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -22040,7 +22099,7 @@ Query( ), name: "d", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22058,7 +22117,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, }, ), @@ -22083,7 +22142,7 @@ Query( ), name: "e", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -22105,7 +22164,7 @@ Query( ), name: "w", quote: None, - is_hole: false, + ident_type: None, }, spec: WindowSpec { existing_window_name: None, @@ -22124,7 +22183,7 @@ Query( ), name: "f", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22146,7 +22205,7 @@ Query( ), name: "g", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22279,7 +22338,7 @@ AttachTable( ), name: "t", quote: None, - is_hole: false, + ident_type: None, }, uri_location: UriLocation { protocol: "s3", @@ -22313,7 +22372,7 @@ CreateUDF( ), name: "isnotempty", quote: None, - is_hole: false, + ident_type: None, }, description: None, definition: LambdaUDF { @@ -22324,7 +22383,7 @@ CreateUDF( ), name: "p", quote: None, - is_hole: false, + ident_type: None, }, ], definition: UnaryOp { @@ -22344,7 +22403,7 @@ CreateUDF( ), name: "is_null", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -22361,7 +22420,7 @@ CreateUDF( ), name: "p", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22392,7 +22451,7 @@ CreateUDF( ), name: "isnotempty_test_replace", quote: None, - is_hole: false, + ident_type: None, }, description: Some( "This is a description", @@ -22405,7 +22464,7 @@ CreateUDF( ), name: "p", quote: None, - is_hole: false, + ident_type: None, }, ], definition: UnaryOp { @@ -22425,7 +22484,7 @@ CreateUDF( ), name: "is_null", quote: None, - is_hole: false, + ident_type: None, }, args: [ ColumnRef { @@ -22442,7 +22501,7 @@ CreateUDF( ), name: "p", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22473,7 +22532,7 @@ CreateUDF( ), name: "binary_reverse", quote: None, - is_hole: false, + ident_type: None, }, description: None, definition: UDFServer { @@ -22507,7 +22566,7 @@ CreateUDF( ), name: "binary_reverse", quote: None, - is_hole: false, + ident_type: None, }, description: None, definition: UDFServer { @@ -22640,7 +22699,7 @@ CreateUDF( ), name: "addone", quote: None, - is_hole: false, + ident_type: None, }, description: None, definition: UDFScript { @@ -22681,7 +22740,7 @@ CreateUDF( ), name: "addone", quote: None, - is_hole: false, + ident_type: None, }, description: None, definition: UDFScript { @@ -22715,7 +22774,7 @@ DropUDF { ), name: "binary_reverse", quote: None, - is_hole: false, + ident_type: None, }, } @@ -22733,7 +22792,7 @@ DropUDF { ), name: "isnotempty", quote: None, - is_hole: false, + ident_type: None, }, } @@ -22800,7 +22859,7 @@ Query( ), name: "abc", quote: None, - is_hole: false, + ident_type: None, }, columns: [], }, @@ -22834,7 +22893,7 @@ Query( ), name: "id", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22856,7 +22915,7 @@ Query( ), name: "uid", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22878,7 +22937,7 @@ Query( ), name: "eid", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22900,7 +22959,7 @@ Query( ), name: "match_id", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22922,7 +22981,7 @@ Query( ), name: "created_at", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22944,7 +23003,7 @@ Query( ), name: "updated_at", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -22996,7 +23055,7 @@ Query( ), name: "ddd", quote: None, - is_hole: false, + ident_type: None, }, ), table: Identifier { @@ -23005,7 +23064,7 @@ Query( ), name: "ccc", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -23035,7 +23094,7 @@ Query( ), name: "score", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -23095,7 +23154,7 @@ Query( ), name: "row_number", quote: None, - is_hole: false, + ident_type: None, }, args: [], params: [], @@ -23120,7 +23179,7 @@ Query( ), name: "uid", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -23139,7 +23198,7 @@ Query( ), name: "eid", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -23161,7 +23220,7 @@ Query( ), name: "updated_at", quote: None, - is_hole: false, + ident_type: None, }, ), }, @@ -23234,7 +23293,7 @@ Query( ), name: "abc", quote: None, - is_hole: false, + ident_type: None, }, alias: None, temporal: None, @@ -23281,7 +23340,7 @@ CreateDictionary( ), name: "my_catalog", quote: None, - is_hole: false, + ident_type: None, }, ), database: Some( @@ -23291,7 +23350,7 @@ CreateDictionary( ), name: "my_database", quote: None, - is_hole: false, + ident_type: None, }, ), dictionary_name: Identifier { @@ -23300,7 +23359,7 @@ CreateDictionary( ), name: "my_dictionary", quote: None, - is_hole: false, + ident_type: None, }, columns: [ ColumnDefinition { @@ -23310,7 +23369,7 @@ CreateDictionary( ), name: "user_name", quote: None, - is_hole: false, + ident_type: None, }, data_type: String, expr: None, @@ -23323,7 +23382,7 @@ CreateDictionary( ), name: "age", quote: None, - is_hole: false, + ident_type: None, }, data_type: Int16, expr: None, @@ -23337,7 +23396,7 @@ CreateDictionary( ), name: "username", quote: None, - is_hole: false, + ident_type: None, }, ], source_name: Identifier { @@ -23346,7 +23405,7 @@ CreateDictionary( ), name: "mysql", quote: None, - is_hole: false, + ident_type: None, }, source_options: { "host": "localhost", diff --git a/src/query/script/src/compiler.rs b/src/query/script/src/compiler.rs index 4663b4ec1bd0..b1e8f800e0ae 100644 --- a/src/query/script/src/compiler.rs +++ b/src/query/script/src/compiler.rs @@ -23,6 +23,7 @@ use databend_common_ast::ast::ColumnRef; use databend_common_ast::ast::Expr; use databend_common_ast::ast::FunctionCall; use databend_common_ast::ast::Identifier; +use databend_common_ast::ast::IdentifierType; use databend_common_ast::ast::Indirection; use databend_common_ast::ast::Literal; use databend_common_ast::ast::Query; @@ -769,12 +770,12 @@ impl Compiler { } fn enter_identifier(&mut self, ident: &mut Identifier) { - if ident.is_hole { + if ident.is_hole() { let index = self.compiler.lookup_var(ident); match index { Ok(index) => { *ident = Identifier::from_name(ident.span, index.to_string()); - ident.is_hole = true; + ident.ident_type = IdentifierType::Hole; } Err(e) => { self.error = Some(e.set_span(ident.span)); @@ -1032,7 +1033,7 @@ impl Compiler { } fn enter_identifier(&mut self, ident: &mut Identifier) { - if ident.is_hole { + if ident.is_hole() { self.error = Some( ErrorCode::ScriptSemanticError( "variable is not allowed in this context".to_string(), diff --git a/src/query/script/src/ir.rs b/src/query/script/src/ir.rs index 84237836de92..4028ef215ec8 100644 --- a/src/query/script/src/ir.rs +++ b/src/query/script/src/ir.rs @@ -184,7 +184,7 @@ impl StatementTemplate { } fn enter_identifier(&mut self, ident: &mut Identifier) { - if ident.is_hole { + if ident.is_hole() { let index = ident.name.parse::().unwrap(); let value = (self.lookup_var)(VarRef::placeholder(index)); match value { diff --git a/src/query/sql/src/planner/binder/util.rs b/src/query/sql/src/planner/binder/util.rs index e745a2f7ea4a..f082224649b4 100644 --- a/src/query/sql/src/planner/binder/util.rs +++ b/src/query/sql/src/planner/binder/util.rs @@ -14,6 +14,7 @@ use databend_common_ast::ast::quote::QuotedIdent; use databend_common_ast::ast::Identifier; +use databend_common_ast::ast::IdentifierType; use databend_common_ast::ast::TableAlias; use databend_common_ast::parser::Dialect; use databend_common_ast::span::merge_span; @@ -125,13 +126,13 @@ impl TableIdentifier { span: None, name: ctx.get_current_catalog(), quote: Some(dialect.default_ident_quote()), - is_hole: false, + ident_type: IdentifierType::None, }); let database = database.to_owned().unwrap_or(Identifier { span: None, name: ctx.get_current_database(), quote: Some(dialect.default_ident_quote()), - is_hole: false, + ident_type: IdentifierType::None, }); let database = Identifier { span: merge_span(catalog.span, database.span), diff --git a/src/query/sql/src/planner/planner.rs b/src/query/sql/src/planner/planner.rs index 0d3691fffe02..91a0d864e2aa 100644 --- a/src/query/sql/src/planner/planner.rs +++ b/src/query/sql/src/planner/planner.rs @@ -47,6 +47,7 @@ use crate::CountSetOps; use crate::Metadata; use crate::MetadataRef; use crate::NameResolutionContext; +use crate::VariableNormalizer; const PROBE_INSERT_INITIAL_TOKENS: usize = 128; const PROBE_INSERT_MAX_TOKENS: usize = 128 * 8; @@ -241,6 +242,15 @@ impl Planner { } fn replace_stmt(&self, stmt: &mut Statement) -> Result<()> { + let name_resolution_ctx = + NameResolutionContext::try_from(self.ctx.get_settings().as_ref())?; + + let mut variable_normalizer = + VariableNormalizer::new(&name_resolution_ctx, self.ctx.clone()); + + stmt.drive_mut(&mut variable_normalizer); + variable_normalizer.render_error()?; + stmt.drive_mut(&mut DistinctToGroupBy::default()); stmt.drive_mut(&mut AggregateRewriter); let mut set_ops_counter = CountSetOps::default(); diff --git a/src/query/sql/src/planner/semantic/mod.rs b/src/query/sql/src/planner/semantic/mod.rs index 4a67430ca3d2..016483b53b9b 100644 --- a/src/query/sql/src/planner/semantic/mod.rs +++ b/src/query/sql/src/planner/semantic/mod.rs @@ -40,6 +40,7 @@ pub use name_resolution::normalize_identifier; pub use name_resolution::IdentifierNormalizer; pub use name_resolution::NameResolutionContext; pub use name_resolution::NameResolutionSuggest; +pub use name_resolution::VariableNormalizer; pub use type_check::resolve_type_name; pub use type_check::resolve_type_name_by_str; pub use type_check::validate_function_arg; diff --git a/src/query/sql/src/planner/semantic/name_resolution.rs b/src/query/sql/src/planner/semantic/name_resolution.rs index 2b5934a2bf80..18a11505cd06 100644 --- a/src/query/sql/src/planner/semantic/name_resolution.rs +++ b/src/query/sql/src/planner/semantic/name_resolution.rs @@ -12,8 +12,15 @@ // See the License for the specific language governing permissions and // limitations under the License. +use std::sync::Arc; + use databend_common_ast::ast::quote::ident_needs_quote; use databend_common_ast::ast::Identifier; +use databend_common_ast::ast::IdentifierType; +use databend_common_catalog::table_context::TableContext; +use databend_common_exception::ErrorCode; +use databend_common_exception::Result; +use databend_common_expression::Scalar; use databend_common_settings::Settings; use derive_visitor::VisitorMut; @@ -108,3 +115,51 @@ impl<'a> IdentifierNormalizer<'a> { *ident = normalized_ident; } } + +#[derive(VisitorMut)] +#[visitor(Identifier(enter))] +pub struct VariableNormalizer<'a> { + pub ctx: &'a NameResolutionContext, + pub table_ctx: Arc, + error: Option, +} + +impl<'a> VariableNormalizer<'a> { + pub fn new(ctx: &'a NameResolutionContext, table_ctx: Arc) -> Self { + Self { + ctx, + table_ctx, + error: None, + } + } + + pub fn render_error(&self) -> Result<()> { + match &self.error { + Some(e) => Err(e.clone()), + None => Ok(()), + } + } + + fn enter_identifier(&mut self, ident: &mut Identifier) { + if ident.is_variable() { + let mut normalized_ident = normalize_identifier(ident, self.ctx); + + let scalar = self.table_ctx.get_variable(&normalized_ident.name); + if let Some(Scalar::String(s)) = scalar { + normalized_ident.name = s; + normalized_ident.ident_type = IdentifierType::None; + } else { + self.error = Some(ErrorCode::SemanticError(format!( + "invalid variable identifier {} in session", + normalized_ident.name + ))); + } + *ident = normalized_ident; + } else if ident.is_hole() { + self.error = Some(ErrorCode::SemanticError(format!( + "invalid hole identifier {}, maybe you want to use ${}", + ident.name, ident.name, + ))); + } + } +} diff --git a/tests/sqllogictests/suites/mode/standalone/explain/table_sample.test b/tests/sqllogictests/suites/mode/standalone/explain/table_sample.test index edef379843a8..6fe74a7d2172 100644 --- a/tests/sqllogictests/suites/mode/standalone/explain/table_sample.test +++ b/tests/sqllogictests/suites/mode/standalone/explain/table_sample.test @@ -1,42 +1,42 @@ statement ok create or replace table t as select number as a from numbers(1000); -query T -explain select * from t sample row (10 rows); ----- -Filter -├── output columns: [t.a (#0)] -├── filters: [rand() <= 0.01] -├── estimated rows: 200.00 -└── TableScan - ├── table: default.default.t - ├── output columns: [a (#0)] - ├── read rows: 1000 - ├── read size: 1.40 KiB - ├── partitions total: 1 - ├── partitions scanned: 1 - ├── pruning stats: [segments: , blocks: ] - ├── push downs: [filters: [rand() <= 0.01], limit: NONE] - └── estimated rows: 1000.00 - -query T -explain select * from t sample row (99.1); ----- -Filter -├── output columns: [t.a (#0)] -├── filters: [rand() <= 0.991] -├── estimated rows: 200.00 -└── TableScan - ├── table: default.default.t - ├── output columns: [a (#0)] - ├── read rows: 1000 - ├── read size: 1.40 KiB - ├── partitions total: 1 - ├── partitions scanned: 1 - ├── pruning stats: [segments: , blocks: ] - ├── push downs: [filters: [rand() <= 0.991], limit: NONE] - └── estimated rows: 1000.00 - +## query T +## explain select * from t sample row (10 rows); +## ---- +## Filter +## ├── output columns: [t.a (#0)] +## ├── filters: [rand() <= 0.01] +## ├── estimated rows: 200.00 +## └── TableScan +## ├── table: default.default.t +## ├── output columns: [a (#0)] +## ├── read rows: 1000 +## ├── read size: 1.40 KiB +## ├── partitions total: 1 +## ├── partitions scanned: 1 +## ├── pruning stats: [segments: , blocks: ] +## ├── push downs: [filters: [rand() <= 0.01], limit: NONE] +## └── estimated rows: 1000.00 +## +## query T +## explain select * from t sample row (99.1); +## ---- +## Filter +## ├── output columns: [t.a (#0)] +## ├── filters: [rand() <= 0.991] +## ├── estimated rows: 200.00 +## └── TableScan +## ├── table: default.default.t +## ├── output columns: [a (#0)] +## ├── read rows: 1000 +## ├── read size: 1.40 KiB +## ├── partitions total: 1 +## ├── partitions scanned: 1 +## ├── pruning stats: [segments: , blocks: ] +## ├── push downs: [filters: [rand() <= 0.991], limit: NONE] +## └── estimated rows: 1000.00 +## statement ok drop table t; diff --git a/tests/sqllogictests/suites/query/set.test b/tests/sqllogictests/suites/query/set.test index 5d7e0bdc0cc3..2bfd15affc63 100644 --- a/tests/sqllogictests/suites/query/set.test +++ b/tests/sqllogictests/suites/query/set.test @@ -50,3 +50,17 @@ NULL NULL xxyyzz NULL statement ok unset variable (a, b, c) + +statement ok +CREATE OR REPLACE TABLE monthly_sales(empid INT, amount INT, month TEXT) as select 1,2,'3'; + +statement ok +set variable t = 'monthly_sales'; + +query IIT +select * from identifier($t); +---- +1 2 3 + +statement ok +DROP TABLE monthly_sales diff --git a/tests/suites/0_stateless/18_rbac/18_0006_mysql_auth.py b/tests/suites/0_stateless/18_rbac/18_0006_mysql_auth.py index bd523b5d17b3..59d6ed1bf5d2 100755 --- a/tests/suites/0_stateless/18_rbac/18_0006_mysql_auth.py +++ b/tests/suites/0_stateless/18_rbac/18_0006_mysql_auth.py @@ -39,12 +39,8 @@ cursor.execute( "create user u4 identified by 'abc123' with must_change_password = true;" ) - cursor.execute( - "create user u5 identified by 'abc123';" - ) - cursor.execute( - "alter user u5 with must_change_password = true;" - ) + cursor.execute("create user u5 identified by 'abc123';") + cursor.execute("alter user u5 with must_change_password = true;") except mysql.connector.errors.OperationalError: print("root@127.0.0.1 is timeout")