1#[cfg(not(feature = "std"))]
20use alloc::{
21 boxed::Box,
22 format,
23 string::{String, ToString},
24 vec,
25 vec::Vec,
26};
27use helpers::{
28 attached_token::AttachedToken,
29 stmt_data_loading::{FileStagingCommand, StageLoadSelectItemKind},
30};
31
32use core::cmp::Ordering;
33use core::ops::Deref;
34use core::{
35 fmt::{self, Display},
36 hash,
37};
38
39#[cfg(feature = "serde")]
40use serde::{Deserialize, Serialize};
41
42#[cfg(feature = "visitor")]
43use sqlparser_derive::{Visit, VisitMut};
44
45use crate::{
46 display_utils::SpaceOrNewline,
47 tokenizer::{Span, Token},
48};
49use crate::{
50 display_utils::{Indent, NewLine},
51 keywords::Keyword,
52};
53
54pub use self::data_type::{
55 ArrayElemTypeDef, BinaryLength, CharLengthUnits, CharacterLength, DataType, EnumMember,
56 ExactNumberInfo, IntervalFields, StructBracketKind, TimezoneInfo,
57};
58pub use self::dcl::{
59 AlterRoleOperation, CreateRole, Grant, ResetConfig, Revoke, RoleOption, SecondaryRoles,
60 SetConfigValue, Use,
61};
62pub use self::ddl::{
63 Alignment, AlterColumnOperation, AlterConnectorOwner, AlterIndexOperation, AlterOperator,
64 AlterOperatorClass, AlterOperatorClassOperation, AlterOperatorFamily,
65 AlterOperatorFamilyOperation, AlterOperatorOperation, AlterPolicy, AlterPolicyOperation,
66 AlterSchema, AlterSchemaOperation, AlterTable, AlterTableAlgorithm, AlterTableLock,
67 AlterTableOperation, AlterTableType, AlterType, AlterTypeAddValue, AlterTypeAddValuePosition,
68 AlterTypeOperation, AlterTypeRename, AlterTypeRenameValue, ClusteredBy, ColumnDef,
69 ColumnOption, ColumnOptionDef, ColumnOptions, ColumnPolicy, ColumnPolicyProperty,
70 ConstraintCharacteristics, CreateConnector, CreateDomain, CreateExtension, CreateFunction,
71 CreateIndex, CreateOperator, CreateOperatorClass, CreateOperatorFamily, CreatePolicy,
72 CreatePolicyCommand, CreatePolicyType, CreateTable, CreateTrigger, CreateView, Deduplicate,
73 DeferrableInitial, DropBehavior, DropExtension, DropFunction, DropOperator, DropOperatorClass,
74 DropOperatorFamily, DropOperatorSignature, DropPolicy, DropTrigger, ForValues, GeneratedAs,
75 GeneratedExpressionMode, IdentityParameters, IdentityProperty, IdentityPropertyFormatKind,
76 IdentityPropertyKind, IdentityPropertyOrder, IndexColumn, IndexOption, IndexType,
77 KeyOrIndexDisplay, Msck, NullsDistinctOption, OperatorArgTypes, OperatorClassItem,
78 OperatorFamilyDropItem, OperatorFamilyItem, OperatorOption, OperatorPurpose, Owner, Partition,
79 PartitionBoundValue, ProcedureParam, ReferentialAction, RenameTableNameKind, ReplicaIdentity,
80 TagsColumnOption, TriggerObjectKind, Truncate, UserDefinedTypeCompositeAttributeDef,
81 UserDefinedTypeInternalLength, UserDefinedTypeRangeOption, UserDefinedTypeRepresentation,
82 UserDefinedTypeSqlDefinitionOption, UserDefinedTypeStorage, ViewColumnDef,
83};
84pub use self::dml::{
85 Delete, Insert, Merge, MergeAction, MergeClause, MergeClauseKind, MergeInsertExpr,
86 MergeInsertKind, MergeUpdateExpr, OutputClause, Update,
87};
88pub use self::operator::{BinaryOperator, UnaryOperator};
89pub use self::query::{
90 AfterMatchSkip, ConnectByKind, Cte, CteAsMaterialized, Distinct, EmptyMatchesMode,
91 ExceptSelectItem, ExcludeSelectItem, ExprWithAlias, ExprWithAliasAndOrderBy, Fetch, ForClause,
92 ForJson, ForXml, FormatClause, GroupByExpr, GroupByWithModifier, IdentWithAlias,
93 IlikeSelectItem, InputFormatClause, Interpolate, InterpolateExpr, Join, JoinConstraint,
94 JoinOperator, JsonTableColumn, JsonTableColumnErrorHandling, JsonTableNamedColumn,
95 JsonTableNestedColumn, LateralView, LimitClause, LockClause, LockType, MatchRecognizePattern,
96 MatchRecognizeSymbol, Measure, NamedWindowDefinition, NamedWindowExpr, NonBlock, Offset,
97 OffsetRows, OpenJsonTableColumn, OrderBy, OrderByExpr, OrderByKind, OrderByOptions,
98 PipeOperator, PivotValueSource, ProjectionSelect, Query, RenameSelectItem,
99 RepetitionQuantifier, ReplaceSelectElement, ReplaceSelectItem, RowsPerMatch, Select,
100 SelectFlavor, SelectInto, SelectItem, SelectItemQualifiedWildcardKind, SelectModifiers,
101 SetExpr, SetOperator, SetQuantifier, Setting, SymbolDefinition, Table, TableAlias,
102 TableAliasColumnDef, TableFactor, TableFunctionArgs, TableIndexHintForClause,
103 TableIndexHintType, TableIndexHints, TableIndexType, TableSample, TableSampleBucket,
104 TableSampleKind, TableSampleMethod, TableSampleModifier, TableSampleQuantity, TableSampleSeed,
105 TableSampleSeedModifier, TableSampleUnit, TableVersion, TableWithJoins, Top, TopQuantity,
106 UpdateTableFromKind, ValueTableMode, Values, WildcardAdditionalOptions, With, WithFill,
107 XmlNamespaceDefinition, XmlPassingArgument, XmlPassingClause, XmlTableColumn,
108 XmlTableColumnOption,
109};
110
111pub use self::trigger::{
112 TriggerEvent, TriggerExecBody, TriggerExecBodyType, TriggerObject, TriggerPeriod,
113 TriggerReferencing, TriggerReferencingType,
114};
115
116pub use self::value::{
117 escape_double_quote_string, escape_quoted_string, DateTimeField, DollarQuotedString,
118 NormalizationForm, QuoteDelimitedString, TrimWhereField, Value, ValueWithSpan,
119};
120
121use crate::ast::helpers::key_value_options::KeyValueOptions;
122use crate::ast::helpers::stmt_data_loading::StageParamsObject;
123
124#[cfg(feature = "visitor")]
125pub use visitor::*;
126
127pub use self::data_type::GeometricTypeKind;
128
129mod data_type;
130mod dcl;
131mod ddl;
132mod dml;
133pub mod helpers;
135pub mod table_constraints;
136pub use table_constraints::{
137 CheckConstraint, ForeignKeyConstraint, FullTextOrSpatialConstraint, IndexConstraint,
138 PrimaryKeyConstraint, TableConstraint, UniqueConstraint,
139};
140mod operator;
141mod query;
142mod spans;
143pub use spans::Spanned;
144
145pub mod comments;
146mod trigger;
147mod value;
148
149#[cfg(feature = "visitor")]
150mod visitor;
151
152pub struct DisplaySeparated<'a, T>
154where
155 T: fmt::Display,
156{
157 slice: &'a [T],
158 sep: &'static str,
159}
160
161impl<T> fmt::Display for DisplaySeparated<'_, T>
162where
163 T: fmt::Display,
164{
165 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
166 let mut delim = "";
167 for t in self.slice {
168 f.write_str(delim)?;
169 delim = self.sep;
170 t.fmt(f)?;
171 }
172 Ok(())
173 }
174}
175
176pub(crate) fn display_separated<'a, T>(slice: &'a [T], sep: &'static str) -> DisplaySeparated<'a, T>
177where
178 T: fmt::Display,
179{
180 DisplaySeparated { slice, sep }
181}
182
183pub(crate) fn display_comma_separated<T>(slice: &[T]) -> DisplaySeparated<'_, T>
184where
185 T: fmt::Display,
186{
187 DisplaySeparated { slice, sep: ", " }
188}
189
190fn format_statement_list(f: &mut fmt::Formatter, statements: &[Statement]) -> fmt::Result {
193 f.write_fmt(format_args!("{0}", display_separated(statements, "; ")))write!(f, "{}", display_separated(statements, "; "))?;
194 f.write_fmt(format_args!(";"))write!(f, ";")
197}
198
199#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Ident {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "Ident",
"value", &self.value, "quote_style", &self.quote_style, "span",
&&self.span)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Ident {
#[inline]
fn clone(&self) -> Ident {
Ident {
value: ::core::clone::Clone::clone(&self.value),
quote_style: ::core::clone::Clone::clone(&self.quote_style),
span: ::core::clone::Clone::clone(&self.span),
}
}
}Clone)]
201#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
202#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Ident {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.value, visitor)?;
sqlparser::ast::Visit::visit(&self.quote_style, visitor)?;
sqlparser::ast::Visit::visit(&self.span, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Ident {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.quote_style,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.span, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
203pub struct Ident {
204 pub value: String,
206 pub quote_style: Option<char>,
209 pub span: Span,
211}
212
213impl PartialEq for Ident {
214 fn eq(&self, other: &Self) -> bool {
215 let Ident {
216 value,
217 quote_style,
218 span: _,
220 } = self;
221
222 value == &other.value && quote_style == &other.quote_style
223 }
224}
225
226impl core::hash::Hash for Ident {
227 fn hash<H: hash::Hasher>(&self, state: &mut H) {
228 let Ident {
229 value,
230 quote_style,
231 span: _,
233 } = self;
234
235 value.hash(state);
236 quote_style.hash(state);
237 }
238}
239
240impl Eq for Ident {}
241
242impl PartialOrd for Ident {
243 fn partial_cmp(&self, other: &Self) -> Option<Ordering> {
244 Some(self.cmp(other))
245 }
246}
247
248impl Ord for Ident {
249 fn cmp(&self, other: &Self) -> Ordering {
250 let Ident {
251 value,
252 quote_style,
253 span: _,
255 } = self;
256
257 let Ident {
258 value: other_value,
259 quote_style: other_quote_style,
260 span: _,
262 } = other;
263
264 value
266 .cmp(other_value)
267 .then_with(|| quote_style.cmp(other_quote_style))
268 }
269}
270
271impl Ident {
272 pub fn new<S>(value: S) -> Self
274 where
275 S: Into<String>,
276 {
277 Ident {
278 value: value.into(),
279 quote_style: None,
280 span: Span::empty(),
281 }
282 }
283
284 pub fn with_quote<S>(quote: char, value: S) -> Self
287 where
288 S: Into<String>,
289 {
290 if !(quote == '\'' || quote == '"' || quote == '`' || quote == '[') {
::core::panicking::panic("assertion failed: quote == \'\\\'\' || quote == \'\"\' || quote == \'`\' || quote == \'[\'")
};assert!(quote == '\'' || quote == '"' || quote == '`' || quote == '[');
291 Ident {
292 value: value.into(),
293 quote_style: Some(quote),
294 span: Span::empty(),
295 }
296 }
297
298 pub fn with_span<S>(span: Span, value: S) -> Self
300 where
301 S: Into<String>,
302 {
303 Ident {
304 value: value.into(),
305 quote_style: None,
306 span,
307 }
308 }
309
310 pub fn with_quote_and_span<S>(quote: char, span: Span, value: S) -> Self
312 where
313 S: Into<String>,
314 {
315 if !(quote == '\'' || quote == '"' || quote == '`' || quote == '[') {
::core::panicking::panic("assertion failed: quote == \'\\\'\' || quote == \'\"\' || quote == \'`\' || quote == \'[\'")
};assert!(quote == '\'' || quote == '"' || quote == '`' || quote == '[');
316 Ident {
317 value: value.into(),
318 quote_style: Some(quote),
319 span,
320 }
321 }
322}
323
324impl From<&str> for Ident {
325 fn from(value: &str) -> Self {
326 Ident {
327 value: value.to_string(),
328 quote_style: None,
329 span: Span::empty(),
330 }
331 }
332}
333
334impl fmt::Display for Ident {
335 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
336 match self.quote_style {
337 Some(q) if q == '"' || q == '\'' || q == '`' => {
338 let escaped = value::escape_quoted_string(&self.value, q);
339 f.write_fmt(format_args!("{0}{1}{0}", q, escaped))write!(f, "{q}{escaped}{q}")
340 }
341 Some('[') => f.write_fmt(format_args!("[{0}]", self.value))write!(f, "[{}]", self.value),
342 None => f.write_str(&self.value),
343 _ => { ::core::panicking::panic_fmt(format_args!("unexpected quote style")); }panic!("unexpected quote style"),
344 }
345 }
346}
347
348#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ObjectName {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_tuple_field1_finish(f, "ObjectName",
&&self.0)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ObjectName {
#[inline]
fn clone(&self) -> ObjectName {
ObjectName(::core::clone::Clone::clone(&self.0))
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ObjectName {
#[inline]
fn eq(&self, other: &ObjectName) -> bool { self.0 == other.0 }
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ObjectName {
#[inline]
fn partial_cmp(&self, other: &ObjectName)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ObjectName {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectNamePart>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ObjectName {
#[inline]
fn cmp(&self, other: &ObjectName) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.0, &other.0)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ObjectName {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.0, state)
}
}Hash)]
350#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
351#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ObjectName {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.0, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ObjectName {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.0, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
352pub struct ObjectName(pub Vec<ObjectNamePart>);
353
354impl From<Vec<Ident>> for ObjectName {
355 fn from(idents: Vec<Ident>) -> Self {
356 ObjectName(idents.into_iter().map(ObjectNamePart::Identifier).collect())
357 }
358}
359
360impl From<Ident> for ObjectName {
361 fn from(ident: Ident) -> Self {
362 ObjectName(::alloc::boxed::box_assume_init_into_vec_unsafe(::alloc::intrinsics::write_box_via_move(::alloc::boxed::Box::new_uninit(),
[ObjectNamePart::Identifier(ident)]))vec![ObjectNamePart::Identifier(ident)])
363 }
364}
365
366impl fmt::Display for ObjectName {
367 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
368 f.write_fmt(format_args!("{0}", display_separated(&self.0, ".")))write!(f, "{}", display_separated(&self.0, "."))
369 }
370}
371
372#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ObjectNamePart {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ObjectNamePart::Identifier(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Identifier", &__self_0),
ObjectNamePart::Function(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Function", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ObjectNamePart {
#[inline]
fn clone(&self) -> ObjectNamePart {
match self {
ObjectNamePart::Identifier(__self_0) =>
ObjectNamePart::Identifier(::core::clone::Clone::clone(__self_0)),
ObjectNamePart::Function(__self_0) =>
ObjectNamePart::Function(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ObjectNamePart {
#[inline]
fn eq(&self, other: &ObjectNamePart) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(ObjectNamePart::Identifier(__self_0),
ObjectNamePart::Identifier(__arg1_0)) =>
__self_0 == __arg1_0,
(ObjectNamePart::Function(__self_0),
ObjectNamePart::Function(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ObjectNamePart {
#[inline]
fn partial_cmp(&self, other: &ObjectNamePart)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ObjectNamePart {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<ObjectNamePartFunction>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ObjectNamePart {
#[inline]
fn cmp(&self, other: &ObjectNamePart) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(ObjectNamePart::Identifier(__self_0),
ObjectNamePart::Identifier(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ObjectNamePart::Function(__self_0),
ObjectNamePart::Function(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ObjectNamePart {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
ObjectNamePart::Identifier(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
ObjectNamePart::Function(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
374#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
375#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ObjectNamePart {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Identifier(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Function(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ObjectNamePart {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Identifier(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Function(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
376pub enum ObjectNamePart {
377 Identifier(Ident),
379 Function(ObjectNamePartFunction),
381}
382
383impl ObjectNamePart {
384 pub fn as_ident(&self) -> Option<&Ident> {
386 match self {
387 ObjectNamePart::Identifier(ident) => Some(ident),
388 ObjectNamePart::Function(_) => None,
389 }
390 }
391}
392
393impl fmt::Display for ObjectNamePart {
394 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
395 match self {
396 ObjectNamePart::Identifier(ident) => f.write_fmt(format_args!("{0}", ident))write!(f, "{ident}"),
397 ObjectNamePart::Function(func) => f.write_fmt(format_args!("{0}", func))write!(f, "{func}"),
398 }
399 }
400}
401
402#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ObjectNamePartFunction {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"ObjectNamePartFunction", "name", &self.name, "args", &&self.args)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ObjectNamePartFunction {
#[inline]
fn clone(&self) -> ObjectNamePartFunction {
ObjectNamePartFunction {
name: ::core::clone::Clone::clone(&self.name),
args: ::core::clone::Clone::clone(&self.args),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ObjectNamePartFunction {
#[inline]
fn eq(&self, other: &ObjectNamePartFunction) -> bool {
self.name == other.name && self.args == other.args
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ObjectNamePartFunction {
#[inline]
fn partial_cmp(&self, other: &ObjectNamePartFunction)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ObjectNamePartFunction {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Vec<FunctionArg>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ObjectNamePartFunction {
#[inline]
fn cmp(&self, other: &ObjectNamePartFunction) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.args, &other.args),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ObjectNamePartFunction {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.args, state)
}
}Hash)]
407#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
408#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ObjectNamePartFunction {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.args, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ObjectNamePartFunction {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.args, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
409pub struct ObjectNamePartFunction {
410 pub name: Ident,
412 pub args: Vec<FunctionArg>,
414}
415
416impl fmt::Display for ObjectNamePartFunction {
417 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
418 f.write_fmt(format_args!("{0}(", self.name))write!(f, "{}(", self.name)?;
419 f.write_fmt(format_args!("{0})", display_comma_separated(&self.args)))write!(f, "{})", display_comma_separated(&self.args))
420 }
421}
422
423#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Array {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "Array", "elem",
&self.elem, "named", &&self.named)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Array {
#[inline]
fn clone(&self) -> Array {
Array {
elem: ::core::clone::Clone::clone(&self.elem),
named: ::core::clone::Clone::clone(&self.named),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Array {
#[inline]
fn eq(&self, other: &Array) -> bool {
self.named == other.named && self.elem == other.elem
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Array {
#[inline]
fn partial_cmp(&self, other: &Array)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Array {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Array {
#[inline]
fn cmp(&self, other: &Array) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.elem, &other.elem) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.named, &other.named),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Array {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.elem, state);
::core::hash::Hash::hash(&self.named, state)
}
}Hash)]
426#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
427#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Array {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.elem, visitor)?;
sqlparser::ast::Visit::visit(&self.named, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Array {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.elem, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.named, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
428pub struct Array {
429 pub elem: Vec<Expr>,
431
432 pub named: bool,
434}
435
436impl fmt::Display for Array {
437 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
438 f.write_fmt(format_args!("{0}[{1}]", if self.named { "ARRAY" } else { "" },
display_comma_separated(&self.elem)))write!(
439 f,
440 "{}[{}]",
441 if self.named { "ARRAY" } else { "" },
442 display_comma_separated(&self.elem)
443 )
444 }
445}
446
447#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Interval {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field5_finish(f, "Interval",
"value", &self.value, "leading_field", &self.leading_field,
"leading_precision", &self.leading_precision, "last_field",
&self.last_field, "fractional_seconds_precision",
&&self.fractional_seconds_precision)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Interval {
#[inline]
fn clone(&self) -> Interval {
Interval {
value: ::core::clone::Clone::clone(&self.value),
leading_field: ::core::clone::Clone::clone(&self.leading_field),
leading_precision: ::core::clone::Clone::clone(&self.leading_precision),
last_field: ::core::clone::Clone::clone(&self.last_field),
fractional_seconds_precision: ::core::clone::Clone::clone(&self.fractional_seconds_precision),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Interval {
#[inline]
fn eq(&self, other: &Interval) -> bool {
self.value == other.value && self.leading_field == other.leading_field
&& self.leading_precision == other.leading_precision &&
self.last_field == other.last_field &&
self.fractional_seconds_precision ==
other.fractional_seconds_precision
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Interval {
#[inline]
fn partial_cmp(&self, other: &Interval)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Interval {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<DateTimeField>>;
let _: ::core::cmp::AssertParamIsEq<Option<u64>>;
let _: ::core::cmp::AssertParamIsEq<Option<DateTimeField>>;
let _: ::core::cmp::AssertParamIsEq<Option<u64>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Interval {
#[inline]
fn cmp(&self, other: &Interval) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.value, &other.value) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.leading_field,
&other.leading_field) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.leading_precision,
&other.leading_precision) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.last_field,
&other.last_field) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.fractional_seconds_precision,
&other.fractional_seconds_precision),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Interval {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.value, state);
::core::hash::Hash::hash(&self.leading_field, state);
::core::hash::Hash::hash(&self.leading_precision, state);
::core::hash::Hash::hash(&self.last_field, state);
::core::hash::Hash::hash(&self.fractional_seconds_precision, state)
}
}Hash)]
456#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
457#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Interval {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.value, visitor)?;
sqlparser::ast::Visit::visit(&self.leading_field, visitor)?;
sqlparser::ast::Visit::visit(&self.leading_precision,
visitor)?;
sqlparser::ast::Visit::visit(&self.last_field, visitor)?;
sqlparser::ast::Visit::visit(&self.fractional_seconds_precision,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Interval {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.leading_field,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.leading_precision,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.last_field,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.fractional_seconds_precision,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
458pub struct Interval {
459 pub value: Box<Expr>,
461 pub leading_field: Option<DateTimeField>,
463 pub leading_precision: Option<u64>,
465 pub last_field: Option<DateTimeField>,
467 pub fractional_seconds_precision: Option<u64>,
471}
472
473impl fmt::Display for Interval {
474 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
475 let value = self.value.as_ref();
476 match (
477 &self.leading_field,
478 self.leading_precision,
479 self.fractional_seconds_precision,
480 ) {
481 (
482 Some(DateTimeField::Second),
483 Some(leading_precision),
484 Some(fractional_seconds_precision),
485 ) => {
486 if !self.last_field.is_none() {
::core::panicking::panic("assertion failed: self.last_field.is_none()")
};assert!(self.last_field.is_none());
489 f.write_fmt(format_args!("INTERVAL {0} SECOND ({1}, {2})", value,
leading_precision, fractional_seconds_precision))write!(
490 f,
491 "INTERVAL {value} SECOND ({leading_precision}, {fractional_seconds_precision})"
492 )
493 }
494 _ => {
495 f.write_fmt(format_args!("INTERVAL {0}", value))write!(f, "INTERVAL {value}")?;
496 if let Some(leading_field) = &self.leading_field {
497 f.write_fmt(format_args!(" {0}", leading_field))write!(f, " {leading_field}")?;
498 }
499 if let Some(leading_precision) = self.leading_precision {
500 f.write_fmt(format_args!(" ({0})", leading_precision))write!(f, " ({leading_precision})")?;
501 }
502 if let Some(last_field) = &self.last_field {
503 f.write_fmt(format_args!(" TO {0}", last_field))write!(f, " TO {last_field}")?;
504 }
505 if let Some(fractional_seconds_precision) = self.fractional_seconds_precision {
506 f.write_fmt(format_args!(" ({0})", fractional_seconds_precision))write!(f, " ({fractional_seconds_precision})")?;
507 }
508 Ok(())
509 }
510 }
511 }
512}
513
514#[derive(#[automatically_derived]
impl ::core::fmt::Debug for StructField {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "StructField",
"field_name", &self.field_name, "field_type", &self.field_type,
"options", &&self.options)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for StructField {
#[inline]
fn clone(&self) -> StructField {
StructField {
field_name: ::core::clone::Clone::clone(&self.field_name),
field_type: ::core::clone::Clone::clone(&self.field_type),
options: ::core::clone::Clone::clone(&self.options),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for StructField {
#[inline]
fn eq(&self, other: &StructField) -> bool {
self.field_name == other.field_name &&
self.field_type == other.field_type &&
self.options == other.options
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for StructField {
#[inline]
fn partial_cmp(&self, other: &StructField)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for StructField {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<DataType>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<SqlOption>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for StructField {
#[inline]
fn cmp(&self, other: &StructField) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.field_name, &other.field_name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.field_type,
&other.field_type) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.options, &other.options),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for StructField {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.field_name, state);
::core::hash::Hash::hash(&self.field_type, state);
::core::hash::Hash::hash(&self.options, state)
}
}Hash)]
518#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
519#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for StructField {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.field_name, visitor)?;
sqlparser::ast::Visit::visit(&self.field_type, visitor)?;
sqlparser::ast::Visit::visit(&self.options, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for StructField {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.field_name,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.field_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.options,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
520pub struct StructField {
521 pub field_name: Option<Ident>,
523 pub field_type: DataType,
525 pub options: Option<Vec<SqlOption>>,
528}
529
530impl fmt::Display for StructField {
531 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
532 if let Some(name) = &self.field_name {
533 f.write_fmt(format_args!("{1} {0}", self.field_type, name))write!(f, "{name} {}", self.field_type)?;
534 } else {
535 f.write_fmt(format_args!("{0}", self.field_type))write!(f, "{}", self.field_type)?;
536 }
537 if let Some(options) = &self.options {
538 f.write_fmt(format_args!(" OPTIONS({0})", display_separated(options, ", ")))write!(f, " OPTIONS({})", display_separated(options, ", "))
539 } else {
540 Ok(())
541 }
542 }
543}
544
545#[derive(#[automatically_derived]
impl ::core::fmt::Debug for UnionField {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "UnionField",
"field_name", &self.field_name, "field_type", &&self.field_type)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for UnionField {
#[inline]
fn clone(&self) -> UnionField {
UnionField {
field_name: ::core::clone::Clone::clone(&self.field_name),
field_type: ::core::clone::Clone::clone(&self.field_type),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for UnionField {
#[inline]
fn eq(&self, other: &UnionField) -> bool {
self.field_name == other.field_name &&
self.field_type == other.field_type
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for UnionField {
#[inline]
fn partial_cmp(&self, other: &UnionField)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for UnionField {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<DataType>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for UnionField {
#[inline]
fn cmp(&self, other: &UnionField) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.field_name, &other.field_name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.field_type, &other.field_type),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for UnionField {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.field_name, state);
::core::hash::Hash::hash(&self.field_type, state)
}
}Hash)]
549#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
550#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for UnionField {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.field_name, visitor)?;
sqlparser::ast::Visit::visit(&self.field_type, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for UnionField {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.field_name,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.field_type,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
551pub struct UnionField {
552 pub field_name: Ident,
554 pub field_type: DataType,
556}
557
558impl fmt::Display for UnionField {
559 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
560 f.write_fmt(format_args!("{0} {1}", self.field_name, self.field_type))write!(f, "{} {}", self.field_name, self.field_type)
561 }
562}
563
564#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DictionaryField {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"DictionaryField", "key", &self.key, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DictionaryField {
#[inline]
fn clone(&self) -> DictionaryField {
DictionaryField {
key: ::core::clone::Clone::clone(&self.key),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DictionaryField {
#[inline]
fn eq(&self, other: &DictionaryField) -> bool {
self.key == other.key && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DictionaryField {
#[inline]
fn partial_cmp(&self, other: &DictionaryField)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DictionaryField {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DictionaryField {
#[inline]
fn cmp(&self, other: &DictionaryField) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.key, &other.key) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DictionaryField {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.key, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
568#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
569#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DictionaryField {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.key, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DictionaryField {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.key, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
570pub struct DictionaryField {
571 pub key: Ident,
573 pub value: Box<Expr>,
575}
576
577impl fmt::Display for DictionaryField {
578 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
579 f.write_fmt(format_args!("{0}: {1}", self.key, self.value))write!(f, "{}: {}", self.key, self.value)
580 }
581}
582
583#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Map {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f, "Map",
"entries", &&self.entries)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Map {
#[inline]
fn clone(&self) -> Map {
Map { entries: ::core::clone::Clone::clone(&self.entries) }
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Map {
#[inline]
fn eq(&self, other: &Map) -> bool { self.entries == other.entries }
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Map {
#[inline]
fn partial_cmp(&self, other: &Map)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Map {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<MapEntry>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Map {
#[inline]
fn cmp(&self, other: &Map) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.entries, &other.entries)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Map {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.entries, state)
}
}Hash)]
585#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
586#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Map {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.entries, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Map {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.entries,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
587pub struct Map {
588 pub entries: Vec<MapEntry>,
590}
591
592impl Display for Map {
593 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
594 f.write_fmt(format_args!("MAP {{{0}}}",
display_comma_separated(&self.entries)))write!(f, "MAP {{{}}}", display_comma_separated(&self.entries))
595 }
596}
597
598#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MapEntry {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "MapEntry",
"key", &self.key, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for MapEntry {
#[inline]
fn clone(&self) -> MapEntry {
MapEntry {
key: ::core::clone::Clone::clone(&self.key),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MapEntry {
#[inline]
fn eq(&self, other: &MapEntry) -> bool {
self.key == other.key && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MapEntry {
#[inline]
fn partial_cmp(&self, other: &MapEntry)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MapEntry {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MapEntry {
#[inline]
fn cmp(&self, other: &MapEntry) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.key, &other.key) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MapEntry {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.key, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
602#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
603#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MapEntry {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.key, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MapEntry {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.key, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
604pub struct MapEntry {
605 pub key: Box<Expr>,
607 pub value: Box<Expr>,
609}
610
611impl fmt::Display for MapEntry {
612 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
613 f.write_fmt(format_args!("{0}: {1}", self.key, self.value))write!(f, "{}: {}", self.key, self.value)
614 }
615}
616
617#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CastFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CastFormat::Value(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Value",
&__self_0),
CastFormat::ValueAtTimeZone(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"ValueAtTimeZone", __self_0, &__self_1),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CastFormat {
#[inline]
fn clone(&self) -> CastFormat {
match self {
CastFormat::Value(__self_0) =>
CastFormat::Value(::core::clone::Clone::clone(__self_0)),
CastFormat::ValueAtTimeZone(__self_0, __self_1) =>
CastFormat::ValueAtTimeZone(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CastFormat {
#[inline]
fn eq(&self, other: &CastFormat) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CastFormat::Value(__self_0), CastFormat::Value(__arg1_0)) =>
__self_0 == __arg1_0,
(CastFormat::ValueAtTimeZone(__self_0, __self_1),
CastFormat::ValueAtTimeZone(__arg1_0, __arg1_1)) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CastFormat {
#[inline]
fn partial_cmp(&self, other: &CastFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CastFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Value>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CastFormat {
#[inline]
fn cmp(&self, other: &CastFormat) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CastFormat::Value(__self_0), CastFormat::Value(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CastFormat::ValueAtTimeZone(__self_0, __self_1),
CastFormat::ValueAtTimeZone(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CastFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CastFormat::Value(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CastFormat::ValueAtTimeZone(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
}
}
}Hash)]
620#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
621#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CastFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Value(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ValueAtTimeZone(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CastFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Value(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ValueAtTimeZone(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
622pub enum CastFormat {
623 Value(Value),
625 ValueAtTimeZone(Value, Value),
627}
628
629#[derive(#[automatically_derived]
impl ::core::fmt::Debug for JsonPathElem {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
JsonPathElem::Dot { key: __self_0, quoted: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "Dot",
"key", __self_0, "quoted", &__self_1),
JsonPathElem::Bracket { key: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Bracket", "key", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for JsonPathElem {
#[inline]
fn clone(&self) -> JsonPathElem {
match self {
JsonPathElem::Dot { key: __self_0, quoted: __self_1 } =>
JsonPathElem::Dot {
key: ::core::clone::Clone::clone(__self_0),
quoted: ::core::clone::Clone::clone(__self_1),
},
JsonPathElem::Bracket { key: __self_0 } =>
JsonPathElem::Bracket {
key: ::core::clone::Clone::clone(__self_0),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for JsonPathElem {
#[inline]
fn eq(&self, other: &JsonPathElem) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(JsonPathElem::Dot { key: __self_0, quoted: __self_1 },
JsonPathElem::Dot { key: __arg1_0, quoted: __arg1_1 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
(JsonPathElem::Bracket { key: __self_0 },
JsonPathElem::Bracket { key: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for JsonPathElem {
#[inline]
fn partial_cmp(&self, other: &JsonPathElem)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for JsonPathElem {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for JsonPathElem {
#[inline]
fn cmp(&self, other: &JsonPathElem) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(JsonPathElem::Dot { key: __self_0, quoted: __self_1 },
JsonPathElem::Dot { key: __arg1_0, quoted: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(JsonPathElem::Bracket { key: __self_0 },
JsonPathElem::Bracket { key: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for JsonPathElem {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
JsonPathElem::Dot { key: __self_0, quoted: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
JsonPathElem::Bracket { key: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
631#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
632#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for JsonPathElem {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Dot { key, quoted } => {
sqlparser::ast::Visit::visit(key, visitor)?;
sqlparser::ast::Visit::visit(quoted, visitor)?;
}
Self::Bracket { key } => {
sqlparser::ast::Visit::visit(key, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for JsonPathElem {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Dot { key, quoted } => {
sqlparser::ast::VisitMut::visit(key, visitor)?;
sqlparser::ast::VisitMut::visit(quoted, visitor)?;
}
Self::Bracket { key } => {
sqlparser::ast::VisitMut::visit(key, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
633pub enum JsonPathElem {
634 Dot {
638 key: String,
640 quoted: bool,
642 },
643 Bracket {
648 key: Expr,
650 },
651}
652
653#[derive(#[automatically_derived]
impl ::core::fmt::Debug for JsonPath {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f, "JsonPath",
"path", &&self.path)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for JsonPath {
#[inline]
fn clone(&self) -> JsonPath {
JsonPath { path: ::core::clone::Clone::clone(&self.path) }
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for JsonPath {
#[inline]
fn eq(&self, other: &JsonPath) -> bool { self.path == other.path }
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for JsonPath {
#[inline]
fn partial_cmp(&self, other: &JsonPath)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for JsonPath {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<JsonPathElem>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for JsonPath {
#[inline]
fn cmp(&self, other: &JsonPath) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.path, &other.path)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for JsonPath {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.path, state)
}
}Hash)]
658#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
659#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for JsonPath {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.path, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for JsonPath {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.path, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
660pub struct JsonPath {
661 pub path: Vec<JsonPathElem>,
663}
664
665impl fmt::Display for JsonPath {
666 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
667 for (i, elem) in self.path.iter().enumerate() {
668 match elem {
669 JsonPathElem::Dot { key, quoted } => {
670 if i == 0 {
671 f.write_fmt(format_args!(":"))write!(f, ":")?;
672 } else {
673 f.write_fmt(format_args!("."))write!(f, ".")?;
674 }
675
676 if *quoted {
677 f.write_fmt(format_args!("\"{0}\"", escape_double_quote_string(key)))write!(f, "\"{}\"", escape_double_quote_string(key))?;
678 } else {
679 f.write_fmt(format_args!("{0}", key))write!(f, "{key}")?;
680 }
681 }
682 JsonPathElem::Bracket { key } => {
683 f.write_fmt(format_args!("[{0}]", key))write!(f, "[{key}]")?;
684 }
685 }
686 }
687 Ok(())
688 }
689}
690
691#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CastKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CastKind::Cast => "Cast",
CastKind::TryCast => "TryCast",
CastKind::SafeCast => "SafeCast",
CastKind::DoubleColon => "DoubleColon",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CastKind {
#[inline]
fn clone(&self) -> CastKind {
match self {
CastKind::Cast => CastKind::Cast,
CastKind::TryCast => CastKind::TryCast,
CastKind::SafeCast => CastKind::SafeCast,
CastKind::DoubleColon => CastKind::DoubleColon,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CastKind {
#[inline]
fn eq(&self, other: &CastKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CastKind {
#[inline]
fn partial_cmp(&self, other: &CastKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CastKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CastKind {
#[inline]
fn cmp(&self, other: &CastKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CastKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
693#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
694#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CastKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Cast => {}
Self::TryCast => {}
Self::SafeCast => {}
Self::DoubleColon => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CastKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Cast => {}
Self::TryCast => {}
Self::SafeCast => {}
Self::DoubleColon => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
695pub enum CastKind {
696 Cast,
698 TryCast,
703 SafeCast,
707 DoubleColon,
709}
710
711#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ConstraintReferenceMatchKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ConstraintReferenceMatchKind::Full => "Full",
ConstraintReferenceMatchKind::Partial => "Partial",
ConstraintReferenceMatchKind::Simple => "Simple",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for ConstraintReferenceMatchKind { }Copy, #[automatically_derived]
impl ::core::clone::Clone for ConstraintReferenceMatchKind {
#[inline]
fn clone(&self) -> ConstraintReferenceMatchKind { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ConstraintReferenceMatchKind {
#[inline]
fn eq(&self, other: &ConstraintReferenceMatchKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ConstraintReferenceMatchKind {
#[inline]
fn partial_cmp(&self, other: &ConstraintReferenceMatchKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ConstraintReferenceMatchKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ConstraintReferenceMatchKind {
#[inline]
fn cmp(&self, other: &ConstraintReferenceMatchKind)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ConstraintReferenceMatchKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
715#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
716#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ConstraintReferenceMatchKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Full => {}
Self::Partial => {}
Self::Simple => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ConstraintReferenceMatchKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Full => {}
Self::Partial => {}
Self::Simple => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
717pub enum ConstraintReferenceMatchKind {
718 Full,
720 Partial,
722 Simple,
724}
725
726impl fmt::Display for ConstraintReferenceMatchKind {
727 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
728 match self {
729 Self::Full => f.write_fmt(format_args!("MATCH FULL"))write!(f, "MATCH FULL"),
730 Self::Partial => f.write_fmt(format_args!("MATCH PARTIAL"))write!(f, "MATCH PARTIAL"),
731 Self::Simple => f.write_fmt(format_args!("MATCH SIMPLE"))write!(f, "MATCH SIMPLE"),
732 }
733 }
734}
735
736#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ExtractSyntax {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ExtractSyntax::From => "From",
ExtractSyntax::Comma => "Comma",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ExtractSyntax {
#[inline]
fn clone(&self) -> ExtractSyntax {
match self {
ExtractSyntax::From => ExtractSyntax::From,
ExtractSyntax::Comma => ExtractSyntax::Comma,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ExtractSyntax {
#[inline]
fn eq(&self, other: &ExtractSyntax) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ExtractSyntax {
#[inline]
fn partial_cmp(&self, other: &ExtractSyntax)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ExtractSyntax {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ExtractSyntax {
#[inline]
fn cmp(&self, other: &ExtractSyntax) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ExtractSyntax {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
743#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
744#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ExtractSyntax {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::From => {} Self::Comma => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ExtractSyntax {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::From => {} Self::Comma => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
745pub enum ExtractSyntax {
746 From,
748 Comma,
750}
751
752#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CeilFloorKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CeilFloorKind::DateTimeField(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DateTimeField", &__self_0),
CeilFloorKind::Scale(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Scale",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CeilFloorKind {
#[inline]
fn clone(&self) -> CeilFloorKind {
match self {
CeilFloorKind::DateTimeField(__self_0) =>
CeilFloorKind::DateTimeField(::core::clone::Clone::clone(__self_0)),
CeilFloorKind::Scale(__self_0) =>
CeilFloorKind::Scale(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CeilFloorKind {
#[inline]
fn eq(&self, other: &CeilFloorKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CeilFloorKind::DateTimeField(__self_0),
CeilFloorKind::DateTimeField(__arg1_0)) =>
__self_0 == __arg1_0,
(CeilFloorKind::Scale(__self_0),
CeilFloorKind::Scale(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CeilFloorKind {
#[inline]
fn partial_cmp(&self, other: &CeilFloorKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CeilFloorKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<DateTimeField>;
let _: ::core::cmp::AssertParamIsEq<Value>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CeilFloorKind {
#[inline]
fn cmp(&self, other: &CeilFloorKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CeilFloorKind::DateTimeField(__self_0),
CeilFloorKind::DateTimeField(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CeilFloorKind::Scale(__self_0),
CeilFloorKind::Scale(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CeilFloorKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CeilFloorKind::DateTimeField(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CeilFloorKind::Scale(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
761#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
762#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CeilFloorKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DateTimeField(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Scale(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CeilFloorKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DateTimeField(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Scale(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
763pub enum CeilFloorKind {
764 DateTimeField(DateTimeField),
766 Scale(Value),
768}
769
770#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CaseWhen {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "CaseWhen",
"condition", &self.condition, "result", &&self.result)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CaseWhen {
#[inline]
fn clone(&self) -> CaseWhen {
CaseWhen {
condition: ::core::clone::Clone::clone(&self.condition),
result: ::core::clone::Clone::clone(&self.result),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CaseWhen {
#[inline]
fn eq(&self, other: &CaseWhen) -> bool {
self.condition == other.condition && self.result == other.result
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CaseWhen {
#[inline]
fn partial_cmp(&self, other: &CaseWhen)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CaseWhen {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CaseWhen {
#[inline]
fn cmp(&self, other: &CaseWhen) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.condition, &other.condition) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.result, &other.result),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CaseWhen {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.condition, state);
::core::hash::Hash::hash(&self.result, state)
}
}Hash)]
773#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
774#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CaseWhen {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.condition, visitor)?;
sqlparser::ast::Visit::visit(&self.result, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CaseWhen {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.condition,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.result, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
775pub struct CaseWhen {
776 pub condition: Expr,
778 pub result: Expr,
780}
781
782impl fmt::Display for CaseWhen {
783 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
784 f.write_str("WHEN ")?;
785 self.condition.fmt(f)?;
786 f.write_str(" THEN")?;
787 SpaceOrNewline.fmt(f)?;
788 Indent(&self.result).fmt(f)?;
789 Ok(())
790 }
791}
792
793#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Expr {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Expr::Identifier(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Identifier", &__self_0),
Expr::CompoundIdentifier(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CompoundIdentifier", &__self_0),
Expr::CompoundFieldAccess { root: __self_0, access_chain: __self_1
} =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"CompoundFieldAccess", "root", __self_0, "access_chain",
&__self_1),
Expr::JsonAccess { value: __self_0, path: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"JsonAccess", "value", __self_0, "path", &__self_1),
Expr::IsFalse(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsFalse", &__self_0),
Expr::IsNotFalse(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsNotFalse", &__self_0),
Expr::IsTrue(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "IsTrue",
&__self_0),
Expr::IsNotTrue(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsNotTrue", &__self_0),
Expr::IsNull(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "IsNull",
&__self_0),
Expr::IsNotNull(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsNotNull", &__self_0),
Expr::IsUnknown(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsUnknown", &__self_0),
Expr::IsNotUnknown(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsNotUnknown", &__self_0),
Expr::IsDistinctFrom(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"IsDistinctFrom", __self_0, &__self_1),
Expr::IsNotDistinctFrom(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"IsNotDistinctFrom", __self_0, &__self_1),
Expr::IsNormalized {
expr: __self_0, form: __self_1, negated: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"IsNormalized", "expr", __self_0, "form", __self_1,
"negated", &__self_2),
Expr::InList { expr: __self_0, list: __self_1, negated: __self_2 }
=>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"InList", "expr", __self_0, "list", __self_1, "negated",
&__self_2),
Expr::InSubquery {
expr: __self_0, subquery: __self_1, negated: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"InSubquery", "expr", __self_0, "subquery", __self_1,
"negated", &__self_2),
Expr::InUnnest {
expr: __self_0, array_expr: __self_1, negated: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"InUnnest", "expr", __self_0, "array_expr", __self_1,
"negated", &__self_2),
Expr::Between {
expr: __self_0,
negated: __self_1,
low: __self_2,
high: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"Between", "expr", __self_0, "negated", __self_1, "low",
__self_2, "high", &__self_3),
Expr::BinaryOp { left: __self_0, op: __self_1, right: __self_2 }
=>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"BinaryOp", "left", __self_0, "op", __self_1, "right",
&__self_2),
Expr::Like {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f, "Like",
"negated", __self_0, "any", __self_1, "expr", __self_2,
"pattern", __self_3, "escape_char", &__self_4),
Expr::ILike {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f, "ILike",
"negated", __self_0, "any", __self_1, "expr", __self_2,
"pattern", __self_3, "escape_char", &__self_4),
Expr::SimilarTo {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
escape_char: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"SimilarTo", "negated", __self_0, "expr", __self_1,
"pattern", __self_2, "escape_char", &__self_3),
Expr::RLike {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
regexp: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f, "RLike",
"negated", __self_0, "expr", __self_1, "pattern", __self_2,
"regexp", &__self_3),
Expr::AnyOp {
left: __self_0,
compare_op: __self_1,
right: __self_2,
is_some: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f, "AnyOp",
"left", __self_0, "compare_op", __self_1, "right", __self_2,
"is_some", &__self_3),
Expr::AllOp {
left: __self_0, compare_op: __self_1, right: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f, "AllOp",
"left", __self_0, "compare_op", __self_1, "right",
&__self_2),
Expr::UnaryOp { op: __self_0, expr: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"UnaryOp", "op", __self_0, "expr", &__self_1),
Expr::Convert {
is_try: __self_0,
expr: __self_1,
data_type: __self_2,
charset: __self_3,
target_before_value: __self_4,
styles: __self_5 } => {
let names: &'static _ =
&["is_try", "expr", "data_type", "charset",
"target_before_value", "styles"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"Convert", names, values)
}
Expr::Cast {
kind: __self_0,
expr: __self_1,
data_type: __self_2,
array: __self_3,
format: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f, "Cast",
"kind", __self_0, "expr", __self_1, "data_type", __self_2,
"array", __self_3, "format", &__self_4),
Expr::AtTimeZone { timestamp: __self_0, time_zone: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AtTimeZone", "timestamp", __self_0, "time_zone",
&__self_1),
Expr::Extract { field: __self_0, syntax: __self_1, expr: __self_2
} =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"Extract", "field", __self_0, "syntax", __self_1, "expr",
&__self_2),
Expr::Ceil { expr: __self_0, field: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "Ceil",
"expr", __self_0, "field", &__self_1),
Expr::Floor { expr: __self_0, field: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "Floor",
"expr", __self_0, "field", &__self_1),
Expr::Position { expr: __self_0, r#in: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Position", "expr", __self_0, "in", &__self_1),
Expr::Substring {
expr: __self_0,
substring_from: __self_1,
substring_for: __self_2,
special: __self_3,
shorthand: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"Substring", "expr", __self_0, "substring_from", __self_1,
"substring_for", __self_2, "special", __self_3, "shorthand",
&__self_4),
Expr::Trim {
expr: __self_0,
trim_where: __self_1,
trim_what: __self_2,
trim_characters: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f, "Trim",
"expr", __self_0, "trim_where", __self_1, "trim_what",
__self_2, "trim_characters", &__self_3),
Expr::Overlay {
expr: __self_0,
overlay_what: __self_1,
overlay_from: __self_2,
overlay_for: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"Overlay", "expr", __self_0, "overlay_what", __self_1,
"overlay_from", __self_2, "overlay_for", &__self_3),
Expr::Collate { expr: __self_0, collation: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Collate", "expr", __self_0, "collation", &__self_1),
Expr::Nested(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Nested",
&__self_0),
Expr::Value(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Value",
&__self_0),
Expr::Prefixed { prefix: __self_0, value: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Prefixed", "prefix", __self_0, "value", &__self_1),
Expr::TypedString(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"TypedString", &__self_0),
Expr::Function(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Function", &__self_0),
Expr::Case {
case_token: __self_0,
end_token: __self_1,
operand: __self_2,
conditions: __self_3,
else_result: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f, "Case",
"case_token", __self_0, "end_token", __self_1, "operand",
__self_2, "conditions", __self_3, "else_result", &__self_4),
Expr::Exists { subquery: __self_0, negated: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Exists", "subquery", __self_0, "negated", &__self_1),
Expr::Subquery(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Subquery", &__self_0),
Expr::GroupingSets(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"GroupingSets", &__self_0),
Expr::Cube(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Cube",
&__self_0),
Expr::Rollup(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Rollup",
&__self_0),
Expr::Tuple(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Tuple",
&__self_0),
Expr::Struct { values: __self_0, fields: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Struct", "values", __self_0, "fields", &__self_1),
Expr::Named { expr: __self_0, name: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "Named",
"expr", __self_0, "name", &__self_1),
Expr::Dictionary(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Dictionary", &__self_0),
Expr::Map(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Map",
&__self_0),
Expr::Array(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Array",
&__self_0),
Expr::Interval(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Interval", &__self_0),
Expr::MatchAgainst {
columns: __self_0,
match_value: __self_1,
opt_search_modifier: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"MatchAgainst", "columns", __self_0, "match_value",
__self_1, "opt_search_modifier", &__self_2),
Expr::Wildcard(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Wildcard", &__self_0),
Expr::QualifiedWildcard(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"QualifiedWildcard", __self_0, &__self_1),
Expr::OuterJoin(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"OuterJoin", &__self_0),
Expr::Prior(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Prior",
&__self_0),
Expr::Lambda(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Lambda",
&__self_0),
Expr::MemberOf(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"MemberOf", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Expr {
#[inline]
fn clone(&self) -> Expr {
match self {
Expr::Identifier(__self_0) =>
Expr::Identifier(::core::clone::Clone::clone(__self_0)),
Expr::CompoundIdentifier(__self_0) =>
Expr::CompoundIdentifier(::core::clone::Clone::clone(__self_0)),
Expr::CompoundFieldAccess { root: __self_0, access_chain: __self_1
} =>
Expr::CompoundFieldAccess {
root: ::core::clone::Clone::clone(__self_0),
access_chain: ::core::clone::Clone::clone(__self_1),
},
Expr::JsonAccess { value: __self_0, path: __self_1 } =>
Expr::JsonAccess {
value: ::core::clone::Clone::clone(__self_0),
path: ::core::clone::Clone::clone(__self_1),
},
Expr::IsFalse(__self_0) =>
Expr::IsFalse(::core::clone::Clone::clone(__self_0)),
Expr::IsNotFalse(__self_0) =>
Expr::IsNotFalse(::core::clone::Clone::clone(__self_0)),
Expr::IsTrue(__self_0) =>
Expr::IsTrue(::core::clone::Clone::clone(__self_0)),
Expr::IsNotTrue(__self_0) =>
Expr::IsNotTrue(::core::clone::Clone::clone(__self_0)),
Expr::IsNull(__self_0) =>
Expr::IsNull(::core::clone::Clone::clone(__self_0)),
Expr::IsNotNull(__self_0) =>
Expr::IsNotNull(::core::clone::Clone::clone(__self_0)),
Expr::IsUnknown(__self_0) =>
Expr::IsUnknown(::core::clone::Clone::clone(__self_0)),
Expr::IsNotUnknown(__self_0) =>
Expr::IsNotUnknown(::core::clone::Clone::clone(__self_0)),
Expr::IsDistinctFrom(__self_0, __self_1) =>
Expr::IsDistinctFrom(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
Expr::IsNotDistinctFrom(__self_0, __self_1) =>
Expr::IsNotDistinctFrom(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
Expr::IsNormalized {
expr: __self_0, form: __self_1, negated: __self_2 } =>
Expr::IsNormalized {
expr: ::core::clone::Clone::clone(__self_0),
form: ::core::clone::Clone::clone(__self_1),
negated: ::core::clone::Clone::clone(__self_2),
},
Expr::InList { expr: __self_0, list: __self_1, negated: __self_2 }
=>
Expr::InList {
expr: ::core::clone::Clone::clone(__self_0),
list: ::core::clone::Clone::clone(__self_1),
negated: ::core::clone::Clone::clone(__self_2),
},
Expr::InSubquery {
expr: __self_0, subquery: __self_1, negated: __self_2 } =>
Expr::InSubquery {
expr: ::core::clone::Clone::clone(__self_0),
subquery: ::core::clone::Clone::clone(__self_1),
negated: ::core::clone::Clone::clone(__self_2),
},
Expr::InUnnest {
expr: __self_0, array_expr: __self_1, negated: __self_2 } =>
Expr::InUnnest {
expr: ::core::clone::Clone::clone(__self_0),
array_expr: ::core::clone::Clone::clone(__self_1),
negated: ::core::clone::Clone::clone(__self_2),
},
Expr::Between {
expr: __self_0,
negated: __self_1,
low: __self_2,
high: __self_3 } =>
Expr::Between {
expr: ::core::clone::Clone::clone(__self_0),
negated: ::core::clone::Clone::clone(__self_1),
low: ::core::clone::Clone::clone(__self_2),
high: ::core::clone::Clone::clone(__self_3),
},
Expr::BinaryOp { left: __self_0, op: __self_1, right: __self_2 }
=>
Expr::BinaryOp {
left: ::core::clone::Clone::clone(__self_0),
op: ::core::clone::Clone::clone(__self_1),
right: ::core::clone::Clone::clone(__self_2),
},
Expr::Like {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 } =>
Expr::Like {
negated: ::core::clone::Clone::clone(__self_0),
any: ::core::clone::Clone::clone(__self_1),
expr: ::core::clone::Clone::clone(__self_2),
pattern: ::core::clone::Clone::clone(__self_3),
escape_char: ::core::clone::Clone::clone(__self_4),
},
Expr::ILike {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 } =>
Expr::ILike {
negated: ::core::clone::Clone::clone(__self_0),
any: ::core::clone::Clone::clone(__self_1),
expr: ::core::clone::Clone::clone(__self_2),
pattern: ::core::clone::Clone::clone(__self_3),
escape_char: ::core::clone::Clone::clone(__self_4),
},
Expr::SimilarTo {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
escape_char: __self_3 } =>
Expr::SimilarTo {
negated: ::core::clone::Clone::clone(__self_0),
expr: ::core::clone::Clone::clone(__self_1),
pattern: ::core::clone::Clone::clone(__self_2),
escape_char: ::core::clone::Clone::clone(__self_3),
},
Expr::RLike {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
regexp: __self_3 } =>
Expr::RLike {
negated: ::core::clone::Clone::clone(__self_0),
expr: ::core::clone::Clone::clone(__self_1),
pattern: ::core::clone::Clone::clone(__self_2),
regexp: ::core::clone::Clone::clone(__self_3),
},
Expr::AnyOp {
left: __self_0,
compare_op: __self_1,
right: __self_2,
is_some: __self_3 } =>
Expr::AnyOp {
left: ::core::clone::Clone::clone(__self_0),
compare_op: ::core::clone::Clone::clone(__self_1),
right: ::core::clone::Clone::clone(__self_2),
is_some: ::core::clone::Clone::clone(__self_3),
},
Expr::AllOp {
left: __self_0, compare_op: __self_1, right: __self_2 } =>
Expr::AllOp {
left: ::core::clone::Clone::clone(__self_0),
compare_op: ::core::clone::Clone::clone(__self_1),
right: ::core::clone::Clone::clone(__self_2),
},
Expr::UnaryOp { op: __self_0, expr: __self_1 } =>
Expr::UnaryOp {
op: ::core::clone::Clone::clone(__self_0),
expr: ::core::clone::Clone::clone(__self_1),
},
Expr::Convert {
is_try: __self_0,
expr: __self_1,
data_type: __self_2,
charset: __self_3,
target_before_value: __self_4,
styles: __self_5 } =>
Expr::Convert {
is_try: ::core::clone::Clone::clone(__self_0),
expr: ::core::clone::Clone::clone(__self_1),
data_type: ::core::clone::Clone::clone(__self_2),
charset: ::core::clone::Clone::clone(__self_3),
target_before_value: ::core::clone::Clone::clone(__self_4),
styles: ::core::clone::Clone::clone(__self_5),
},
Expr::Cast {
kind: __self_0,
expr: __self_1,
data_type: __self_2,
array: __self_3,
format: __self_4 } =>
Expr::Cast {
kind: ::core::clone::Clone::clone(__self_0),
expr: ::core::clone::Clone::clone(__self_1),
data_type: ::core::clone::Clone::clone(__self_2),
array: ::core::clone::Clone::clone(__self_3),
format: ::core::clone::Clone::clone(__self_4),
},
Expr::AtTimeZone { timestamp: __self_0, time_zone: __self_1 } =>
Expr::AtTimeZone {
timestamp: ::core::clone::Clone::clone(__self_0),
time_zone: ::core::clone::Clone::clone(__self_1),
},
Expr::Extract { field: __self_0, syntax: __self_1, expr: __self_2
} =>
Expr::Extract {
field: ::core::clone::Clone::clone(__self_0),
syntax: ::core::clone::Clone::clone(__self_1),
expr: ::core::clone::Clone::clone(__self_2),
},
Expr::Ceil { expr: __self_0, field: __self_1 } =>
Expr::Ceil {
expr: ::core::clone::Clone::clone(__self_0),
field: ::core::clone::Clone::clone(__self_1),
},
Expr::Floor { expr: __self_0, field: __self_1 } =>
Expr::Floor {
expr: ::core::clone::Clone::clone(__self_0),
field: ::core::clone::Clone::clone(__self_1),
},
Expr::Position { expr: __self_0, r#in: __self_1 } =>
Expr::Position {
expr: ::core::clone::Clone::clone(__self_0),
r#in: ::core::clone::Clone::clone(__self_1),
},
Expr::Substring {
expr: __self_0,
substring_from: __self_1,
substring_for: __self_2,
special: __self_3,
shorthand: __self_4 } =>
Expr::Substring {
expr: ::core::clone::Clone::clone(__self_0),
substring_from: ::core::clone::Clone::clone(__self_1),
substring_for: ::core::clone::Clone::clone(__self_2),
special: ::core::clone::Clone::clone(__self_3),
shorthand: ::core::clone::Clone::clone(__self_4),
},
Expr::Trim {
expr: __self_0,
trim_where: __self_1,
trim_what: __self_2,
trim_characters: __self_3 } =>
Expr::Trim {
expr: ::core::clone::Clone::clone(__self_0),
trim_where: ::core::clone::Clone::clone(__self_1),
trim_what: ::core::clone::Clone::clone(__self_2),
trim_characters: ::core::clone::Clone::clone(__self_3),
},
Expr::Overlay {
expr: __self_0,
overlay_what: __self_1,
overlay_from: __self_2,
overlay_for: __self_3 } =>
Expr::Overlay {
expr: ::core::clone::Clone::clone(__self_0),
overlay_what: ::core::clone::Clone::clone(__self_1),
overlay_from: ::core::clone::Clone::clone(__self_2),
overlay_for: ::core::clone::Clone::clone(__self_3),
},
Expr::Collate { expr: __self_0, collation: __self_1 } =>
Expr::Collate {
expr: ::core::clone::Clone::clone(__self_0),
collation: ::core::clone::Clone::clone(__self_1),
},
Expr::Nested(__self_0) =>
Expr::Nested(::core::clone::Clone::clone(__self_0)),
Expr::Value(__self_0) =>
Expr::Value(::core::clone::Clone::clone(__self_0)),
Expr::Prefixed { prefix: __self_0, value: __self_1 } =>
Expr::Prefixed {
prefix: ::core::clone::Clone::clone(__self_0),
value: ::core::clone::Clone::clone(__self_1),
},
Expr::TypedString(__self_0) =>
Expr::TypedString(::core::clone::Clone::clone(__self_0)),
Expr::Function(__self_0) =>
Expr::Function(::core::clone::Clone::clone(__self_0)),
Expr::Case {
case_token: __self_0,
end_token: __self_1,
operand: __self_2,
conditions: __self_3,
else_result: __self_4 } =>
Expr::Case {
case_token: ::core::clone::Clone::clone(__self_0),
end_token: ::core::clone::Clone::clone(__self_1),
operand: ::core::clone::Clone::clone(__self_2),
conditions: ::core::clone::Clone::clone(__self_3),
else_result: ::core::clone::Clone::clone(__self_4),
},
Expr::Exists { subquery: __self_0, negated: __self_1 } =>
Expr::Exists {
subquery: ::core::clone::Clone::clone(__self_0),
negated: ::core::clone::Clone::clone(__self_1),
},
Expr::Subquery(__self_0) =>
Expr::Subquery(::core::clone::Clone::clone(__self_0)),
Expr::GroupingSets(__self_0) =>
Expr::GroupingSets(::core::clone::Clone::clone(__self_0)),
Expr::Cube(__self_0) =>
Expr::Cube(::core::clone::Clone::clone(__self_0)),
Expr::Rollup(__self_0) =>
Expr::Rollup(::core::clone::Clone::clone(__self_0)),
Expr::Tuple(__self_0) =>
Expr::Tuple(::core::clone::Clone::clone(__self_0)),
Expr::Struct { values: __self_0, fields: __self_1 } =>
Expr::Struct {
values: ::core::clone::Clone::clone(__self_0),
fields: ::core::clone::Clone::clone(__self_1),
},
Expr::Named { expr: __self_0, name: __self_1 } =>
Expr::Named {
expr: ::core::clone::Clone::clone(__self_0),
name: ::core::clone::Clone::clone(__self_1),
},
Expr::Dictionary(__self_0) =>
Expr::Dictionary(::core::clone::Clone::clone(__self_0)),
Expr::Map(__self_0) =>
Expr::Map(::core::clone::Clone::clone(__self_0)),
Expr::Array(__self_0) =>
Expr::Array(::core::clone::Clone::clone(__self_0)),
Expr::Interval(__self_0) =>
Expr::Interval(::core::clone::Clone::clone(__self_0)),
Expr::MatchAgainst {
columns: __self_0,
match_value: __self_1,
opt_search_modifier: __self_2 } =>
Expr::MatchAgainst {
columns: ::core::clone::Clone::clone(__self_0),
match_value: ::core::clone::Clone::clone(__self_1),
opt_search_modifier: ::core::clone::Clone::clone(__self_2),
},
Expr::Wildcard(__self_0) =>
Expr::Wildcard(::core::clone::Clone::clone(__self_0)),
Expr::QualifiedWildcard(__self_0, __self_1) =>
Expr::QualifiedWildcard(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
Expr::OuterJoin(__self_0) =>
Expr::OuterJoin(::core::clone::Clone::clone(__self_0)),
Expr::Prior(__self_0) =>
Expr::Prior(::core::clone::Clone::clone(__self_0)),
Expr::Lambda(__self_0) =>
Expr::Lambda(::core::clone::Clone::clone(__self_0)),
Expr::MemberOf(__self_0) =>
Expr::MemberOf(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Expr {
#[inline]
fn eq(&self, other: &Expr) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Expr::Identifier(__self_0), Expr::Identifier(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::CompoundIdentifier(__self_0),
Expr::CompoundIdentifier(__arg1_0)) => __self_0 == __arg1_0,
(Expr::CompoundFieldAccess {
root: __self_0, access_chain: __self_1 },
Expr::CompoundFieldAccess {
root: __arg1_0, access_chain: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::JsonAccess { value: __self_0, path: __self_1 },
Expr::JsonAccess { value: __arg1_0, path: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::IsFalse(__self_0), Expr::IsFalse(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsNotFalse(__self_0), Expr::IsNotFalse(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsTrue(__self_0), Expr::IsTrue(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsNotTrue(__self_0), Expr::IsNotTrue(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsNull(__self_0), Expr::IsNull(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsNotNull(__self_0), Expr::IsNotNull(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsUnknown(__self_0), Expr::IsUnknown(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::IsNotUnknown(__self_0), Expr::IsNotUnknown(__arg1_0))
=> __self_0 == __arg1_0,
(Expr::IsDistinctFrom(__self_0, __self_1),
Expr::IsDistinctFrom(__arg1_0, __arg1_1)) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::IsNotDistinctFrom(__self_0, __self_1),
Expr::IsNotDistinctFrom(__arg1_0, __arg1_1)) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::IsNormalized {
expr: __self_0, form: __self_1, negated: __self_2 },
Expr::IsNormalized {
expr: __arg1_0, form: __arg1_1, negated: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
(Expr::InList {
expr: __self_0, list: __self_1, negated: __self_2 },
Expr::InList {
expr: __arg1_0, list: __arg1_1, negated: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
(Expr::InSubquery {
expr: __self_0, subquery: __self_1, negated: __self_2 },
Expr::InSubquery {
expr: __arg1_0, subquery: __arg1_1, negated: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
(Expr::InUnnest {
expr: __self_0, array_expr: __self_1, negated: __self_2 },
Expr::InUnnest {
expr: __arg1_0, array_expr: __arg1_1, negated: __arg1_2 })
=>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
(Expr::Between {
expr: __self_0,
negated: __self_1,
low: __self_2,
high: __self_3 }, Expr::Between {
expr: __arg1_0,
negated: __arg1_1,
low: __arg1_2,
high: __arg1_3 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Expr::BinaryOp {
left: __self_0, op: __self_1, right: __self_2 },
Expr::BinaryOp {
left: __arg1_0, op: __arg1_1, right: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Expr::Like {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 }, Expr::Like {
negated: __arg1_0,
any: __arg1_1,
expr: __arg1_2,
pattern: __arg1_3,
escape_char: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Expr::ILike {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 }, Expr::ILike {
negated: __arg1_0,
any: __arg1_1,
expr: __arg1_2,
pattern: __arg1_3,
escape_char: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Expr::SimilarTo {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
escape_char: __self_3 }, Expr::SimilarTo {
negated: __arg1_0,
expr: __arg1_1,
pattern: __arg1_2,
escape_char: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Expr::RLike {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
regexp: __self_3 }, Expr::RLike {
negated: __arg1_0,
expr: __arg1_1,
pattern: __arg1_2,
regexp: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_3 == __arg1_3 &&
__self_1 == __arg1_1 && __self_2 == __arg1_2,
(Expr::AnyOp {
left: __self_0,
compare_op: __self_1,
right: __self_2,
is_some: __self_3 }, Expr::AnyOp {
left: __arg1_0,
compare_op: __arg1_1,
right: __arg1_2,
is_some: __arg1_3 }) =>
__self_3 == __arg1_3 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1 && __self_2 == __arg1_2,
(Expr::AllOp {
left: __self_0, compare_op: __self_1, right: __self_2 },
Expr::AllOp {
left: __arg1_0, compare_op: __arg1_1, right: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Expr::UnaryOp { op: __self_0, expr: __self_1 },
Expr::UnaryOp { op: __arg1_0, expr: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Convert {
is_try: __self_0,
expr: __self_1,
data_type: __self_2,
charset: __self_3,
target_before_value: __self_4,
styles: __self_5 }, Expr::Convert {
is_try: __arg1_0,
expr: __arg1_1,
data_type: __arg1_2,
charset: __arg1_3,
target_before_value: __arg1_4,
styles: __arg1_5 }) =>
__self_0 == __arg1_0 && __self_4 == __arg1_4 &&
__self_1 == __arg1_1 && __self_2 == __arg1_2 &&
__self_3 == __arg1_3 && __self_5 == __arg1_5,
(Expr::Cast {
kind: __self_0,
expr: __self_1,
data_type: __self_2,
array: __self_3,
format: __self_4 }, Expr::Cast {
kind: __arg1_0,
expr: __arg1_1,
data_type: __arg1_2,
array: __arg1_3,
format: __arg1_4 }) =>
__self_3 == __arg1_3 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1 && __self_2 == __arg1_2 &&
__self_4 == __arg1_4,
(Expr::AtTimeZone { timestamp: __self_0, time_zone: __self_1
}, Expr::AtTimeZone {
timestamp: __arg1_0, time_zone: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Extract {
field: __self_0, syntax: __self_1, expr: __self_2 },
Expr::Extract {
field: __arg1_0, syntax: __arg1_1, expr: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Expr::Ceil { expr: __self_0, field: __self_1 }, Expr::Ceil {
expr: __arg1_0, field: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Floor { expr: __self_0, field: __self_1 },
Expr::Floor { expr: __arg1_0, field: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Position { expr: __self_0, r#in: __self_1 },
Expr::Position { expr: __arg1_0, r#in: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Substring {
expr: __self_0,
substring_from: __self_1,
substring_for: __self_2,
special: __self_3,
shorthand: __self_4 }, Expr::Substring {
expr: __arg1_0,
substring_from: __arg1_1,
substring_for: __arg1_2,
special: __arg1_3,
shorthand: __arg1_4 }) =>
__self_3 == __arg1_3 && __self_4 == __arg1_4 &&
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Expr::Trim {
expr: __self_0,
trim_where: __self_1,
trim_what: __self_2,
trim_characters: __self_3 }, Expr::Trim {
expr: __arg1_0,
trim_where: __arg1_1,
trim_what: __arg1_2,
trim_characters: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Expr::Overlay {
expr: __self_0,
overlay_what: __self_1,
overlay_from: __self_2,
overlay_for: __self_3 }, Expr::Overlay {
expr: __arg1_0,
overlay_what: __arg1_1,
overlay_from: __arg1_2,
overlay_for: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Expr::Collate { expr: __self_0, collation: __self_1 },
Expr::Collate { expr: __arg1_0, collation: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Nested(__self_0), Expr::Nested(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Value(__self_0), Expr::Value(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Prefixed { prefix: __self_0, value: __self_1 },
Expr::Prefixed { prefix: __arg1_0, value: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::TypedString(__self_0), Expr::TypedString(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Function(__self_0), Expr::Function(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Case {
case_token: __self_0,
end_token: __self_1,
operand: __self_2,
conditions: __self_3,
else_result: __self_4 }, Expr::Case {
case_token: __arg1_0,
end_token: __arg1_1,
operand: __arg1_2,
conditions: __arg1_3,
else_result: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Expr::Exists { subquery: __self_0, negated: __self_1 },
Expr::Exists { subquery: __arg1_0, negated: __arg1_1 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
(Expr::Subquery(__self_0), Expr::Subquery(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::GroupingSets(__self_0), Expr::GroupingSets(__arg1_0))
=> __self_0 == __arg1_0,
(Expr::Cube(__self_0), Expr::Cube(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Rollup(__self_0), Expr::Rollup(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Tuple(__self_0), Expr::Tuple(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Struct { values: __self_0, fields: __self_1 },
Expr::Struct { values: __arg1_0, fields: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Named { expr: __self_0, name: __self_1 }, Expr::Named {
expr: __arg1_0, name: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::Dictionary(__self_0), Expr::Dictionary(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Map(__self_0), Expr::Map(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Array(__self_0), Expr::Array(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Interval(__self_0), Expr::Interval(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::MatchAgainst {
columns: __self_0,
match_value: __self_1,
opt_search_modifier: __self_2 }, Expr::MatchAgainst {
columns: __arg1_0,
match_value: __arg1_1,
opt_search_modifier: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Expr::Wildcard(__self_0), Expr::Wildcard(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::QualifiedWildcard(__self_0, __self_1),
Expr::QualifiedWildcard(__arg1_0, __arg1_1)) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Expr::OuterJoin(__self_0), Expr::OuterJoin(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Prior(__self_0), Expr::Prior(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::Lambda(__self_0), Expr::Lambda(__arg1_0)) =>
__self_0 == __arg1_0,
(Expr::MemberOf(__self_0), Expr::MemberOf(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Expr {
#[inline]
fn partial_cmp(&self, other: &Expr)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Expr {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<AccessExpr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<JsonPath>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<NormalizationForm>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<BinaryOperator>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<UnaryOperator>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<DataType>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<CastKind>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<DataType>;
let _: ::core::cmp::AssertParamIsEq<Option<CastFormat>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<DateTimeField>;
let _: ::core::cmp::AssertParamIsEq<ExtractSyntax>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<CeilFloorKind>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<TrimWhereField>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<ValueWithSpan>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<TypedString>;
let _: ::core::cmp::AssertParamIsEq<Function>;
let _: ::core::cmp::AssertParamIsEq<AttachedToken>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Vec<CaseWhen>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Vec<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Vec<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Vec<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<StructField>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<DictionaryField>>;
let _: ::core::cmp::AssertParamIsEq<Map>;
let _: ::core::cmp::AssertParamIsEq<Array>;
let _: ::core::cmp::AssertParamIsEq<Interval>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Value>;
let _: ::core::cmp::AssertParamIsEq<Option<SearchModifier>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<LambdaFunction>;
let _: ::core::cmp::AssertParamIsEq<MemberOf>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Expr {
#[inline]
fn cmp(&self, other: &Expr) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Expr::Identifier(__self_0), Expr::Identifier(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::CompoundIdentifier(__self_0),
Expr::CompoundIdentifier(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::CompoundFieldAccess {
root: __self_0, access_chain: __self_1 },
Expr::CompoundFieldAccess {
root: __arg1_0, access_chain: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::JsonAccess { value: __self_0, path: __self_1 },
Expr::JsonAccess { value: __arg1_0, path: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::IsFalse(__self_0), Expr::IsFalse(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsNotFalse(__self_0), Expr::IsNotFalse(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsTrue(__self_0), Expr::IsTrue(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsNotTrue(__self_0), Expr::IsNotTrue(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsNull(__self_0), Expr::IsNull(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsNotNull(__self_0), Expr::IsNotNull(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsUnknown(__self_0), Expr::IsUnknown(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsNotUnknown(__self_0), Expr::IsNotUnknown(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::IsDistinctFrom(__self_0, __self_1),
Expr::IsDistinctFrom(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::IsNotDistinctFrom(__self_0, __self_1),
Expr::IsNotDistinctFrom(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::IsNormalized {
expr: __self_0, form: __self_1, negated: __self_2 },
Expr::IsNormalized {
expr: __arg1_0, form: __arg1_1, negated: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::InList {
expr: __self_0, list: __self_1, negated: __self_2 },
Expr::InList {
expr: __arg1_0, list: __arg1_1, negated: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::InSubquery {
expr: __self_0, subquery: __self_1, negated: __self_2 },
Expr::InSubquery {
expr: __arg1_0, subquery: __arg1_1, negated: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::InUnnest {
expr: __self_0, array_expr: __self_1, negated: __self_2 },
Expr::InUnnest {
expr: __arg1_0, array_expr: __arg1_1, negated: __arg1_2 })
=>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::Between {
expr: __self_0,
negated: __self_1,
low: __self_2,
high: __self_3 }, Expr::Between {
expr: __arg1_0,
negated: __arg1_1,
low: __arg1_2,
high: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::BinaryOp {
left: __self_0, op: __self_1, right: __self_2 },
Expr::BinaryOp {
left: __arg1_0, op: __arg1_1, right: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::Like {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 }, Expr::Like {
negated: __arg1_0,
any: __arg1_1,
expr: __arg1_2,
pattern: __arg1_3,
escape_char: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::ILike {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 }, Expr::ILike {
negated: __arg1_0,
any: __arg1_1,
expr: __arg1_2,
pattern: __arg1_3,
escape_char: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::SimilarTo {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
escape_char: __self_3 }, Expr::SimilarTo {
negated: __arg1_0,
expr: __arg1_1,
pattern: __arg1_2,
escape_char: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::RLike {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
regexp: __self_3 }, Expr::RLike {
negated: __arg1_0,
expr: __arg1_1,
pattern: __arg1_2,
regexp: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::AnyOp {
left: __self_0,
compare_op: __self_1,
right: __self_2,
is_some: __self_3 }, Expr::AnyOp {
left: __arg1_0,
compare_op: __arg1_1,
right: __arg1_2,
is_some: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::AllOp {
left: __self_0, compare_op: __self_1, right: __self_2 },
Expr::AllOp {
left: __arg1_0, compare_op: __arg1_1, right: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::UnaryOp { op: __self_0, expr: __self_1 },
Expr::UnaryOp { op: __arg1_0, expr: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Convert {
is_try: __self_0,
expr: __self_1,
data_type: __self_2,
charset: __self_3,
target_before_value: __self_4,
styles: __self_5 }, Expr::Convert {
is_try: __arg1_0,
expr: __arg1_1,
data_type: __arg1_2,
charset: __arg1_3,
target_before_value: __arg1_4,
styles: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::Cast {
kind: __self_0,
expr: __self_1,
data_type: __self_2,
array: __self_3,
format: __self_4 }, Expr::Cast {
kind: __arg1_0,
expr: __arg1_1,
data_type: __arg1_2,
array: __arg1_3,
format: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::AtTimeZone { timestamp: __self_0, time_zone: __self_1
}, Expr::AtTimeZone {
timestamp: __arg1_0, time_zone: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Extract {
field: __self_0, syntax: __self_1, expr: __self_2 },
Expr::Extract {
field: __arg1_0, syntax: __arg1_1, expr: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::Ceil { expr: __self_0, field: __self_1 },
Expr::Ceil { expr: __arg1_0, field: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Floor { expr: __self_0, field: __self_1 },
Expr::Floor { expr: __arg1_0, field: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Position { expr: __self_0, r#in: __self_1 },
Expr::Position { expr: __arg1_0, r#in: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Substring {
expr: __self_0,
substring_from: __self_1,
substring_for: __self_2,
special: __self_3,
shorthand: __self_4 }, Expr::Substring {
expr: __arg1_0,
substring_from: __arg1_1,
substring_for: __arg1_2,
special: __arg1_3,
shorthand: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::Trim {
expr: __self_0,
trim_where: __self_1,
trim_what: __self_2,
trim_characters: __self_3 }, Expr::Trim {
expr: __arg1_0,
trim_where: __arg1_1,
trim_what: __arg1_2,
trim_characters: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::Overlay {
expr: __self_0,
overlay_what: __self_1,
overlay_from: __self_2,
overlay_for: __self_3 }, Expr::Overlay {
expr: __arg1_0,
overlay_what: __arg1_1,
overlay_from: __arg1_2,
overlay_for: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::Collate { expr: __self_0, collation: __self_1 },
Expr::Collate { expr: __arg1_0, collation: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Nested(__self_0), Expr::Nested(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Value(__self_0), Expr::Value(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Prefixed { prefix: __self_0, value: __self_1 },
Expr::Prefixed { prefix: __arg1_0, value: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::TypedString(__self_0), Expr::TypedString(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Function(__self_0), Expr::Function(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Case {
case_token: __self_0,
end_token: __self_1,
operand: __self_2,
conditions: __self_3,
else_result: __self_4 }, Expr::Case {
case_token: __arg1_0,
end_token: __arg1_1,
operand: __arg1_2,
conditions: __arg1_3,
else_result: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Expr::Exists { subquery: __self_0, negated: __self_1 },
Expr::Exists { subquery: __arg1_0, negated: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Subquery(__self_0), Expr::Subquery(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::GroupingSets(__self_0), Expr::GroupingSets(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Cube(__self_0), Expr::Cube(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Rollup(__self_0), Expr::Rollup(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Tuple(__self_0), Expr::Tuple(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Struct { values: __self_0, fields: __self_1 },
Expr::Struct { values: __arg1_0, fields: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Named { expr: __self_0, name: __self_1 },
Expr::Named { expr: __arg1_0, name: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::Dictionary(__self_0), Expr::Dictionary(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Map(__self_0), Expr::Map(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Array(__self_0), Expr::Array(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Interval(__self_0), Expr::Interval(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::MatchAgainst {
columns: __self_0,
match_value: __self_1,
opt_search_modifier: __self_2 }, Expr::MatchAgainst {
columns: __arg1_0,
match_value: __arg1_1,
opt_search_modifier: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Expr::Wildcard(__self_0), Expr::Wildcard(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::QualifiedWildcard(__self_0, __self_1),
Expr::QualifiedWildcard(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Expr::OuterJoin(__self_0), Expr::OuterJoin(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Prior(__self_0), Expr::Prior(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::Lambda(__self_0), Expr::Lambda(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Expr::MemberOf(__self_0), Expr::MemberOf(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Expr {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Expr::Identifier(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::CompoundIdentifier(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::CompoundFieldAccess { root: __self_0, access_chain: __self_1
} => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::JsonAccess { value: __self_0, path: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::IsFalse(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsNotFalse(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsTrue(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsNotTrue(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsNull(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsNotNull(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsUnknown(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsNotUnknown(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::IsDistinctFrom(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::IsNotDistinctFrom(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::IsNormalized {
expr: __self_0, form: __self_1, negated: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::InList { expr: __self_0, list: __self_1, negated: __self_2 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::InSubquery {
expr: __self_0, subquery: __self_1, negated: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::InUnnest {
expr: __self_0, array_expr: __self_1, negated: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::Between {
expr: __self_0,
negated: __self_1,
low: __self_2,
high: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Expr::BinaryOp { left: __self_0, op: __self_1, right: __self_2 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::Like {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Expr::ILike {
negated: __self_0,
any: __self_1,
expr: __self_2,
pattern: __self_3,
escape_char: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Expr::SimilarTo {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
escape_char: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Expr::RLike {
negated: __self_0,
expr: __self_1,
pattern: __self_2,
regexp: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Expr::AnyOp {
left: __self_0,
compare_op: __self_1,
right: __self_2,
is_some: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Expr::AllOp {
left: __self_0, compare_op: __self_1, right: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::UnaryOp { op: __self_0, expr: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Convert {
is_try: __self_0,
expr: __self_1,
data_type: __self_2,
charset: __self_3,
target_before_value: __self_4,
styles: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Expr::Cast {
kind: __self_0,
expr: __self_1,
data_type: __self_2,
array: __self_3,
format: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Expr::AtTimeZone { timestamp: __self_0, time_zone: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Extract { field: __self_0, syntax: __self_1, expr: __self_2
} => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::Ceil { expr: __self_0, field: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Floor { expr: __self_0, field: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Position { expr: __self_0, r#in: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Substring {
expr: __self_0,
substring_from: __self_1,
substring_for: __self_2,
special: __self_3,
shorthand: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Expr::Trim {
expr: __self_0,
trim_where: __self_1,
trim_what: __self_2,
trim_characters: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Expr::Overlay {
expr: __self_0,
overlay_what: __self_1,
overlay_from: __self_2,
overlay_for: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Expr::Collate { expr: __self_0, collation: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Nested(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Value(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Prefixed { prefix: __self_0, value: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::TypedString(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Function(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Case {
case_token: __self_0,
end_token: __self_1,
operand: __self_2,
conditions: __self_3,
else_result: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Expr::Exists { subquery: __self_0, negated: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Subquery(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::GroupingSets(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Cube(__self_0) => ::core::hash::Hash::hash(__self_0, state),
Expr::Rollup(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Tuple(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Struct { values: __self_0, fields: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Named { expr: __self_0, name: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::Dictionary(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Map(__self_0) => ::core::hash::Hash::hash(__self_0, state),
Expr::Array(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Interval(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::MatchAgainst {
columns: __self_0,
match_value: __self_1,
opt_search_modifier: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Expr::Wildcard(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::QualifiedWildcard(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Expr::OuterJoin(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Prior(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::Lambda(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Expr::MemberOf(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
811#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
812#[cfg_attr(
813 feature = "visitor",
814 derive(impl sqlparser::ast::Visit for Expr {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
visitor.pre_visit_expr(self)?;
match self {
Self::Identifier(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CompoundIdentifier(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CompoundFieldAccess { root, access_chain } => {
sqlparser::ast::Visit::visit(root, visitor)?;
sqlparser::ast::Visit::visit(access_chain, visitor)?;
}
Self::JsonAccess { value, path } => {
sqlparser::ast::Visit::visit(value, visitor)?;
sqlparser::ast::Visit::visit(path, visitor)?;
}
Self::IsFalse(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsNotFalse(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsTrue(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsNotTrue(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsNull(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsNotNull(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsUnknown(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsNotUnknown(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsDistinctFrom(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
Self::IsNotDistinctFrom(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
Self::IsNormalized { expr, form, negated } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(form, visitor)?;
sqlparser::ast::Visit::visit(negated, visitor)?;
}
Self::InList { expr, list, negated } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(list, visitor)?;
sqlparser::ast::Visit::visit(negated, visitor)?;
}
Self::InSubquery { expr, subquery, negated } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(subquery, visitor)?;
sqlparser::ast::Visit::visit(negated, visitor)?;
}
Self::InUnnest { expr, array_expr, negated } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(array_expr, visitor)?;
sqlparser::ast::Visit::visit(negated, visitor)?;
}
Self::Between { expr, negated, low, high } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(negated, visitor)?;
sqlparser::ast::Visit::visit(low, visitor)?;
sqlparser::ast::Visit::visit(high, visitor)?;
}
Self::BinaryOp { left, op, right } => {
sqlparser::ast::Visit::visit(left, visitor)?;
sqlparser::ast::Visit::visit(op, visitor)?;
sqlparser::ast::Visit::visit(right, visitor)?;
}
Self::Like { negated, any, expr, pattern, escape_char } => {
sqlparser::ast::Visit::visit(negated, visitor)?;
sqlparser::ast::Visit::visit(any, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(pattern, visitor)?;
sqlparser::ast::Visit::visit(escape_char, visitor)?;
}
Self::ILike { negated, any, expr, pattern, escape_char } =>
{
sqlparser::ast::Visit::visit(negated, visitor)?;
sqlparser::ast::Visit::visit(any, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(pattern, visitor)?;
sqlparser::ast::Visit::visit(escape_char, visitor)?;
}
Self::SimilarTo { negated, expr, pattern, escape_char } => {
sqlparser::ast::Visit::visit(negated, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(pattern, visitor)?;
sqlparser::ast::Visit::visit(escape_char, visitor)?;
}
Self::RLike { negated, expr, pattern, regexp } => {
sqlparser::ast::Visit::visit(negated, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(pattern, visitor)?;
sqlparser::ast::Visit::visit(regexp, visitor)?;
}
Self::AnyOp { left, compare_op, right, is_some } => {
sqlparser::ast::Visit::visit(left, visitor)?;
sqlparser::ast::Visit::visit(compare_op, visitor)?;
sqlparser::ast::Visit::visit(right, visitor)?;
sqlparser::ast::Visit::visit(is_some, visitor)?;
}
Self::AllOp { left, compare_op, right } => {
sqlparser::ast::Visit::visit(left, visitor)?;
sqlparser::ast::Visit::visit(compare_op, visitor)?;
sqlparser::ast::Visit::visit(right, visitor)?;
}
Self::UnaryOp { op, expr } => {
sqlparser::ast::Visit::visit(op, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
}
Self::Convert {
is_try,
expr,
data_type,
charset,
target_before_value,
styles } => {
sqlparser::ast::Visit::visit(is_try, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(data_type, visitor)?;
sqlparser::ast::Visit::visit(charset, visitor)?;
sqlparser::ast::Visit::visit(target_before_value, visitor)?;
sqlparser::ast::Visit::visit(styles, visitor)?;
}
Self::Cast { kind, expr, data_type, array, format } => {
sqlparser::ast::Visit::visit(kind, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(data_type, visitor)?;
sqlparser::ast::Visit::visit(array, visitor)?;
sqlparser::ast::Visit::visit(format, visitor)?;
}
Self::AtTimeZone { timestamp, time_zone } => {
sqlparser::ast::Visit::visit(timestamp, visitor)?;
sqlparser::ast::Visit::visit(time_zone, visitor)?;
}
Self::Extract { field, syntax, expr } => {
sqlparser::ast::Visit::visit(field, visitor)?;
sqlparser::ast::Visit::visit(syntax, visitor)?;
sqlparser::ast::Visit::visit(expr, visitor)?;
}
Self::Ceil { expr, field } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(field, visitor)?;
}
Self::Floor { expr, field } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(field, visitor)?;
}
Self::Position { expr, r#in } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(r#in, visitor)?;
}
Self::Substring {
expr, substring_from, substring_for, special, shorthand } =>
{
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(substring_from, visitor)?;
sqlparser::ast::Visit::visit(substring_for, visitor)?;
sqlparser::ast::Visit::visit(special, visitor)?;
sqlparser::ast::Visit::visit(shorthand, visitor)?;
}
Self::Trim { expr, trim_where, trim_what, trim_characters }
=> {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(trim_where, visitor)?;
sqlparser::ast::Visit::visit(trim_what, visitor)?;
sqlparser::ast::Visit::visit(trim_characters, visitor)?;
}
Self::Overlay {
expr, overlay_what, overlay_from, overlay_for } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(overlay_what, visitor)?;
sqlparser::ast::Visit::visit(overlay_from, visitor)?;
sqlparser::ast::Visit::visit(overlay_for, visitor)?;
}
Self::Collate { expr, collation } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(collation, visitor)?;
}
Self::Nested(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Value(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Prefixed { prefix, value } => {
sqlparser::ast::Visit::visit(prefix, visitor)?;
sqlparser::ast::Visit::visit(value, visitor)?;
}
Self::TypedString(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Function(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Case {
case_token, end_token, operand, conditions, else_result } =>
{
sqlparser::ast::Visit::visit(case_token, visitor)?;
sqlparser::ast::Visit::visit(end_token, visitor)?;
sqlparser::ast::Visit::visit(operand, visitor)?;
sqlparser::ast::Visit::visit(conditions, visitor)?;
sqlparser::ast::Visit::visit(else_result, visitor)?;
}
Self::Exists { subquery, negated } => {
sqlparser::ast::Visit::visit(subquery, visitor)?;
sqlparser::ast::Visit::visit(negated, visitor)?;
}
Self::Subquery(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::GroupingSets(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Cube(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Rollup(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Tuple(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Struct { values, fields } => {
sqlparser::ast::Visit::visit(values, visitor)?;
sqlparser::ast::Visit::visit(fields, visitor)?;
}
Self::Named { expr, name } => {
sqlparser::ast::Visit::visit(expr, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
}
Self::Dictionary(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Map(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Array(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Interval(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::MatchAgainst {
columns, match_value, opt_search_modifier } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
sqlparser::ast::Visit::visit(match_value, visitor)?;
sqlparser::ast::Visit::visit(opt_search_modifier, visitor)?;
}
Self::Wildcard(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::QualifiedWildcard(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
Self::OuterJoin(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Prior(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Lambda(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::MemberOf(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
visitor.post_visit_expr(self)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Expr {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
visitor.pre_visit_expr(self)?;
match self {
Self::Identifier(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CompoundIdentifier(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CompoundFieldAccess { root, access_chain } => {
sqlparser::ast::VisitMut::visit(root, visitor)?;
sqlparser::ast::VisitMut::visit(access_chain, visitor)?;
}
Self::JsonAccess { value, path } => {
sqlparser::ast::VisitMut::visit(value, visitor)?;
sqlparser::ast::VisitMut::visit(path, visitor)?;
}
Self::IsFalse(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsNotFalse(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsTrue(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsNotTrue(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsNull(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsNotNull(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsUnknown(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsNotUnknown(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsDistinctFrom(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
Self::IsNotDistinctFrom(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
Self::IsNormalized { expr, form, negated } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(form, visitor)?;
sqlparser::ast::VisitMut::visit(negated, visitor)?;
}
Self::InList { expr, list, negated } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(list, visitor)?;
sqlparser::ast::VisitMut::visit(negated, visitor)?;
}
Self::InSubquery { expr, subquery, negated } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(subquery, visitor)?;
sqlparser::ast::VisitMut::visit(negated, visitor)?;
}
Self::InUnnest { expr, array_expr, negated } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(array_expr, visitor)?;
sqlparser::ast::VisitMut::visit(negated, visitor)?;
}
Self::Between { expr, negated, low, high } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(negated, visitor)?;
sqlparser::ast::VisitMut::visit(low, visitor)?;
sqlparser::ast::VisitMut::visit(high, visitor)?;
}
Self::BinaryOp { left, op, right } => {
sqlparser::ast::VisitMut::visit(left, visitor)?;
sqlparser::ast::VisitMut::visit(op, visitor)?;
sqlparser::ast::VisitMut::visit(right, visitor)?;
}
Self::Like { negated, any, expr, pattern, escape_char } => {
sqlparser::ast::VisitMut::visit(negated, visitor)?;
sqlparser::ast::VisitMut::visit(any, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(pattern, visitor)?;
sqlparser::ast::VisitMut::visit(escape_char, visitor)?;
}
Self::ILike { negated, any, expr, pattern, escape_char } =>
{
sqlparser::ast::VisitMut::visit(negated, visitor)?;
sqlparser::ast::VisitMut::visit(any, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(pattern, visitor)?;
sqlparser::ast::VisitMut::visit(escape_char, visitor)?;
}
Self::SimilarTo { negated, expr, pattern, escape_char } => {
sqlparser::ast::VisitMut::visit(negated, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(pattern, visitor)?;
sqlparser::ast::VisitMut::visit(escape_char, visitor)?;
}
Self::RLike { negated, expr, pattern, regexp } => {
sqlparser::ast::VisitMut::visit(negated, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(pattern, visitor)?;
sqlparser::ast::VisitMut::visit(regexp, visitor)?;
}
Self::AnyOp { left, compare_op, right, is_some } => {
sqlparser::ast::VisitMut::visit(left, visitor)?;
sqlparser::ast::VisitMut::visit(compare_op, visitor)?;
sqlparser::ast::VisitMut::visit(right, visitor)?;
sqlparser::ast::VisitMut::visit(is_some, visitor)?;
}
Self::AllOp { left, compare_op, right } => {
sqlparser::ast::VisitMut::visit(left, visitor)?;
sqlparser::ast::VisitMut::visit(compare_op, visitor)?;
sqlparser::ast::VisitMut::visit(right, visitor)?;
}
Self::UnaryOp { op, expr } => {
sqlparser::ast::VisitMut::visit(op, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
}
Self::Convert {
is_try,
expr,
data_type,
charset,
target_before_value,
styles } => {
sqlparser::ast::VisitMut::visit(is_try, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(data_type, visitor)?;
sqlparser::ast::VisitMut::visit(charset, visitor)?;
sqlparser::ast::VisitMut::visit(target_before_value,
visitor)?;
sqlparser::ast::VisitMut::visit(styles, visitor)?;
}
Self::Cast { kind, expr, data_type, array, format } => {
sqlparser::ast::VisitMut::visit(kind, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(data_type, visitor)?;
sqlparser::ast::VisitMut::visit(array, visitor)?;
sqlparser::ast::VisitMut::visit(format, visitor)?;
}
Self::AtTimeZone { timestamp, time_zone } => {
sqlparser::ast::VisitMut::visit(timestamp, visitor)?;
sqlparser::ast::VisitMut::visit(time_zone, visitor)?;
}
Self::Extract { field, syntax, expr } => {
sqlparser::ast::VisitMut::visit(field, visitor)?;
sqlparser::ast::VisitMut::visit(syntax, visitor)?;
sqlparser::ast::VisitMut::visit(expr, visitor)?;
}
Self::Ceil { expr, field } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(field, visitor)?;
}
Self::Floor { expr, field } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(field, visitor)?;
}
Self::Position { expr, r#in } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(r#in, visitor)?;
}
Self::Substring {
expr, substring_from, substring_for, special, shorthand } =>
{
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(substring_from, visitor)?;
sqlparser::ast::VisitMut::visit(substring_for, visitor)?;
sqlparser::ast::VisitMut::visit(special, visitor)?;
sqlparser::ast::VisitMut::visit(shorthand, visitor)?;
}
Self::Trim { expr, trim_where, trim_what, trim_characters }
=> {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(trim_where, visitor)?;
sqlparser::ast::VisitMut::visit(trim_what, visitor)?;
sqlparser::ast::VisitMut::visit(trim_characters, visitor)?;
}
Self::Overlay {
expr, overlay_what, overlay_from, overlay_for } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(overlay_what, visitor)?;
sqlparser::ast::VisitMut::visit(overlay_from, visitor)?;
sqlparser::ast::VisitMut::visit(overlay_for, visitor)?;
}
Self::Collate { expr, collation } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(collation, visitor)?;
}
Self::Nested(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Value(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Prefixed { prefix, value } => {
sqlparser::ast::VisitMut::visit(prefix, visitor)?;
sqlparser::ast::VisitMut::visit(value, visitor)?;
}
Self::TypedString(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Function(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Case {
case_token, end_token, operand, conditions, else_result } =>
{
sqlparser::ast::VisitMut::visit(case_token, visitor)?;
sqlparser::ast::VisitMut::visit(end_token, visitor)?;
sqlparser::ast::VisitMut::visit(operand, visitor)?;
sqlparser::ast::VisitMut::visit(conditions, visitor)?;
sqlparser::ast::VisitMut::visit(else_result, visitor)?;
}
Self::Exists { subquery, negated } => {
sqlparser::ast::VisitMut::visit(subquery, visitor)?;
sqlparser::ast::VisitMut::visit(negated, visitor)?;
}
Self::Subquery(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::GroupingSets(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Cube(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Rollup(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Tuple(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Struct { values, fields } => {
sqlparser::ast::VisitMut::visit(values, visitor)?;
sqlparser::ast::VisitMut::visit(fields, visitor)?;
}
Self::Named { expr, name } => {
sqlparser::ast::VisitMut::visit(expr, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
}
Self::Dictionary(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Map(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Array(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Interval(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::MatchAgainst {
columns, match_value, opt_search_modifier } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
sqlparser::ast::VisitMut::visit(match_value, visitor)?;
sqlparser::ast::VisitMut::visit(opt_search_modifier,
visitor)?;
}
Self::Wildcard(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::QualifiedWildcard(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
Self::OuterJoin(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Prior(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Lambda(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::MemberOf(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
visitor.post_visit_expr(self)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut),
815 visit(with = "visit_expr")
816)]
817pub enum Expr {
818 Identifier(Ident),
820 CompoundIdentifier(Vec<Ident>),
822 CompoundFieldAccess {
841 root: Box<Expr>,
843 access_chain: Vec<AccessExpr>,
845 },
846 JsonAccess {
852 value: Box<Expr>,
854 path: JsonPath,
856 },
857 IsFalse(Box<Expr>),
859 IsNotFalse(Box<Expr>),
861 IsTrue(Box<Expr>),
863 IsNotTrue(Box<Expr>),
865 IsNull(Box<Expr>),
867 IsNotNull(Box<Expr>),
869 IsUnknown(Box<Expr>),
871 IsNotUnknown(Box<Expr>),
873 IsDistinctFrom(Box<Expr>, Box<Expr>),
875 IsNotDistinctFrom(Box<Expr>, Box<Expr>),
877 IsNormalized {
879 expr: Box<Expr>,
881 form: Option<NormalizationForm>,
883 negated: bool,
885 },
886 InList {
888 expr: Box<Expr>,
890 list: Vec<Expr>,
892 negated: bool,
894 },
895 InSubquery {
897 expr: Box<Expr>,
899 subquery: Box<Query>,
901 negated: bool,
903 },
904 InUnnest {
906 expr: Box<Expr>,
908 array_expr: Box<Expr>,
910 negated: bool,
912 },
913 Between {
915 expr: Box<Expr>,
917 negated: bool,
919 low: Box<Expr>,
921 high: Box<Expr>,
923 },
924 BinaryOp {
926 left: Box<Expr>,
928 op: BinaryOperator,
930 right: Box<Expr>,
932 },
933 Like {
935 negated: bool,
937 any: bool,
940 expr: Box<Expr>,
942 pattern: Box<Expr>,
944 escape_char: Option<Value>,
946 },
947 ILike {
949 negated: bool,
951 any: bool,
954 expr: Box<Expr>,
956 pattern: Box<Expr>,
958 escape_char: Option<Value>,
960 },
961 SimilarTo {
963 negated: bool,
965 expr: Box<Expr>,
967 pattern: Box<Expr>,
969 escape_char: Option<Value>,
971 },
972 RLike {
974 negated: bool,
976 expr: Box<Expr>,
978 pattern: Box<Expr>,
980 regexp: bool,
982 },
983 AnyOp {
986 left: Box<Expr>,
988 compare_op: BinaryOperator,
990 right: Box<Expr>,
992 is_some: bool,
994 },
995 AllOp {
998 left: Box<Expr>,
1000 compare_op: BinaryOperator,
1002 right: Box<Expr>,
1004 },
1005
1006 UnaryOp {
1008 op: UnaryOperator,
1010 expr: Box<Expr>,
1012 },
1013 Convert {
1015 is_try: bool,
1018 expr: Box<Expr>,
1020 data_type: Option<DataType>,
1022 charset: Option<ObjectName>,
1024 target_before_value: bool,
1026 styles: Vec<Expr>,
1030 },
1031 Cast {
1033 kind: CastKind,
1035 expr: Box<Expr>,
1037 data_type: DataType,
1039 array: bool,
1045 format: Option<CastFormat>,
1049 },
1050 AtTimeZone {
1052 timestamp: Box<Expr>,
1054 time_zone: Box<Expr>,
1056 },
1057 Extract {
1065 field: DateTimeField,
1067 syntax: ExtractSyntax,
1069 expr: Box<Expr>,
1071 },
1072 Ceil {
1079 expr: Box<Expr>,
1081 field: CeilFloorKind,
1083 },
1084 Floor {
1091 expr: Box<Expr>,
1093 field: CeilFloorKind,
1095 },
1096 Position {
1100 expr: Box<Expr>,
1102 r#in: Box<Expr>,
1104 },
1105 Substring {
1113 expr: Box<Expr>,
1115 substring_from: Option<Box<Expr>>,
1117 substring_for: Option<Box<Expr>>,
1119
1120 special: bool,
1124
1125 shorthand: bool,
1128 },
1129 Trim {
1135 expr: Box<Expr>,
1137 trim_where: Option<TrimWhereField>,
1139 trim_what: Option<Box<Expr>>,
1141 trim_characters: Option<Vec<Expr>>,
1143 },
1144 Overlay {
1148 expr: Box<Expr>,
1150 overlay_what: Box<Expr>,
1152 overlay_from: Box<Expr>,
1154 overlay_for: Option<Box<Expr>>,
1156 },
1157 Collate {
1159 expr: Box<Expr>,
1161 collation: ObjectName,
1163 },
1164 Nested(Box<Expr>),
1166 Value(ValueWithSpan),
1168 Prefixed {
1172 prefix: Ident,
1174 value: Box<Expr>,
1177 },
1178 TypedString(TypedString),
1182 Function(Function),
1184 Case {
1190 case_token: AttachedToken,
1192 end_token: AttachedToken,
1194 operand: Option<Box<Expr>>,
1196 conditions: Vec<CaseWhen>,
1198 else_result: Option<Box<Expr>>,
1200 },
1201 Exists {
1204 subquery: Box<Query>,
1206 negated: bool,
1208 },
1209 Subquery(Box<Query>),
1212 GroupingSets(Vec<Vec<Expr>>),
1214 Cube(Vec<Vec<Expr>>),
1216 Rollup(Vec<Vec<Expr>>),
1218 Tuple(Vec<Expr>),
1220 Struct {
1229 values: Vec<Expr>,
1231 fields: Vec<StructField>,
1233 },
1234 Named {
1242 expr: Box<Expr>,
1244 name: Ident,
1246 },
1247 Dictionary(Vec<DictionaryField>),
1255 Map(Map),
1263 Array(Array),
1265 Interval(Interval),
1267 MatchAgainst {
1278 columns: Vec<ObjectName>,
1280 match_value: Value,
1282 opt_search_modifier: Option<SearchModifier>,
1284 },
1285 Wildcard(AttachedToken),
1287 QualifiedWildcard(ObjectName, AttachedToken),
1290 OuterJoin(Box<Expr>),
1305 Prior(Box<Expr>),
1307 Lambda(LambdaFunction),
1318 MemberOf(MemberOf),
1320}
1321
1322impl Expr {
1323 pub fn value(value: impl Into<ValueWithSpan>) -> Self {
1325 Expr::Value(value.into())
1326 }
1327}
1328
1329#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Subscript {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Subscript::Index { index: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Index",
"index", &__self_0),
Subscript::Slice {
lower_bound: __self_0, upper_bound: __self_1, stride: __self_2
} =>
::core::fmt::Formatter::debug_struct_field3_finish(f, "Slice",
"lower_bound", __self_0, "upper_bound", __self_1, "stride",
&__self_2),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Subscript {
#[inline]
fn clone(&self) -> Subscript {
match self {
Subscript::Index { index: __self_0 } =>
Subscript::Index {
index: ::core::clone::Clone::clone(__self_0),
},
Subscript::Slice {
lower_bound: __self_0, upper_bound: __self_1, stride: __self_2
} =>
Subscript::Slice {
lower_bound: ::core::clone::Clone::clone(__self_0),
upper_bound: ::core::clone::Clone::clone(__self_1),
stride: ::core::clone::Clone::clone(__self_2),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Subscript {
#[inline]
fn eq(&self, other: &Subscript) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Subscript::Index { index: __self_0 }, Subscript::Index {
index: __arg1_0 }) => __self_0 == __arg1_0,
(Subscript::Slice {
lower_bound: __self_0,
upper_bound: __self_1,
stride: __self_2 }, Subscript::Slice {
lower_bound: __arg1_0,
upper_bound: __arg1_1,
stride: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Subscript {
#[inline]
fn partial_cmp(&self, other: &Subscript)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Subscript {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Subscript {
#[inline]
fn cmp(&self, other: &Subscript) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Subscript::Index { index: __self_0 }, Subscript::Index {
index: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Subscript::Slice {
lower_bound: __self_0,
upper_bound: __self_1,
stride: __self_2 }, Subscript::Slice {
lower_bound: __arg1_0,
upper_bound: __arg1_1,
stride: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Subscript {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Subscript::Index { index: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Subscript::Slice {
lower_bound: __self_0, upper_bound: __self_1, stride: __self_2
} => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
}
}
}Hash)]
1331#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
1332#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Subscript {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Index { index } => {
sqlparser::ast::Visit::visit(index, visitor)?;
}
Self::Slice { lower_bound, upper_bound, stride } => {
sqlparser::ast::Visit::visit(lower_bound, visitor)?;
sqlparser::ast::Visit::visit(upper_bound, visitor)?;
sqlparser::ast::Visit::visit(stride, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Subscript {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Index { index } => {
sqlparser::ast::VisitMut::visit(index, visitor)?;
}
Self::Slice { lower_bound, upper_bound, stride } => {
sqlparser::ast::VisitMut::visit(lower_bound, visitor)?;
sqlparser::ast::VisitMut::visit(upper_bound, visitor)?;
sqlparser::ast::VisitMut::visit(stride, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
1333pub enum Subscript {
1334 Index {
1336 index: Expr,
1338 },
1339
1340 Slice {
1362 lower_bound: Option<Expr>,
1364 upper_bound: Option<Expr>,
1366 stride: Option<Expr>,
1368 },
1369}
1370
1371impl fmt::Display for Subscript {
1372 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1373 match self {
1374 Subscript::Index { index } => f.write_fmt(format_args!("{0}", index))write!(f, "{index}"),
1375 Subscript::Slice {
1376 lower_bound,
1377 upper_bound,
1378 stride,
1379 } => {
1380 if let Some(lower) = lower_bound {
1381 f.write_fmt(format_args!("{0}", lower))write!(f, "{lower}")?;
1382 }
1383 f.write_fmt(format_args!(":"))write!(f, ":")?;
1384 if let Some(upper) = upper_bound {
1385 f.write_fmt(format_args!("{0}", upper))write!(f, "{upper}")?;
1386 }
1387 if let Some(stride) = stride {
1388 f.write_fmt(format_args!(":"))write!(f, ":")?;
1389 f.write_fmt(format_args!("{0}", stride))write!(f, "{stride}")?;
1390 }
1391 Ok(())
1392 }
1393 }
1394 }
1395}
1396
1397#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AccessExpr {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
AccessExpr::Dot(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Dot",
&__self_0),
AccessExpr::Subscript(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Subscript", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AccessExpr {
#[inline]
fn clone(&self) -> AccessExpr {
match self {
AccessExpr::Dot(__self_0) =>
AccessExpr::Dot(::core::clone::Clone::clone(__self_0)),
AccessExpr::Subscript(__self_0) =>
AccessExpr::Subscript(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AccessExpr {
#[inline]
fn eq(&self, other: &AccessExpr) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(AccessExpr::Dot(__self_0), AccessExpr::Dot(__arg1_0)) =>
__self_0 == __arg1_0,
(AccessExpr::Subscript(__self_0),
AccessExpr::Subscript(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AccessExpr {
#[inline]
fn partial_cmp(&self, other: &AccessExpr)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AccessExpr {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Subscript>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AccessExpr {
#[inline]
fn cmp(&self, other: &AccessExpr) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(AccessExpr::Dot(__self_0), AccessExpr::Dot(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(AccessExpr::Subscript(__self_0),
AccessExpr::Subscript(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AccessExpr {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
AccessExpr::Dot(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
AccessExpr::Subscript(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
1400#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
1401#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AccessExpr {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Dot(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Subscript(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AccessExpr {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Dot(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Subscript(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
1402pub enum AccessExpr {
1403 Dot(Expr),
1405 Subscript(Subscript),
1407}
1408
1409impl fmt::Display for AccessExpr {
1410 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1411 match self {
1412 AccessExpr::Dot(expr) => f.write_fmt(format_args!(".{0}", expr))write!(f, ".{expr}"),
1413 AccessExpr::Subscript(subscript) => f.write_fmt(format_args!("[{0}]", subscript))write!(f, "[{subscript}]"),
1414 }
1415 }
1416}
1417
1418#[derive(#[automatically_derived]
impl ::core::fmt::Debug for LambdaFunction {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"LambdaFunction", "params", &self.params, "body", &self.body,
"syntax", &&self.syntax)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for LambdaFunction {
#[inline]
fn clone(&self) -> LambdaFunction {
LambdaFunction {
params: ::core::clone::Clone::clone(&self.params),
body: ::core::clone::Clone::clone(&self.body),
syntax: ::core::clone::Clone::clone(&self.syntax),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for LambdaFunction {
#[inline]
fn eq(&self, other: &LambdaFunction) -> bool {
self.params == other.params && self.body == other.body &&
self.syntax == other.syntax
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for LambdaFunction {
#[inline]
fn partial_cmp(&self, other: &LambdaFunction)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for LambdaFunction {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<OneOrManyWithParens<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<LambdaSyntax>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for LambdaFunction {
#[inline]
fn cmp(&self, other: &LambdaFunction) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.params, &other.params) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.body, &other.body) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.syntax, &other.syntax),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for LambdaFunction {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.params, state);
::core::hash::Hash::hash(&self.body, state);
::core::hash::Hash::hash(&self.syntax, state)
}
}Hash)]
1420#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
1421#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for LambdaFunction {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.params, visitor)?;
sqlparser::ast::Visit::visit(&self.body, visitor)?;
sqlparser::ast::Visit::visit(&self.syntax, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for LambdaFunction {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.params, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.body, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.syntax, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
1422pub struct LambdaFunction {
1423 pub params: OneOrManyWithParens<Ident>,
1425 pub body: Box<Expr>,
1427 pub syntax: LambdaSyntax,
1429}
1430
1431impl fmt::Display for LambdaFunction {
1432 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1433 match self.syntax {
1434 LambdaSyntax::Arrow => f.write_fmt(format_args!("{0} -> {1}", self.params, self.body))write!(f, "{} -> {}", self.params, self.body),
1435 LambdaSyntax::LambdaKeyword => {
1436 f.write_fmt(format_args!("lambda "))write!(f, "lambda ")?;
1439 match &self.params {
1440 OneOrManyWithParens::One(p) => f.write_fmt(format_args!("{0}", p))write!(f, "{p}")?,
1441 OneOrManyWithParens::Many(ps) => f.write_fmt(format_args!("{0}", display_comma_separated(ps)))write!(f, "{}", display_comma_separated(ps))?,
1442 };
1443 f.write_fmt(format_args!(" : {0}", self.body))write!(f, " : {}", self.body)
1444 }
1445 }
1446 }
1447}
1448
1449#[derive(#[automatically_derived]
impl ::core::fmt::Debug for LambdaSyntax {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
LambdaSyntax::Arrow => "Arrow",
LambdaSyntax::LambdaKeyword => "LambdaKeyword",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for LambdaSyntax {
#[inline]
fn clone(&self) -> LambdaSyntax { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for LambdaSyntax {
#[inline]
fn eq(&self, other: &LambdaSyntax) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for LambdaSyntax {
#[inline]
fn partial_cmp(&self, other: &LambdaSyntax)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for LambdaSyntax {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for LambdaSyntax {
#[inline]
fn cmp(&self, other: &LambdaSyntax) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for LambdaSyntax {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash, #[automatically_derived]
impl ::core::marker::Copy for LambdaSyntax { }Copy)]
1451#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
1452#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for LambdaSyntax {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Arrow => {} Self::LambdaKeyword => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for LambdaSyntax {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Arrow => {} Self::LambdaKeyword => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
1453pub enum LambdaSyntax {
1454 Arrow,
1461 LambdaKeyword,
1466}
1467
1468#[derive(#[automatically_derived]
impl<T: ::core::fmt::Debug> ::core::fmt::Debug for OneOrManyWithParens<T> {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
OneOrManyWithParens::One(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "One",
&__self_0),
OneOrManyWithParens::Many(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Many",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl<T: ::core::clone::Clone> ::core::clone::Clone for OneOrManyWithParens<T>
{
#[inline]
fn clone(&self) -> OneOrManyWithParens<T> {
match self {
OneOrManyWithParens::One(__self_0) =>
OneOrManyWithParens::One(::core::clone::Clone::clone(__self_0)),
OneOrManyWithParens::Many(__self_0) =>
OneOrManyWithParens::Many(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl<T: ::core::cmp::PartialEq> ::core::cmp::PartialEq for
OneOrManyWithParens<T> {
#[inline]
fn eq(&self, other: &OneOrManyWithParens<T>) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(OneOrManyWithParens::One(__self_0),
OneOrManyWithParens::One(__arg1_0)) => __self_0 == __arg1_0,
(OneOrManyWithParens::Many(__self_0),
OneOrManyWithParens::Many(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl<T: ::core::cmp::PartialOrd> ::core::cmp::PartialOrd for
OneOrManyWithParens<T> {
#[inline]
fn partial_cmp(&self, other: &OneOrManyWithParens<T>)
-> ::core::option::Option<::core::cmp::Ordering> {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match (self, other) {
(OneOrManyWithParens::One(__self_0),
OneOrManyWithParens::One(__arg1_0)) =>
::core::cmp::PartialOrd::partial_cmp(__self_0, __arg1_0),
(OneOrManyWithParens::Many(__self_0),
OneOrManyWithParens::Many(__arg1_0)) =>
::core::cmp::PartialOrd::partial_cmp(__self_0, __arg1_0),
_ =>
::core::cmp::PartialOrd::partial_cmp(&__self_discr,
&__arg1_discr),
}
}
}PartialOrd, #[automatically_derived]
impl<T: ::core::cmp::Eq> ::core::cmp::Eq for OneOrManyWithParens<T> {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<T>;
let _: ::core::cmp::AssertParamIsEq<Vec<T>>;
}
}Eq, #[automatically_derived]
impl<T: ::core::cmp::Ord> ::core::cmp::Ord for OneOrManyWithParens<T> {
#[inline]
fn cmp(&self, other: &OneOrManyWithParens<T>) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(OneOrManyWithParens::One(__self_0),
OneOrManyWithParens::One(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(OneOrManyWithParens::Many(__self_0),
OneOrManyWithParens::Many(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl<T: ::core::hash::Hash> ::core::hash::Hash for OneOrManyWithParens<T> {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
OneOrManyWithParens::One(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
OneOrManyWithParens::Many(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
1491#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
1492#[cfg_attr(feature = "visitor", derive(impl<T: sqlparser::ast::Visit> sqlparser::ast::Visit for
OneOrManyWithParens<T> {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::One(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Many(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl<T: sqlparser::ast::VisitMut> sqlparser::ast::VisitMut for
OneOrManyWithParens<T> {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::One(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Many(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
1493pub enum OneOrManyWithParens<T> {
1494 One(T),
1496 Many(Vec<T>),
1498}
1499
1500impl<T> Deref for OneOrManyWithParens<T> {
1501 type Target = [T];
1502
1503 fn deref(&self) -> &[T] {
1504 match self {
1505 OneOrManyWithParens::One(one) => core::slice::from_ref(one),
1506 OneOrManyWithParens::Many(many) => many,
1507 }
1508 }
1509}
1510
1511impl<T> AsRef<[T]> for OneOrManyWithParens<T> {
1512 fn as_ref(&self) -> &[T] {
1513 self
1514 }
1515}
1516
1517impl<'a, T> IntoIterator for &'a OneOrManyWithParens<T> {
1518 type Item = &'a T;
1519 type IntoIter = core::slice::Iter<'a, T>;
1520
1521 fn into_iter(self) -> Self::IntoIter {
1522 self.iter()
1523 }
1524}
1525
1526#[derive(#[automatically_derived]
impl<T: ::core::fmt::Debug> ::core::fmt::Debug for
OneOrManyWithParensIntoIter<T> {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"OneOrManyWithParensIntoIter", "inner", &&self.inner)
}
}Debug, #[automatically_derived]
impl<T: ::core::clone::Clone> ::core::clone::Clone for
OneOrManyWithParensIntoIter<T> {
#[inline]
fn clone(&self) -> OneOrManyWithParensIntoIter<T> {
OneOrManyWithParensIntoIter {
inner: ::core::clone::Clone::clone(&self.inner),
}
}
}Clone)]
1528pub struct OneOrManyWithParensIntoIter<T> {
1529 inner: OneOrManyWithParensIntoIterInner<T>,
1530}
1531
1532#[derive(#[automatically_derived]
impl<T: ::core::fmt::Debug> ::core::fmt::Debug for
OneOrManyWithParensIntoIterInner<T> {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
OneOrManyWithParensIntoIterInner::One(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "One",
&__self_0),
OneOrManyWithParensIntoIterInner::Many(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Many",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl<T: ::core::clone::Clone> ::core::clone::Clone for
OneOrManyWithParensIntoIterInner<T> {
#[inline]
fn clone(&self) -> OneOrManyWithParensIntoIterInner<T> {
match self {
OneOrManyWithParensIntoIterInner::One(__self_0) =>
OneOrManyWithParensIntoIterInner::One(::core::clone::Clone::clone(__self_0)),
OneOrManyWithParensIntoIterInner::Many(__self_0) =>
OneOrManyWithParensIntoIterInner::Many(::core::clone::Clone::clone(__self_0)),
}
}
}Clone)]
1533enum OneOrManyWithParensIntoIterInner<T> {
1534 One(core::iter::Once<T>),
1535 Many(<Vec<T> as IntoIterator>::IntoIter),
1536}
1537
1538impl<T> core::iter::FusedIterator for OneOrManyWithParensIntoIter<T>
1539where
1540 core::iter::Once<T>: core::iter::FusedIterator,
1541 <Vec<T> as IntoIterator>::IntoIter: core::iter::FusedIterator,
1542{
1543}
1544
1545impl<T> core::iter::ExactSizeIterator for OneOrManyWithParensIntoIter<T>
1546where
1547 core::iter::Once<T>: core::iter::ExactSizeIterator,
1548 <Vec<T> as IntoIterator>::IntoIter: core::iter::ExactSizeIterator,
1549{
1550}
1551
1552impl<T> core::iter::Iterator for OneOrManyWithParensIntoIter<T> {
1553 type Item = T;
1554
1555 fn next(&mut self) -> Option<Self::Item> {
1556 match &mut self.inner {
1557 OneOrManyWithParensIntoIterInner::One(one) => one.next(),
1558 OneOrManyWithParensIntoIterInner::Many(many) => many.next(),
1559 }
1560 }
1561
1562 fn size_hint(&self) -> (usize, Option<usize>) {
1563 match &self.inner {
1564 OneOrManyWithParensIntoIterInner::One(one) => one.size_hint(),
1565 OneOrManyWithParensIntoIterInner::Many(many) => many.size_hint(),
1566 }
1567 }
1568
1569 fn count(self) -> usize
1570 where
1571 Self: Sized,
1572 {
1573 match self.inner {
1574 OneOrManyWithParensIntoIterInner::One(one) => one.count(),
1575 OneOrManyWithParensIntoIterInner::Many(many) => many.count(),
1576 }
1577 }
1578
1579 fn fold<B, F>(mut self, init: B, f: F) -> B
1580 where
1581 Self: Sized,
1582 F: FnMut(B, Self::Item) -> B,
1583 {
1584 match &mut self.inner {
1585 OneOrManyWithParensIntoIterInner::One(one) => one.fold(init, f),
1586 OneOrManyWithParensIntoIterInner::Many(many) => many.fold(init, f),
1587 }
1588 }
1589}
1590
1591impl<T> core::iter::DoubleEndedIterator for OneOrManyWithParensIntoIter<T> {
1592 fn next_back(&mut self) -> Option<Self::Item> {
1593 match &mut self.inner {
1594 OneOrManyWithParensIntoIterInner::One(one) => one.next_back(),
1595 OneOrManyWithParensIntoIterInner::Many(many) => many.next_back(),
1596 }
1597 }
1598}
1599
1600impl<T> IntoIterator for OneOrManyWithParens<T> {
1601 type Item = T;
1602
1603 type IntoIter = OneOrManyWithParensIntoIter<T>;
1604
1605 fn into_iter(self) -> Self::IntoIter {
1606 let inner = match self {
1607 OneOrManyWithParens::One(one) => {
1608 OneOrManyWithParensIntoIterInner::One(core::iter::once(one))
1609 }
1610 OneOrManyWithParens::Many(many) => {
1611 OneOrManyWithParensIntoIterInner::Many(many.into_iter())
1612 }
1613 };
1614
1615 OneOrManyWithParensIntoIter { inner }
1616 }
1617}
1618
1619impl<T> fmt::Display for OneOrManyWithParens<T>
1620where
1621 T: fmt::Display,
1622{
1623 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
1624 match self {
1625 OneOrManyWithParens::One(value) => f.write_fmt(format_args!("{0}", value))write!(f, "{value}"),
1626 OneOrManyWithParens::Many(values) => {
1627 f.write_fmt(format_args!("({0})", display_comma_separated(values)))write!(f, "({})", display_comma_separated(values))
1628 }
1629 }
1630 }
1631}
1632
1633impl fmt::Display for CastFormat {
1634 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
1635 match self {
1636 CastFormat::Value(v) => f.write_fmt(format_args!("{0}", v))write!(f, "{v}"),
1637 CastFormat::ValueAtTimeZone(v, tz) => f.write_fmt(format_args!("{0} AT TIME ZONE {1}", v, tz))write!(f, "{v} AT TIME ZONE {tz}"),
1638 }
1639 }
1640}
1641
1642impl fmt::Display for Expr {
1643 #[cfg_attr(feature = "recursive-protection", fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> fmt::Result
{
{
match self {
Expr::Identifier(s) => f.write_fmt(format_args!("{0}", s)),
Expr::Wildcard(_) => f.write_str("*"),
Expr::QualifiedWildcard(prefix, _) =>
f.write_fmt(format_args!("{0}.*", prefix)),
Expr::CompoundIdentifier(s) =>
f.write_fmt(format_args!("{0}", display_separated(s, "."))),
Expr::CompoundFieldAccess { root, access_chain } => {
f.write_fmt(format_args!("{0}", root))?;
for field in access_chain {
f.write_fmt(format_args!("{0}", field))?;
}
Ok(())
}
Expr::IsTrue(ast) =>
f.write_fmt(format_args!("{0} IS TRUE", ast)),
Expr::IsNotTrue(ast) =>
f.write_fmt(format_args!("{0} IS NOT TRUE", ast)),
Expr::IsFalse(ast) =>
f.write_fmt(format_args!("{0} IS FALSE", ast)),
Expr::IsNotFalse(ast) =>
f.write_fmt(format_args!("{0} IS NOT FALSE", ast)),
Expr::IsNull(ast) =>
f.write_fmt(format_args!("{0} IS NULL", ast)),
Expr::IsNotNull(ast) =>
f.write_fmt(format_args!("{0} IS NOT NULL", ast)),
Expr::IsUnknown(ast) =>
f.write_fmt(format_args!("{0} IS UNKNOWN", ast)),
Expr::IsNotUnknown(ast) =>
f.write_fmt(format_args!("{0} IS NOT UNKNOWN", ast)),
Expr::InList { expr, list, negated } =>
f.write_fmt(format_args!("{0} {1}IN ({2})", expr,
if *negated { "NOT " } else { "" },
display_comma_separated(list))),
Expr::InSubquery { expr, subquery, negated } =>
f.write_fmt(format_args!("{0} {1}IN ({2})", expr,
if *negated { "NOT " } else { "" }, subquery)),
Expr::InUnnest { expr, array_expr, negated } =>
f.write_fmt(format_args!("{0} {1}IN UNNEST({2})", expr,
if *negated { "NOT " } else { "" }, array_expr)),
Expr::Between { expr, negated, low, high } =>
f.write_fmt(format_args!("{0} {1}BETWEEN {2} AND {3}", expr,
if *negated { "NOT " } else { "" }, low, high)),
Expr::BinaryOp { left, op, right } =>
f.write_fmt(format_args!("{0} {1} {2}", left, op, right)),
Expr::Like { negated, expr, pattern, escape_char, any } =>
match escape_char {
Some(ch) =>
f.write_fmt(format_args!("{0} {1}LIKE {2}{3} ESCAPE {4}",
expr, if *negated { "NOT " } else { "" },
if *any { "ANY " } else { "" }, pattern, ch)),
_ =>
f.write_fmt(format_args!("{0} {1}LIKE {2}{3}", expr,
if *negated { "NOT " } else { "" },
if *any { "ANY " } else { "" }, pattern)),
},
Expr::ILike { negated, expr, pattern, escape_char, any } =>
match escape_char {
Some(ch) =>
f.write_fmt(format_args!("{0} {1}ILIKE {2}{3} ESCAPE {4}",
expr, if *negated { "NOT " } else { "" },
if *any { "ANY" } else { "" }, pattern, ch)),
_ =>
f.write_fmt(format_args!("{0} {1}ILIKE {2}{3}", expr,
if *negated { "NOT " } else { "" },
if *any { "ANY " } else { "" }, pattern)),
},
Expr::RLike { negated, expr, pattern, regexp } =>
f.write_fmt(format_args!("{0} {1}{2} {3}", expr,
if *negated { "NOT " } else { "" },
if *regexp { "REGEXP" } else { "RLIKE" }, pattern)),
Expr::IsNormalized { expr, form, negated } => {
let not_ = if *negated { "NOT " } else { "" };
if form.is_none() {
f.write_fmt(format_args!("{0} IS {1}NORMALIZED", expr,
not_))
} else {
f.write_fmt(format_args!("{0} IS {1}{2} NORMALIZED", expr,
not_, form.as_ref().unwrap()))
}
}
Expr::SimilarTo { negated, expr, pattern, escape_char } =>
match escape_char {
Some(ch) =>
f.write_fmt(format_args!("{0} {1}SIMILAR TO {2} ESCAPE {3}",
expr, if *negated { "NOT " } else { "" }, pattern, ch)),
_ =>
f.write_fmt(format_args!("{0} {1}SIMILAR TO {2}", expr,
if *negated { "NOT " } else { "" }, pattern)),
},
Expr::AnyOp { left, compare_op, right, is_some } => {
let add_parens =
!#[allow(non_exhaustive_omitted_patterns)] match right.as_ref()
{
Expr::Subquery(_) => true,
_ => false,
};
f.write_fmt(format_args!("{3} {4} {0}{1}{5}{2}",
if *is_some { "SOME" } else { "ANY" },
if add_parens { "(" } else { "" },
if add_parens { ")" } else { "" }, left, compare_op, right))
}
Expr::AllOp { left, compare_op, right } => {
let add_parens =
!#[allow(non_exhaustive_omitted_patterns)] match right.as_ref()
{
Expr::Subquery(_) => true,
_ => false,
};
f.write_fmt(format_args!("{2} {3} ALL{0}{4}{1}",
if add_parens { "(" } else { "" },
if add_parens { ")" } else { "" }, left, compare_op, right))
}
Expr::UnaryOp { op, expr } => {
if op == &UnaryOperator::PGPostfixFactorial {
f.write_fmt(format_args!("{0}{1}", expr, op))
} else if #[allow(non_exhaustive_omitted_patterns)] match op
{
UnaryOperator::Not | UnaryOperator::Hash |
UnaryOperator::AtDashAt | UnaryOperator::DoubleAt |
UnaryOperator::QuestionDash | UnaryOperator::QuestionPipe =>
true,
_ => false,
} {
f.write_fmt(format_args!("{0} {1}", op, expr))
} else { f.write_fmt(format_args!("{0}{1}", op, expr)) }
}
Expr::Convert {
is_try,
expr,
target_before_value,
data_type,
charset,
styles } => {
f.write_fmt(format_args!("{0}CONVERT(",
if *is_try { "TRY_" } else { "" }))?;
if let Some(data_type) = data_type {
if let Some(charset) = charset {
f.write_fmt(format_args!("{0}, {1} CHARACTER SET {2}", expr,
data_type, charset))
} else if *target_before_value {
f.write_fmt(format_args!("{0}, {1}", data_type, expr))
} else {
f.write_fmt(format_args!("{0}, {1}", expr, data_type))
}
} else if let Some(charset) = charset {
f.write_fmt(format_args!("{0} USING {1}", expr, charset))
} else { f.write_fmt(format_args!("{0}", expr)) }?;
if !styles.is_empty() {
f.write_fmt(format_args!(", {0}",
display_comma_separated(styles)))?;
}
f.write_fmt(format_args!(")"))
}
Expr::Cast { kind, expr, data_type, array, format } =>
match kind {
CastKind::Cast => {
f.write_fmt(format_args!("CAST({0} AS {1}", expr,
data_type))?;
if *array { f.write_fmt(format_args!(" ARRAY"))?; }
if let Some(format) = format {
f.write_fmt(format_args!(" FORMAT {0}", format))?;
}
f.write_fmt(format_args!(")"))
}
CastKind::TryCast => {
if let Some(format) = format {
f.write_fmt(format_args!("TRY_CAST({0} AS {1} FORMAT {2})",
expr, data_type, format))
} else {
f.write_fmt(format_args!("TRY_CAST({0} AS {1})", expr,
data_type))
}
}
CastKind::SafeCast => {
if let Some(format) = format {
f.write_fmt(format_args!("SAFE_CAST({0} AS {1} FORMAT {2})",
expr, data_type, format))
} else {
f.write_fmt(format_args!("SAFE_CAST({0} AS {1})", expr,
data_type))
}
}
CastKind::DoubleColon => {
f.write_fmt(format_args!("{0}::{1}", expr, data_type))
}
},
Expr::Extract { field, syntax, expr } =>
match syntax {
ExtractSyntax::From =>
f.write_fmt(format_args!("EXTRACT({0} FROM {1})", field,
expr)),
ExtractSyntax::Comma =>
f.write_fmt(format_args!("EXTRACT({0}, {1})", field, expr)),
},
Expr::Ceil { expr, field } =>
match field {
CeilFloorKind::DateTimeField(DateTimeField::NoDateTime) => {
f.write_fmt(format_args!("CEIL({0})", expr))
}
CeilFloorKind::DateTimeField(dt_field) =>
f.write_fmt(format_args!("CEIL({0} TO {1})", expr,
dt_field)),
CeilFloorKind::Scale(s) =>
f.write_fmt(format_args!("CEIL({0}, {1})", expr, s)),
},
Expr::Floor { expr, field } =>
match field {
CeilFloorKind::DateTimeField(DateTimeField::NoDateTime) => {
f.write_fmt(format_args!("FLOOR({0})", expr))
}
CeilFloorKind::DateTimeField(dt_field) =>
f.write_fmt(format_args!("FLOOR({0} TO {1})", expr,
dt_field)),
CeilFloorKind::Scale(s) =>
f.write_fmt(format_args!("FLOOR({0}, {1})", expr, s)),
},
Expr::Position { expr, r#in } =>
f.write_fmt(format_args!("POSITION({0} IN {1})", expr,
r#in)),
Expr::Collate { expr, collation } =>
f.write_fmt(format_args!("{0} COLLATE {1}", expr,
collation)),
Expr::Nested(ast) =>
f.write_fmt(format_args!("({0})", ast)),
Expr::Value(v) => f.write_fmt(format_args!("{0}", v)),
Expr::Prefixed { prefix, value } =>
f.write_fmt(format_args!("{0} {1}", prefix, value)),
Expr::TypedString(ts) => ts.fmt(f),
Expr::Function(fun) => fun.fmt(f),
Expr::Case {
case_token: _,
end_token: _,
operand,
conditions,
else_result } => {
f.write_str("CASE")?;
if let Some(operand) = operand {
f.write_str(" ")?;
operand.fmt(f)?;
}
for when in conditions {
SpaceOrNewline.fmt(f)?;
Indent(when).fmt(f)?;
}
if let Some(else_result) = else_result {
SpaceOrNewline.fmt(f)?;
Indent("ELSE").fmt(f)?;
SpaceOrNewline.fmt(f)?;
Indent(Indent(else_result)).fmt(f)?;
}
SpaceOrNewline.fmt(f)?;
f.write_str("END")
}
Expr::Exists { subquery, negated } =>
f.write_fmt(format_args!("{0}EXISTS ({1})",
if *negated { "NOT " } else { "" }, subquery)),
Expr::Subquery(s) => f.write_fmt(format_args!("({0})", s)),
Expr::GroupingSets(sets) => {
f.write_fmt(format_args!("GROUPING SETS ("))?;
let mut sep = "";
for set in sets {
f.write_fmt(format_args!("{0}", sep))?;
sep = ", ";
f.write_fmt(format_args!("({0})",
display_comma_separated(set)))?;
}
f.write_fmt(format_args!(")"))
}
Expr::Cube(sets) => {
f.write_fmt(format_args!("CUBE ("))?;
let mut sep = "";
for set in sets {
f.write_fmt(format_args!("{0}", sep))?;
sep = ", ";
if set.len() == 1 {
f.write_fmt(format_args!("{0}", set[0]))?;
} else {
f.write_fmt(format_args!("({0})",
display_comma_separated(set)))?;
}
}
f.write_fmt(format_args!(")"))
}
Expr::Rollup(sets) => {
f.write_fmt(format_args!("ROLLUP ("))?;
let mut sep = "";
for set in sets {
f.write_fmt(format_args!("{0}", sep))?;
sep = ", ";
if set.len() == 1 {
f.write_fmt(format_args!("{0}", set[0]))?;
} else {
f.write_fmt(format_args!("({0})",
display_comma_separated(set)))?;
}
}
f.write_fmt(format_args!(")"))
}
Expr::Substring {
expr, substring_from, substring_for, special, shorthand } =>
{
f.write_str("SUBSTR")?;
if !*shorthand { f.write_str("ING")?; }
f.write_fmt(format_args!("({0}", expr))?;
if let Some(from_part) = substring_from {
if *special {
f.write_fmt(format_args!(", {0}", from_part))?;
} else {
f.write_fmt(format_args!(" FROM {0}", from_part))?;
}
}
if let Some(for_part) = substring_for {
if *special {
f.write_fmt(format_args!(", {0}", for_part))?;
} else { f.write_fmt(format_args!(" FOR {0}", for_part))?; }
}
f.write_fmt(format_args!(")"))
}
Expr::Overlay {
expr, overlay_what, overlay_from, overlay_for } => {
f.write_fmt(format_args!("OVERLAY({0} PLACING {1} FROM {2}",
expr, overlay_what, overlay_from))?;
if let Some(for_part) = overlay_for {
f.write_fmt(format_args!(" FOR {0}", for_part))?;
}
f.write_fmt(format_args!(")"))
}
Expr::IsDistinctFrom(a, b) =>
f.write_fmt(format_args!("{0} IS DISTINCT FROM {1}", a, b)),
Expr::IsNotDistinctFrom(a, b) =>
f.write_fmt(format_args!("{0} IS NOT DISTINCT FROM {1}", a,
b)),
Expr::Trim { expr, trim_where, trim_what, trim_characters }
=> {
f.write_fmt(format_args!("TRIM("))?;
if let Some(ident) = trim_where {
f.write_fmt(format_args!("{0} ", ident))?;
}
if let Some(trim_char) = trim_what {
f.write_fmt(format_args!("{0} FROM {1}", trim_char, expr))?;
} else { f.write_fmt(format_args!("{0}", expr))?; }
if let Some(characters) = trim_characters {
f.write_fmt(format_args!(", {0}",
display_comma_separated(characters)))?;
}
f.write_fmt(format_args!(")"))
}
Expr::Tuple(exprs) => {
f.write_fmt(format_args!("({0})",
display_comma_separated(exprs)))
}
Expr::Struct { values, fields } => {
if !fields.is_empty() {
f.write_fmt(format_args!("STRUCT<{0}>({1})",
display_comma_separated(fields),
display_comma_separated(values)))
} else {
f.write_fmt(format_args!("STRUCT({0})",
display_comma_separated(values)))
}
}
Expr::Named { expr, name } => {
f.write_fmt(format_args!("{0} AS {1}", expr, name))
}
Expr::Dictionary(fields) => {
f.write_fmt(format_args!("{{{0}}}",
display_comma_separated(fields)))
}
Expr::Map(map) => { f.write_fmt(format_args!("{0}", map)) }
Expr::Array(set) => {
f.write_fmt(format_args!("{0}", set))
}
Expr::JsonAccess { value, path } => {
f.write_fmt(format_args!("{0}{1}", value, path))
}
Expr::AtTimeZone { timestamp, time_zone } => {
f.write_fmt(format_args!("{0} AT TIME ZONE {1}", timestamp,
time_zone))
}
Expr::Interval(interval) => {
f.write_fmt(format_args!("{0}", interval))
}
Expr::MatchAgainst {
columns, match_value: match_expr, opt_search_modifier } => {
f.write_fmt(format_args!("MATCH ({0}) AGAINST ",
display_comma_separated(columns)))?;
if let Some(search_modifier) = opt_search_modifier {
f.write_fmt(format_args!("({0} {1})", match_expr,
search_modifier))?;
} else { f.write_fmt(format_args!("({0})", match_expr))?; }
Ok(())
}
Expr::OuterJoin(expr) => {
f.write_fmt(format_args!("{0} (+)", expr))
}
Expr::Prior(expr) =>
f.write_fmt(format_args!("PRIOR {0}", expr)),
Expr::Lambda(lambda) =>
f.write_fmt(format_args!("{0}", lambda)),
Expr::MemberOf(member_of) =>
f.write_fmt(format_args!("{0}", member_of)),
}
}
})
}recursive::recursive)]
1644 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
1645 match self {
1646 Expr::Identifier(s) => write!(f, "{s}"),
1647 Expr::Wildcard(_) => f.write_str("*"),
1648 Expr::QualifiedWildcard(prefix, _) => write!(f, "{prefix}.*"),
1649 Expr::CompoundIdentifier(s) => write!(f, "{}", display_separated(s, ".")),
1650 Expr::CompoundFieldAccess { root, access_chain } => {
1651 write!(f, "{root}")?;
1652 for field in access_chain {
1653 write!(f, "{field}")?;
1654 }
1655 Ok(())
1656 }
1657 Expr::IsTrue(ast) => write!(f, "{ast} IS TRUE"),
1658 Expr::IsNotTrue(ast) => write!(f, "{ast} IS NOT TRUE"),
1659 Expr::IsFalse(ast) => write!(f, "{ast} IS FALSE"),
1660 Expr::IsNotFalse(ast) => write!(f, "{ast} IS NOT FALSE"),
1661 Expr::IsNull(ast) => write!(f, "{ast} IS NULL"),
1662 Expr::IsNotNull(ast) => write!(f, "{ast} IS NOT NULL"),
1663 Expr::IsUnknown(ast) => write!(f, "{ast} IS UNKNOWN"),
1664 Expr::IsNotUnknown(ast) => write!(f, "{ast} IS NOT UNKNOWN"),
1665 Expr::InList {
1666 expr,
1667 list,
1668 negated,
1669 } => write!(
1670 f,
1671 "{} {}IN ({})",
1672 expr,
1673 if *negated { "NOT " } else { "" },
1674 display_comma_separated(list)
1675 ),
1676 Expr::InSubquery {
1677 expr,
1678 subquery,
1679 negated,
1680 } => write!(
1681 f,
1682 "{} {}IN ({})",
1683 expr,
1684 if *negated { "NOT " } else { "" },
1685 subquery
1686 ),
1687 Expr::InUnnest {
1688 expr,
1689 array_expr,
1690 negated,
1691 } => write!(
1692 f,
1693 "{} {}IN UNNEST({})",
1694 expr,
1695 if *negated { "NOT " } else { "" },
1696 array_expr
1697 ),
1698 Expr::Between {
1699 expr,
1700 negated,
1701 low,
1702 high,
1703 } => write!(
1704 f,
1705 "{} {}BETWEEN {} AND {}",
1706 expr,
1707 if *negated { "NOT " } else { "" },
1708 low,
1709 high
1710 ),
1711 Expr::BinaryOp { left, op, right } => write!(f, "{left} {op} {right}"),
1712 Expr::Like {
1713 negated,
1714 expr,
1715 pattern,
1716 escape_char,
1717 any,
1718 } => match escape_char {
1719 Some(ch) => write!(
1720 f,
1721 "{} {}LIKE {}{} ESCAPE {}",
1722 expr,
1723 if *negated { "NOT " } else { "" },
1724 if *any { "ANY " } else { "" },
1725 pattern,
1726 ch
1727 ),
1728 _ => write!(
1729 f,
1730 "{} {}LIKE {}{}",
1731 expr,
1732 if *negated { "NOT " } else { "" },
1733 if *any { "ANY " } else { "" },
1734 pattern
1735 ),
1736 },
1737 Expr::ILike {
1738 negated,
1739 expr,
1740 pattern,
1741 escape_char,
1742 any,
1743 } => match escape_char {
1744 Some(ch) => write!(
1745 f,
1746 "{} {}ILIKE {}{} ESCAPE {}",
1747 expr,
1748 if *negated { "NOT " } else { "" },
1749 if *any { "ANY" } else { "" },
1750 pattern,
1751 ch
1752 ),
1753 _ => write!(
1754 f,
1755 "{} {}ILIKE {}{}",
1756 expr,
1757 if *negated { "NOT " } else { "" },
1758 if *any { "ANY " } else { "" },
1759 pattern
1760 ),
1761 },
1762 Expr::RLike {
1763 negated,
1764 expr,
1765 pattern,
1766 regexp,
1767 } => write!(
1768 f,
1769 "{} {}{} {}",
1770 expr,
1771 if *negated { "NOT " } else { "" },
1772 if *regexp { "REGEXP" } else { "RLIKE" },
1773 pattern
1774 ),
1775 Expr::IsNormalized {
1776 expr,
1777 form,
1778 negated,
1779 } => {
1780 let not_ = if *negated { "NOT " } else { "" };
1781 if form.is_none() {
1782 write!(f, "{expr} IS {not_}NORMALIZED")
1783 } else {
1784 write!(
1785 f,
1786 "{} IS {}{} NORMALIZED",
1787 expr,
1788 not_,
1789 form.as_ref().unwrap()
1790 )
1791 }
1792 }
1793 Expr::SimilarTo {
1794 negated,
1795 expr,
1796 pattern,
1797 escape_char,
1798 } => match escape_char {
1799 Some(ch) => write!(
1800 f,
1801 "{} {}SIMILAR TO {} ESCAPE {}",
1802 expr,
1803 if *negated { "NOT " } else { "" },
1804 pattern,
1805 ch
1806 ),
1807 _ => write!(
1808 f,
1809 "{} {}SIMILAR TO {}",
1810 expr,
1811 if *negated { "NOT " } else { "" },
1812 pattern
1813 ),
1814 },
1815 Expr::AnyOp {
1816 left,
1817 compare_op,
1818 right,
1819 is_some,
1820 } => {
1821 let add_parens = !matches!(right.as_ref(), Expr::Subquery(_));
1822 write!(
1823 f,
1824 "{left} {compare_op} {}{}{right}{}",
1825 if *is_some { "SOME" } else { "ANY" },
1826 if add_parens { "(" } else { "" },
1827 if add_parens { ")" } else { "" },
1828 )
1829 }
1830 Expr::AllOp {
1831 left,
1832 compare_op,
1833 right,
1834 } => {
1835 let add_parens = !matches!(right.as_ref(), Expr::Subquery(_));
1836 write!(
1837 f,
1838 "{left} {compare_op} ALL{}{right}{}",
1839 if add_parens { "(" } else { "" },
1840 if add_parens { ")" } else { "" },
1841 )
1842 }
1843 Expr::UnaryOp { op, expr } => {
1844 if op == &UnaryOperator::PGPostfixFactorial {
1845 write!(f, "{expr}{op}")
1846 } else if matches!(
1847 op,
1848 UnaryOperator::Not
1849 | UnaryOperator::Hash
1850 | UnaryOperator::AtDashAt
1851 | UnaryOperator::DoubleAt
1852 | UnaryOperator::QuestionDash
1853 | UnaryOperator::QuestionPipe
1854 ) {
1855 write!(f, "{op} {expr}")
1856 } else {
1857 write!(f, "{op}{expr}")
1858 }
1859 }
1860 Expr::Convert {
1861 is_try,
1862 expr,
1863 target_before_value,
1864 data_type,
1865 charset,
1866 styles,
1867 } => {
1868 write!(f, "{}CONVERT(", if *is_try { "TRY_" } else { "" })?;
1869 if let Some(data_type) = data_type {
1870 if let Some(charset) = charset {
1871 write!(f, "{expr}, {data_type} CHARACTER SET {charset}")
1872 } else if *target_before_value {
1873 write!(f, "{data_type}, {expr}")
1874 } else {
1875 write!(f, "{expr}, {data_type}")
1876 }
1877 } else if let Some(charset) = charset {
1878 write!(f, "{expr} USING {charset}")
1879 } else {
1880 write!(f, "{expr}") }?;
1882 if !styles.is_empty() {
1883 write!(f, ", {}", display_comma_separated(styles))?;
1884 }
1885 write!(f, ")")
1886 }
1887 Expr::Cast {
1888 kind,
1889 expr,
1890 data_type,
1891 array,
1892 format,
1893 } => match kind {
1894 CastKind::Cast => {
1895 write!(f, "CAST({expr} AS {data_type}")?;
1896 if *array {
1897 write!(f, " ARRAY")?;
1898 }
1899 if let Some(format) = format {
1900 write!(f, " FORMAT {format}")?;
1901 }
1902 write!(f, ")")
1903 }
1904 CastKind::TryCast => {
1905 if let Some(format) = format {
1906 write!(f, "TRY_CAST({expr} AS {data_type} FORMAT {format})")
1907 } else {
1908 write!(f, "TRY_CAST({expr} AS {data_type})")
1909 }
1910 }
1911 CastKind::SafeCast => {
1912 if let Some(format) = format {
1913 write!(f, "SAFE_CAST({expr} AS {data_type} FORMAT {format})")
1914 } else {
1915 write!(f, "SAFE_CAST({expr} AS {data_type})")
1916 }
1917 }
1918 CastKind::DoubleColon => {
1919 write!(f, "{expr}::{data_type}")
1920 }
1921 },
1922 Expr::Extract {
1923 field,
1924 syntax,
1925 expr,
1926 } => match syntax {
1927 ExtractSyntax::From => write!(f, "EXTRACT({field} FROM {expr})"),
1928 ExtractSyntax::Comma => write!(f, "EXTRACT({field}, {expr})"),
1929 },
1930 Expr::Ceil { expr, field } => match field {
1931 CeilFloorKind::DateTimeField(DateTimeField::NoDateTime) => {
1932 write!(f, "CEIL({expr})")
1933 }
1934 CeilFloorKind::DateTimeField(dt_field) => write!(f, "CEIL({expr} TO {dt_field})"),
1935 CeilFloorKind::Scale(s) => write!(f, "CEIL({expr}, {s})"),
1936 },
1937 Expr::Floor { expr, field } => match field {
1938 CeilFloorKind::DateTimeField(DateTimeField::NoDateTime) => {
1939 write!(f, "FLOOR({expr})")
1940 }
1941 CeilFloorKind::DateTimeField(dt_field) => write!(f, "FLOOR({expr} TO {dt_field})"),
1942 CeilFloorKind::Scale(s) => write!(f, "FLOOR({expr}, {s})"),
1943 },
1944 Expr::Position { expr, r#in } => write!(f, "POSITION({expr} IN {in})"),
1945 Expr::Collate { expr, collation } => write!(f, "{expr} COLLATE {collation}"),
1946 Expr::Nested(ast) => write!(f, "({ast})"),
1947 Expr::Value(v) => write!(f, "{v}"),
1948 Expr::Prefixed { prefix, value } => write!(f, "{prefix} {value}"),
1949 Expr::TypedString(ts) => ts.fmt(f),
1950 Expr::Function(fun) => fun.fmt(f),
1951 Expr::Case {
1952 case_token: _,
1953 end_token: _,
1954 operand,
1955 conditions,
1956 else_result,
1957 } => {
1958 f.write_str("CASE")?;
1959 if let Some(operand) = operand {
1960 f.write_str(" ")?;
1961 operand.fmt(f)?;
1962 }
1963 for when in conditions {
1964 SpaceOrNewline.fmt(f)?;
1965 Indent(when).fmt(f)?;
1966 }
1967 if let Some(else_result) = else_result {
1968 SpaceOrNewline.fmt(f)?;
1969 Indent("ELSE").fmt(f)?;
1970 SpaceOrNewline.fmt(f)?;
1971 Indent(Indent(else_result)).fmt(f)?;
1972 }
1973 SpaceOrNewline.fmt(f)?;
1974 f.write_str("END")
1975 }
1976 Expr::Exists { subquery, negated } => write!(
1977 f,
1978 "{}EXISTS ({})",
1979 if *negated { "NOT " } else { "" },
1980 subquery
1981 ),
1982 Expr::Subquery(s) => write!(f, "({s})"),
1983 Expr::GroupingSets(sets) => {
1984 write!(f, "GROUPING SETS (")?;
1985 let mut sep = "";
1986 for set in sets {
1987 write!(f, "{sep}")?;
1988 sep = ", ";
1989 write!(f, "({})", display_comma_separated(set))?;
1990 }
1991 write!(f, ")")
1992 }
1993 Expr::Cube(sets) => {
1994 write!(f, "CUBE (")?;
1995 let mut sep = "";
1996 for set in sets {
1997 write!(f, "{sep}")?;
1998 sep = ", ";
1999 if set.len() == 1 {
2000 write!(f, "{}", set[0])?;
2001 } else {
2002 write!(f, "({})", display_comma_separated(set))?;
2003 }
2004 }
2005 write!(f, ")")
2006 }
2007 Expr::Rollup(sets) => {
2008 write!(f, "ROLLUP (")?;
2009 let mut sep = "";
2010 for set in sets {
2011 write!(f, "{sep}")?;
2012 sep = ", ";
2013 if set.len() == 1 {
2014 write!(f, "{}", set[0])?;
2015 } else {
2016 write!(f, "({})", display_comma_separated(set))?;
2017 }
2018 }
2019 write!(f, ")")
2020 }
2021 Expr::Substring {
2022 expr,
2023 substring_from,
2024 substring_for,
2025 special,
2026 shorthand,
2027 } => {
2028 f.write_str("SUBSTR")?;
2029 if !*shorthand {
2030 f.write_str("ING")?;
2031 }
2032 write!(f, "({expr}")?;
2033 if let Some(from_part) = substring_from {
2034 if *special {
2035 write!(f, ", {from_part}")?;
2036 } else {
2037 write!(f, " FROM {from_part}")?;
2038 }
2039 }
2040 if let Some(for_part) = substring_for {
2041 if *special {
2042 write!(f, ", {for_part}")?;
2043 } else {
2044 write!(f, " FOR {for_part}")?;
2045 }
2046 }
2047
2048 write!(f, ")")
2049 }
2050 Expr::Overlay {
2051 expr,
2052 overlay_what,
2053 overlay_from,
2054 overlay_for,
2055 } => {
2056 write!(
2057 f,
2058 "OVERLAY({expr} PLACING {overlay_what} FROM {overlay_from}"
2059 )?;
2060 if let Some(for_part) = overlay_for {
2061 write!(f, " FOR {for_part}")?;
2062 }
2063
2064 write!(f, ")")
2065 }
2066 Expr::IsDistinctFrom(a, b) => write!(f, "{a} IS DISTINCT FROM {b}"),
2067 Expr::IsNotDistinctFrom(a, b) => write!(f, "{a} IS NOT DISTINCT FROM {b}"),
2068 Expr::Trim {
2069 expr,
2070 trim_where,
2071 trim_what,
2072 trim_characters,
2073 } => {
2074 write!(f, "TRIM(")?;
2075 if let Some(ident) = trim_where {
2076 write!(f, "{ident} ")?;
2077 }
2078 if let Some(trim_char) = trim_what {
2079 write!(f, "{trim_char} FROM {expr}")?;
2080 } else {
2081 write!(f, "{expr}")?;
2082 }
2083 if let Some(characters) = trim_characters {
2084 write!(f, ", {}", display_comma_separated(characters))?;
2085 }
2086
2087 write!(f, ")")
2088 }
2089 Expr::Tuple(exprs) => {
2090 write!(f, "({})", display_comma_separated(exprs))
2091 }
2092 Expr::Struct { values, fields } => {
2093 if !fields.is_empty() {
2094 write!(
2095 f,
2096 "STRUCT<{}>({})",
2097 display_comma_separated(fields),
2098 display_comma_separated(values)
2099 )
2100 } else {
2101 write!(f, "STRUCT({})", display_comma_separated(values))
2102 }
2103 }
2104 Expr::Named { expr, name } => {
2105 write!(f, "{expr} AS {name}")
2106 }
2107 Expr::Dictionary(fields) => {
2108 write!(f, "{{{}}}", display_comma_separated(fields))
2109 }
2110 Expr::Map(map) => {
2111 write!(f, "{map}")
2112 }
2113 Expr::Array(set) => {
2114 write!(f, "{set}")
2115 }
2116 Expr::JsonAccess { value, path } => {
2117 write!(f, "{value}{path}")
2118 }
2119 Expr::AtTimeZone {
2120 timestamp,
2121 time_zone,
2122 } => {
2123 write!(f, "{timestamp} AT TIME ZONE {time_zone}")
2124 }
2125 Expr::Interval(interval) => {
2126 write!(f, "{interval}")
2127 }
2128 Expr::MatchAgainst {
2129 columns,
2130 match_value: match_expr,
2131 opt_search_modifier,
2132 } => {
2133 write!(f, "MATCH ({}) AGAINST ", display_comma_separated(columns),)?;
2134
2135 if let Some(search_modifier) = opt_search_modifier {
2136 write!(f, "({match_expr} {search_modifier})")?;
2137 } else {
2138 write!(f, "({match_expr})")?;
2139 }
2140
2141 Ok(())
2142 }
2143 Expr::OuterJoin(expr) => {
2144 write!(f, "{expr} (+)")
2145 }
2146 Expr::Prior(expr) => write!(f, "PRIOR {expr}"),
2147 Expr::Lambda(lambda) => write!(f, "{lambda}"),
2148 Expr::MemberOf(member_of) => write!(f, "{member_of}"),
2149 }
2150 }
2151}
2152
2153#[derive(#[automatically_derived]
impl ::core::fmt::Debug for WindowType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
WindowType::WindowSpec(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"WindowSpec", &__self_0),
WindowType::NamedWindow(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"NamedWindow", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for WindowType {
#[inline]
fn clone(&self) -> WindowType {
match self {
WindowType::WindowSpec(__self_0) =>
WindowType::WindowSpec(::core::clone::Clone::clone(__self_0)),
WindowType::NamedWindow(__self_0) =>
WindowType::NamedWindow(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for WindowType {
#[inline]
fn eq(&self, other: &WindowType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(WindowType::WindowSpec(__self_0),
WindowType::WindowSpec(__arg1_0)) => __self_0 == __arg1_0,
(WindowType::NamedWindow(__self_0),
WindowType::NamedWindow(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for WindowType {
#[inline]
fn partial_cmp(&self, other: &WindowType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for WindowType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<WindowSpec>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for WindowType {
#[inline]
fn cmp(&self, other: &WindowType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(WindowType::WindowSpec(__self_0),
WindowType::WindowSpec(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(WindowType::NamedWindow(__self_0),
WindowType::NamedWindow(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for WindowType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
WindowType::WindowSpec(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
WindowType::NamedWindow(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
2162#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2163#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for WindowType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::WindowSpec(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::NamedWindow(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for WindowType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::WindowSpec(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::NamedWindow(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2164pub enum WindowType {
2165 WindowSpec(WindowSpec),
2167 NamedWindow(Ident),
2169}
2170
2171impl Display for WindowType {
2172 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2173 match self {
2174 WindowType::WindowSpec(spec) => {
2175 f.write_str("(")?;
2176 NewLine.fmt(f)?;
2177 Indent(spec).fmt(f)?;
2178 NewLine.fmt(f)?;
2179 f.write_str(")")
2180 }
2181 WindowType::NamedWindow(name) => name.fmt(f),
2182 }
2183 }
2184}
2185
2186#[derive(#[automatically_derived]
impl ::core::fmt::Debug for WindowSpec {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field4_finish(f, "WindowSpec",
"window_name", &self.window_name, "partition_by",
&self.partition_by, "order_by", &self.order_by, "window_frame",
&&self.window_frame)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for WindowSpec {
#[inline]
fn clone(&self) -> WindowSpec {
WindowSpec {
window_name: ::core::clone::Clone::clone(&self.window_name),
partition_by: ::core::clone::Clone::clone(&self.partition_by),
order_by: ::core::clone::Clone::clone(&self.order_by),
window_frame: ::core::clone::Clone::clone(&self.window_frame),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for WindowSpec {
#[inline]
fn eq(&self, other: &WindowSpec) -> bool {
self.window_name == other.window_name &&
self.partition_by == other.partition_by &&
self.order_by == other.order_by &&
self.window_frame == other.window_frame
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for WindowSpec {
#[inline]
fn partial_cmp(&self, other: &WindowSpec)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for WindowSpec {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<OrderByExpr>>;
let _: ::core::cmp::AssertParamIsEq<Option<WindowFrame>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for WindowSpec {
#[inline]
fn cmp(&self, other: &WindowSpec) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.window_name, &other.window_name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.partition_by,
&other.partition_by) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.order_by, &other.order_by)
{
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.window_frame,
&other.window_frame),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for WindowSpec {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.window_name, state);
::core::hash::Hash::hash(&self.partition_by, state);
::core::hash::Hash::hash(&self.order_by, state);
::core::hash::Hash::hash(&self.window_frame, state)
}
}Hash)]
2188#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2189#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for WindowSpec {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.window_name, visitor)?;
sqlparser::ast::Visit::visit(&self.partition_by, visitor)?;
sqlparser::ast::Visit::visit(&self.order_by, visitor)?;
sqlparser::ast::Visit::visit(&self.window_frame, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for WindowSpec {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.window_name,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.partition_by,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.order_by,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.window_frame,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2190pub struct WindowSpec {
2191 pub window_name: Option<Ident>,
2199 pub partition_by: Vec<Expr>,
2201 pub order_by: Vec<OrderByExpr>,
2203 pub window_frame: Option<WindowFrame>,
2205}
2206
2207impl fmt::Display for WindowSpec {
2208 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2209 let mut is_first = true;
2210 if let Some(window_name) = &self.window_name {
2211 if !is_first {
2212 SpaceOrNewline.fmt(f)?;
2213 }
2214 is_first = false;
2215 f.write_fmt(format_args!("{0}", window_name))write!(f, "{window_name}")?;
2216 }
2217 if !self.partition_by.is_empty() {
2218 if !is_first {
2219 SpaceOrNewline.fmt(f)?;
2220 }
2221 is_first = false;
2222 f.write_fmt(format_args!("PARTITION BY {0}",
display_comma_separated(&self.partition_by)))write!(
2223 f,
2224 "PARTITION BY {}",
2225 display_comma_separated(&self.partition_by)
2226 )?;
2227 }
2228 if !self.order_by.is_empty() {
2229 if !is_first {
2230 SpaceOrNewline.fmt(f)?;
2231 }
2232 is_first = false;
2233 f.write_fmt(format_args!("ORDER BY {0}",
display_comma_separated(&self.order_by)))write!(f, "ORDER BY {}", display_comma_separated(&self.order_by))?;
2234 }
2235 if let Some(window_frame) = &self.window_frame {
2236 if !is_first {
2237 SpaceOrNewline.fmt(f)?;
2238 }
2239 if let Some(end_bound) = &window_frame.end_bound {
2240 f.write_fmt(format_args!("{0} BETWEEN {1} AND {2}", window_frame.units,
window_frame.start_bound, end_bound))write!(
2241 f,
2242 "{} BETWEEN {} AND {}",
2243 window_frame.units, window_frame.start_bound, end_bound
2244 )?;
2245 } else {
2246 f.write_fmt(format_args!("{0} {1}", window_frame.units,
window_frame.start_bound))write!(f, "{} {}", window_frame.units, window_frame.start_bound)?;
2247 }
2248 }
2249 Ok(())
2250 }
2251}
2252
2253#[derive(#[automatically_derived]
impl ::core::fmt::Debug for WindowFrame {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "WindowFrame",
"units", &self.units, "start_bound", &self.start_bound,
"end_bound", &&self.end_bound)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for WindowFrame {
#[inline]
fn clone(&self) -> WindowFrame {
WindowFrame {
units: ::core::clone::Clone::clone(&self.units),
start_bound: ::core::clone::Clone::clone(&self.start_bound),
end_bound: ::core::clone::Clone::clone(&self.end_bound),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for WindowFrame {
#[inline]
fn eq(&self, other: &WindowFrame) -> bool {
self.units == other.units && self.start_bound == other.start_bound &&
self.end_bound == other.end_bound
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for WindowFrame {
#[inline]
fn partial_cmp(&self, other: &WindowFrame)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for WindowFrame {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<WindowFrameUnits>;
let _: ::core::cmp::AssertParamIsEq<WindowFrameBound>;
let _: ::core::cmp::AssertParamIsEq<Option<WindowFrameBound>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for WindowFrame {
#[inline]
fn cmp(&self, other: &WindowFrame) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.units, &other.units) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.start_bound,
&other.start_bound) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.end_bound, &other.end_bound),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for WindowFrame {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.units, state);
::core::hash::Hash::hash(&self.start_bound, state);
::core::hash::Hash::hash(&self.end_bound, state)
}
}Hash)]
2259#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2260#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for WindowFrame {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.units, visitor)?;
sqlparser::ast::Visit::visit(&self.start_bound, visitor)?;
sqlparser::ast::Visit::visit(&self.end_bound, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for WindowFrame {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.units, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.start_bound,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.end_bound,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2261pub struct WindowFrame {
2262 pub units: WindowFrameUnits,
2264 pub start_bound: WindowFrameBound,
2266 pub end_bound: Option<WindowFrameBound>,
2270 }
2272
2273impl Default for WindowFrame {
2274 fn default() -> Self {
2278 Self {
2279 units: WindowFrameUnits::Range,
2280 start_bound: WindowFrameBound::Preceding(None),
2281 end_bound: None,
2282 }
2283 }
2284}
2285
2286#[derive(#[automatically_derived]
impl ::core::fmt::Debug for WindowFrameUnits {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
WindowFrameUnits::Rows => "Rows",
WindowFrameUnits::Range => "Range",
WindowFrameUnits::Groups => "Groups",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for WindowFrameUnits { }Copy, #[automatically_derived]
impl ::core::clone::Clone for WindowFrameUnits {
#[inline]
fn clone(&self) -> WindowFrameUnits { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for WindowFrameUnits {
#[inline]
fn eq(&self, other: &WindowFrameUnits) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for WindowFrameUnits {
#[inline]
fn partial_cmp(&self, other: &WindowFrameUnits)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for WindowFrameUnits {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for WindowFrameUnits {
#[inline]
fn cmp(&self, other: &WindowFrameUnits) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for WindowFrameUnits {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
2287#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2288#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for WindowFrameUnits {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Rows => {}
Self::Range => {}
Self::Groups => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for WindowFrameUnits {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Rows => {}
Self::Range => {}
Self::Groups => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2289pub enum WindowFrameUnits {
2291 Rows,
2293 Range,
2295 Groups,
2297}
2298
2299impl fmt::Display for WindowFrameUnits {
2300 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2301 f.write_str(match self {
2302 WindowFrameUnits::Rows => "ROWS",
2303 WindowFrameUnits::Range => "RANGE",
2304 WindowFrameUnits::Groups => "GROUPS",
2305 })
2306 }
2307}
2308
2309#[derive(#[automatically_derived]
impl ::core::fmt::Debug for NullTreatment {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
NullTreatment::IgnoreNulls => "IgnoreNulls",
NullTreatment::RespectNulls => "RespectNulls",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for NullTreatment { }Copy, #[automatically_derived]
impl ::core::clone::Clone for NullTreatment {
#[inline]
fn clone(&self) -> NullTreatment { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for NullTreatment {
#[inline]
fn eq(&self, other: &NullTreatment) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for NullTreatment {
#[inline]
fn partial_cmp(&self, other: &NullTreatment)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for NullTreatment {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for NullTreatment {
#[inline]
fn cmp(&self, other: &NullTreatment) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for NullTreatment {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
2313#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2314#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for NullTreatment {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IgnoreNulls => {}
Self::RespectNulls => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for NullTreatment {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IgnoreNulls => {}
Self::RespectNulls => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2315pub enum NullTreatment {
2317 IgnoreNulls,
2319 RespectNulls,
2321}
2322
2323impl fmt::Display for NullTreatment {
2324 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2325 f.write_str(match self {
2326 NullTreatment::IgnoreNulls => "IGNORE NULLS",
2327 NullTreatment::RespectNulls => "RESPECT NULLS",
2328 })
2329 }
2330}
2331
2332#[derive(#[automatically_derived]
impl ::core::fmt::Debug for WindowFrameBound {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
WindowFrameBound::CurrentRow =>
::core::fmt::Formatter::write_str(f, "CurrentRow"),
WindowFrameBound::Preceding(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Preceding", &__self_0),
WindowFrameBound::Following(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Following", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for WindowFrameBound {
#[inline]
fn clone(&self) -> WindowFrameBound {
match self {
WindowFrameBound::CurrentRow => WindowFrameBound::CurrentRow,
WindowFrameBound::Preceding(__self_0) =>
WindowFrameBound::Preceding(::core::clone::Clone::clone(__self_0)),
WindowFrameBound::Following(__self_0) =>
WindowFrameBound::Following(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for WindowFrameBound {
#[inline]
fn eq(&self, other: &WindowFrameBound) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(WindowFrameBound::Preceding(__self_0),
WindowFrameBound::Preceding(__arg1_0)) =>
__self_0 == __arg1_0,
(WindowFrameBound::Following(__self_0),
WindowFrameBound::Following(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for WindowFrameBound {
#[inline]
fn partial_cmp(&self, other: &WindowFrameBound)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for WindowFrameBound {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for WindowFrameBound {
#[inline]
fn cmp(&self, other: &WindowFrameBound) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(WindowFrameBound::Preceding(__self_0),
WindowFrameBound::Preceding(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(WindowFrameBound::Following(__self_0),
WindowFrameBound::Following(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for WindowFrameBound {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
WindowFrameBound::Preceding(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
WindowFrameBound::Following(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
2334#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2335#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for WindowFrameBound {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::CurrentRow => {}
Self::Preceding(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Following(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for WindowFrameBound {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::CurrentRow => {}
Self::Preceding(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Following(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2336pub enum WindowFrameBound {
2337 CurrentRow,
2339 Preceding(Option<Box<Expr>>),
2341 Following(Option<Box<Expr>>),
2343}
2344
2345impl fmt::Display for WindowFrameBound {
2346 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2347 match self {
2348 WindowFrameBound::CurrentRow => f.write_str("CURRENT ROW"),
2349 WindowFrameBound::Preceding(None) => f.write_str("UNBOUNDED PRECEDING"),
2350 WindowFrameBound::Following(None) => f.write_str("UNBOUNDED FOLLOWING"),
2351 WindowFrameBound::Preceding(Some(n)) => f.write_fmt(format_args!("{0} PRECEDING", n))write!(f, "{n} PRECEDING"),
2352 WindowFrameBound::Following(Some(n)) => f.write_fmt(format_args!("{0} FOLLOWING", n))write!(f, "{n} FOLLOWING"),
2353 }
2354 }
2355}
2356
2357#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AddDropSync {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
AddDropSync::ADD => "ADD",
AddDropSync::DROP => "DROP",
AddDropSync::SYNC => "SYNC",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for AddDropSync { }Copy, #[automatically_derived]
impl ::core::clone::Clone for AddDropSync {
#[inline]
fn clone(&self) -> AddDropSync { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AddDropSync {
#[inline]
fn eq(&self, other: &AddDropSync) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AddDropSync {
#[inline]
fn partial_cmp(&self, other: &AddDropSync)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AddDropSync {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AddDropSync {
#[inline]
fn cmp(&self, other: &AddDropSync) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AddDropSync {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
2358#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2359#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AddDropSync {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ADD => {}
Self::DROP => {}
Self::SYNC => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AddDropSync {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ADD => {}
Self::DROP => {}
Self::SYNC => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2360pub enum AddDropSync {
2362 ADD,
2364 DROP,
2366 SYNC,
2368}
2369
2370impl fmt::Display for AddDropSync {
2371 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2372 match self {
2373 AddDropSync::SYNC => f.write_str("SYNC PARTITIONS"),
2374 AddDropSync::DROP => f.write_str("DROP PARTITIONS"),
2375 AddDropSync::ADD => f.write_str("ADD PARTITIONS"),
2376 }
2377 }
2378}
2379
2380#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowCreateObject {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ShowCreateObject::Event => "Event",
ShowCreateObject::Function => "Function",
ShowCreateObject::Procedure => "Procedure",
ShowCreateObject::Table => "Table",
ShowCreateObject::Trigger => "Trigger",
ShowCreateObject::View => "View",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for ShowCreateObject { }Copy, #[automatically_derived]
impl ::core::clone::Clone for ShowCreateObject {
#[inline]
fn clone(&self) -> ShowCreateObject { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowCreateObject {
#[inline]
fn eq(&self, other: &ShowCreateObject) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowCreateObject {
#[inline]
fn partial_cmp(&self, other: &ShowCreateObject)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowCreateObject {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowCreateObject {
#[inline]
fn cmp(&self, other: &ShowCreateObject) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowCreateObject {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
2381#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2382#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowCreateObject {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Event => {}
Self::Function => {}
Self::Procedure => {}
Self::Table => {}
Self::Trigger => {}
Self::View => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowCreateObject {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Event => {}
Self::Function => {}
Self::Procedure => {}
Self::Table => {}
Self::Trigger => {}
Self::View => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2383pub enum ShowCreateObject {
2385 Event,
2387 Function,
2389 Procedure,
2391 Table,
2393 Trigger,
2395 View,
2397}
2398
2399impl fmt::Display for ShowCreateObject {
2400 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2401 match self {
2402 ShowCreateObject::Event => f.write_str("EVENT"),
2403 ShowCreateObject::Function => f.write_str("FUNCTION"),
2404 ShowCreateObject::Procedure => f.write_str("PROCEDURE"),
2405 ShowCreateObject::Table => f.write_str("TABLE"),
2406 ShowCreateObject::Trigger => f.write_str("TRIGGER"),
2407 ShowCreateObject::View => f.write_str("VIEW"),
2408 }
2409 }
2410}
2411
2412#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CommentObject {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CommentObject::Column => "Column",
CommentObject::Table => "Table",
CommentObject::Extension => "Extension",
CommentObject::Schema => "Schema",
CommentObject::Database => "Database",
CommentObject::User => "User",
CommentObject::Role => "Role",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for CommentObject { }Copy, #[automatically_derived]
impl ::core::clone::Clone for CommentObject {
#[inline]
fn clone(&self) -> CommentObject { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CommentObject {
#[inline]
fn eq(&self, other: &CommentObject) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CommentObject {
#[inline]
fn partial_cmp(&self, other: &CommentObject)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CommentObject {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CommentObject {
#[inline]
fn cmp(&self, other: &CommentObject) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CommentObject {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
2413#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2414#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CommentObject {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Column => {}
Self::Table => {}
Self::Extension => {}
Self::Schema => {}
Self::Database => {}
Self::User => {}
Self::Role => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CommentObject {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Column => {}
Self::Table => {}
Self::Extension => {}
Self::Schema => {}
Self::Database => {}
Self::User => {}
Self::Role => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2415pub enum CommentObject {
2417 Column,
2419 Table,
2421 Extension,
2423 Schema,
2425 Database,
2427 User,
2429 Role,
2431}
2432
2433impl fmt::Display for CommentObject {
2434 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2435 match self {
2436 CommentObject::Column => f.write_str("COLUMN"),
2437 CommentObject::Table => f.write_str("TABLE"),
2438 CommentObject::Extension => f.write_str("EXTENSION"),
2439 CommentObject::Schema => f.write_str("SCHEMA"),
2440 CommentObject::Database => f.write_str("DATABASE"),
2441 CommentObject::User => f.write_str("USER"),
2442 CommentObject::Role => f.write_str("ROLE"),
2443 }
2444 }
2445}
2446
2447#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Password {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Password::Password(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Password", &__self_0),
Password::NullPassword =>
::core::fmt::Formatter::write_str(f, "NullPassword"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Password {
#[inline]
fn clone(&self) -> Password {
match self {
Password::Password(__self_0) =>
Password::Password(::core::clone::Clone::clone(__self_0)),
Password::NullPassword => Password::NullPassword,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Password {
#[inline]
fn eq(&self, other: &Password) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Password::Password(__self_0), Password::Password(__arg1_0))
=> __self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Password {
#[inline]
fn partial_cmp(&self, other: &Password)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Password {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Password {
#[inline]
fn cmp(&self, other: &Password) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Password::Password(__self_0), Password::Password(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Password {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Password::Password(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
2448#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2449#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Password {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Password(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::NullPassword => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Password {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Password(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::NullPassword => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2450pub enum Password {
2452 Password(Expr),
2454 NullPassword,
2456}
2457
2458#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CaseStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field5_finish(f, "CaseStatement",
"case_token", &self.case_token, "match_expr", &self.match_expr,
"when_blocks", &self.when_blocks, "else_block", &self.else_block,
"end_case_token", &&self.end_case_token)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CaseStatement {
#[inline]
fn clone(&self) -> CaseStatement {
CaseStatement {
case_token: ::core::clone::Clone::clone(&self.case_token),
match_expr: ::core::clone::Clone::clone(&self.match_expr),
when_blocks: ::core::clone::Clone::clone(&self.when_blocks),
else_block: ::core::clone::Clone::clone(&self.else_block),
end_case_token: ::core::clone::Clone::clone(&self.end_case_token),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CaseStatement {
#[inline]
fn eq(&self, other: &CaseStatement) -> bool {
self.case_token == other.case_token &&
self.match_expr == other.match_expr &&
self.when_blocks == other.when_blocks &&
self.else_block == other.else_block &&
self.end_case_token == other.end_case_token
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CaseStatement {
#[inline]
fn partial_cmp(&self, other: &CaseStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CaseStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<AttachedToken>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ConditionalStatementBlock>>;
let _:
::core::cmp::AssertParamIsEq<Option<ConditionalStatementBlock>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CaseStatement {
#[inline]
fn cmp(&self, other: &CaseStatement) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.case_token, &other.case_token) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.match_expr,
&other.match_expr) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.when_blocks,
&other.when_blocks) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.else_block,
&other.else_block) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.end_case_token,
&other.end_case_token),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CaseStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.case_token, state);
::core::hash::Hash::hash(&self.match_expr, state);
::core::hash::Hash::hash(&self.when_blocks, state);
::core::hash::Hash::hash(&self.else_block, state);
::core::hash::Hash::hash(&self.end_case_token, state)
}
}Hash)]
2475#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2476#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CaseStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.case_token, visitor)?;
sqlparser::ast::Visit::visit(&self.match_expr, visitor)?;
sqlparser::ast::Visit::visit(&self.when_blocks, visitor)?;
sqlparser::ast::Visit::visit(&self.else_block, visitor)?;
sqlparser::ast::Visit::visit(&self.end_case_token,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CaseStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.case_token,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.match_expr,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.when_blocks,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.else_block,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.end_case_token,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2477pub struct CaseStatement {
2478 pub case_token: AttachedToken,
2480 pub match_expr: Option<Expr>,
2482 pub when_blocks: Vec<ConditionalStatementBlock>,
2484 pub else_block: Option<ConditionalStatementBlock>,
2486 pub end_case_token: AttachedToken,
2488}
2489
2490impl fmt::Display for CaseStatement {
2491 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2492 let CaseStatement {
2493 case_token: _,
2494 match_expr,
2495 when_blocks,
2496 else_block,
2497 end_case_token: AttachedToken(end),
2498 } = self;
2499
2500 f.write_fmt(format_args!("CASE"))write!(f, "CASE")?;
2501
2502 if let Some(expr) = match_expr {
2503 f.write_fmt(format_args!(" {0}", expr))write!(f, " {expr}")?;
2504 }
2505
2506 if !when_blocks.is_empty() {
2507 f.write_fmt(format_args!(" {0}", display_separated(when_blocks, " ")))write!(f, " {}", display_separated(when_blocks, " "))?;
2508 }
2509
2510 if let Some(else_block) = else_block {
2511 f.write_fmt(format_args!(" {0}", else_block))write!(f, " {else_block}")?;
2512 }
2513
2514 f.write_fmt(format_args!(" END"))write!(f, " END")?;
2515
2516 if let Token::Word(w) = &end.token {
2517 if w.keyword == Keyword::CASE {
2518 f.write_fmt(format_args!(" CASE"))write!(f, " CASE")?;
2519 }
2520 }
2521
2522 Ok(())
2523 }
2524}
2525
2526#[derive(#[automatically_derived]
impl ::core::fmt::Debug for IfStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field4_finish(f, "IfStatement",
"if_block", &self.if_block, "elseif_blocks", &self.elseif_blocks,
"else_block", &self.else_block, "end_token", &&self.end_token)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for IfStatement {
#[inline]
fn clone(&self) -> IfStatement {
IfStatement {
if_block: ::core::clone::Clone::clone(&self.if_block),
elseif_blocks: ::core::clone::Clone::clone(&self.elseif_blocks),
else_block: ::core::clone::Clone::clone(&self.else_block),
end_token: ::core::clone::Clone::clone(&self.end_token),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for IfStatement {
#[inline]
fn eq(&self, other: &IfStatement) -> bool {
self.if_block == other.if_block &&
self.elseif_blocks == other.elseif_blocks &&
self.else_block == other.else_block &&
self.end_token == other.end_token
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for IfStatement {
#[inline]
fn partial_cmp(&self, other: &IfStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for IfStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ConditionalStatementBlock>;
let _: ::core::cmp::AssertParamIsEq<Vec<ConditionalStatementBlock>>;
let _:
::core::cmp::AssertParamIsEq<Option<ConditionalStatementBlock>>;
let _: ::core::cmp::AssertParamIsEq<Option<AttachedToken>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for IfStatement {
#[inline]
fn cmp(&self, other: &IfStatement) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.if_block, &other.if_block) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.elseif_blocks,
&other.elseif_blocks) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.else_block,
&other.else_block) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.end_token, &other.end_token),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for IfStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.if_block, state);
::core::hash::Hash::hash(&self.elseif_blocks, state);
::core::hash::Hash::hash(&self.else_block, state);
::core::hash::Hash::hash(&self.end_token, state)
}
}Hash)]
2548#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2549#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for IfStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.if_block, visitor)?;
sqlparser::ast::Visit::visit(&self.elseif_blocks, visitor)?;
sqlparser::ast::Visit::visit(&self.else_block, visitor)?;
sqlparser::ast::Visit::visit(&self.end_token, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for IfStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.if_block,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.elseif_blocks,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.else_block,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.end_token,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2550pub struct IfStatement {
2551 pub if_block: ConditionalStatementBlock,
2553 pub elseif_blocks: Vec<ConditionalStatementBlock>,
2555 pub else_block: Option<ConditionalStatementBlock>,
2557 pub end_token: Option<AttachedToken>,
2559}
2560
2561impl fmt::Display for IfStatement {
2562 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2563 let IfStatement {
2564 if_block,
2565 elseif_blocks,
2566 else_block,
2567 end_token,
2568 } = self;
2569
2570 f.write_fmt(format_args!("{0}", if_block))write!(f, "{if_block}")?;
2571
2572 for elseif_block in elseif_blocks {
2573 f.write_fmt(format_args!(" {0}", elseif_block))write!(f, " {elseif_block}")?;
2574 }
2575
2576 if let Some(else_block) = else_block {
2577 f.write_fmt(format_args!(" {0}", else_block))write!(f, " {else_block}")?;
2578 }
2579
2580 if let Some(AttachedToken(end_token)) = end_token {
2581 f.write_fmt(format_args!(" END {0}", end_token))write!(f, " END {end_token}")?;
2582 }
2583
2584 Ok(())
2585 }
2586}
2587
2588#[derive(#[automatically_derived]
impl ::core::fmt::Debug for WhileStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"WhileStatement", "while_block", &&self.while_block)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for WhileStatement {
#[inline]
fn clone(&self) -> WhileStatement {
WhileStatement {
while_block: ::core::clone::Clone::clone(&self.while_block),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for WhileStatement {
#[inline]
fn eq(&self, other: &WhileStatement) -> bool {
self.while_block == other.while_block
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for WhileStatement {
#[inline]
fn partial_cmp(&self, other: &WhileStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for WhileStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ConditionalStatementBlock>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for WhileStatement {
#[inline]
fn cmp(&self, other: &WhileStatement) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.while_block, &other.while_block)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for WhileStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.while_block, state)
}
}Hash)]
2600#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2601#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for WhileStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.while_block, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for WhileStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.while_block,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2602pub struct WhileStatement {
2603 pub while_block: ConditionalStatementBlock,
2605}
2606
2607impl fmt::Display for WhileStatement {
2608 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2609 let WhileStatement { while_block } = self;
2610 f.write_fmt(format_args!("{0}", while_block))write!(f, "{while_block}")?;
2611 Ok(())
2612 }
2613}
2614
2615#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ConditionalStatementBlock {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field4_finish(f,
"ConditionalStatementBlock", "start_token", &self.start_token,
"condition", &self.condition, "then_token", &self.then_token,
"conditional_statements", &&self.conditional_statements)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ConditionalStatementBlock {
#[inline]
fn clone(&self) -> ConditionalStatementBlock {
ConditionalStatementBlock {
start_token: ::core::clone::Clone::clone(&self.start_token),
condition: ::core::clone::Clone::clone(&self.condition),
then_token: ::core::clone::Clone::clone(&self.then_token),
conditional_statements: ::core::clone::Clone::clone(&self.conditional_statements),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ConditionalStatementBlock {
#[inline]
fn eq(&self, other: &ConditionalStatementBlock) -> bool {
self.start_token == other.start_token &&
self.condition == other.condition &&
self.then_token == other.then_token &&
self.conditional_statements == other.conditional_statements
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ConditionalStatementBlock {
#[inline]
fn partial_cmp(&self, other: &ConditionalStatementBlock)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ConditionalStatementBlock {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<AttachedToken>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<AttachedToken>>;
let _: ::core::cmp::AssertParamIsEq<ConditionalStatements>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ConditionalStatementBlock {
#[inline]
fn cmp(&self, other: &ConditionalStatementBlock)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.start_token, &other.start_token) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.condition, &other.condition)
{
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.then_token,
&other.then_token) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.conditional_statements,
&other.conditional_statements),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ConditionalStatementBlock {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.start_token, state);
::core::hash::Hash::hash(&self.condition, state);
::core::hash::Hash::hash(&self.then_token, state);
::core::hash::Hash::hash(&self.conditional_statements, state)
}
}Hash)]
2640#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2641#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ConditionalStatementBlock {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.start_token, visitor)?;
sqlparser::ast::Visit::visit(&self.condition, visitor)?;
sqlparser::ast::Visit::visit(&self.then_token, visitor)?;
sqlparser::ast::Visit::visit(&self.conditional_statements,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ConditionalStatementBlock {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.start_token,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.condition,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.then_token,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.conditional_statements,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2642pub struct ConditionalStatementBlock {
2643 pub start_token: AttachedToken,
2645 pub condition: Option<Expr>,
2647 pub then_token: Option<AttachedToken>,
2649 pub conditional_statements: ConditionalStatements,
2651}
2652
2653impl ConditionalStatementBlock {
2654 pub fn statements(&self) -> &Vec<Statement> {
2656 self.conditional_statements.statements()
2657 }
2658}
2659
2660impl fmt::Display for ConditionalStatementBlock {
2661 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2662 let ConditionalStatementBlock {
2663 start_token: AttachedToken(start_token),
2664 condition,
2665 then_token,
2666 conditional_statements,
2667 } = self;
2668
2669 f.write_fmt(format_args!("{0}", start_token))write!(f, "{start_token}")?;
2670
2671 if let Some(condition) = condition {
2672 f.write_fmt(format_args!(" {0}", condition))write!(f, " {condition}")?;
2673 }
2674
2675 if then_token.is_some() {
2676 f.write_fmt(format_args!(" THEN"))write!(f, " THEN")?;
2677 }
2678
2679 if !conditional_statements.statements().is_empty() {
2680 f.write_fmt(format_args!(" {0}", conditional_statements))write!(f, " {conditional_statements}")?;
2681 }
2682
2683 Ok(())
2684 }
2685}
2686
2687#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ConditionalStatements {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ConditionalStatements::Sequence { statements: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Sequence", "statements", &__self_0),
ConditionalStatements::BeginEnd(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"BeginEnd", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ConditionalStatements {
#[inline]
fn clone(&self) -> ConditionalStatements {
match self {
ConditionalStatements::Sequence { statements: __self_0 } =>
ConditionalStatements::Sequence {
statements: ::core::clone::Clone::clone(__self_0),
},
ConditionalStatements::BeginEnd(__self_0) =>
ConditionalStatements::BeginEnd(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ConditionalStatements {
#[inline]
fn eq(&self, other: &ConditionalStatements) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(ConditionalStatements::Sequence { statements: __self_0 },
ConditionalStatements::Sequence { statements: __arg1_0 }) =>
__self_0 == __arg1_0,
(ConditionalStatements::BeginEnd(__self_0),
ConditionalStatements::BeginEnd(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ConditionalStatements {
#[inline]
fn partial_cmp(&self, other: &ConditionalStatements)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ConditionalStatements {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Statement>>;
let _: ::core::cmp::AssertParamIsEq<BeginEndStatements>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ConditionalStatements {
#[inline]
fn cmp(&self, other: &ConditionalStatements) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(ConditionalStatements::Sequence { statements: __self_0 },
ConditionalStatements::Sequence { statements: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ConditionalStatements::BeginEnd(__self_0),
ConditionalStatements::BeginEnd(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ConditionalStatements {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
ConditionalStatements::Sequence { statements: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
ConditionalStatements::BeginEnd(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
2689#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2690#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ConditionalStatements {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Sequence { statements } => {
sqlparser::ast::Visit::visit(statements, visitor)?;
}
Self::BeginEnd(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ConditionalStatements {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Sequence { statements } => {
sqlparser::ast::VisitMut::visit(statements, visitor)?;
}
Self::BeginEnd(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2691pub enum ConditionalStatements {
2693 Sequence {
2695 statements: Vec<Statement>,
2697 },
2698 BeginEnd(BeginEndStatements),
2700}
2701
2702impl ConditionalStatements {
2703 pub fn statements(&self) -> &Vec<Statement> {
2705 match self {
2706 ConditionalStatements::Sequence { statements } => statements,
2707 ConditionalStatements::BeginEnd(bes) => &bes.statements,
2708 }
2709 }
2710}
2711
2712impl fmt::Display for ConditionalStatements {
2713 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2714 match self {
2715 ConditionalStatements::Sequence { statements } => {
2716 if !statements.is_empty() {
2717 format_statement_list(f, statements)?;
2718 }
2719 Ok(())
2720 }
2721 ConditionalStatements::BeginEnd(bes) => f.write_fmt(format_args!("{0}", bes))write!(f, "{bes}"),
2722 }
2723 }
2724}
2725
2726#[derive(#[automatically_derived]
impl ::core::fmt::Debug for BeginEndStatements {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"BeginEndStatements", "begin_token", &self.begin_token,
"statements", &self.statements, "end_token", &&self.end_token)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for BeginEndStatements {
#[inline]
fn clone(&self) -> BeginEndStatements {
BeginEndStatements {
begin_token: ::core::clone::Clone::clone(&self.begin_token),
statements: ::core::clone::Clone::clone(&self.statements),
end_token: ::core::clone::Clone::clone(&self.end_token),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for BeginEndStatements {
#[inline]
fn eq(&self, other: &BeginEndStatements) -> bool {
self.begin_token == other.begin_token &&
self.statements == other.statements &&
self.end_token == other.end_token
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for BeginEndStatements {
#[inline]
fn partial_cmp(&self, other: &BeginEndStatements)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for BeginEndStatements {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<AttachedToken>;
let _: ::core::cmp::AssertParamIsEq<Vec<Statement>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for BeginEndStatements {
#[inline]
fn cmp(&self, other: &BeginEndStatements) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.begin_token, &other.begin_token) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.statements,
&other.statements) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.end_token, &other.end_token),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for BeginEndStatements {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.begin_token, state);
::core::hash::Hash::hash(&self.statements, state);
::core::hash::Hash::hash(&self.end_token, state)
}
}Hash)]
2735#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2736#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for BeginEndStatements {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.begin_token, visitor)?;
sqlparser::ast::Visit::visit(&self.statements, visitor)?;
sqlparser::ast::Visit::visit(&self.end_token, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for BeginEndStatements {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.begin_token,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.statements,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.end_token,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2737pub struct BeginEndStatements {
2738 pub begin_token: AttachedToken,
2740 pub statements: Vec<Statement>,
2742 pub end_token: AttachedToken,
2744}
2745
2746impl fmt::Display for BeginEndStatements {
2747 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2748 let BeginEndStatements {
2749 begin_token: AttachedToken(begin_token),
2750 statements,
2751 end_token: AttachedToken(end_token),
2752 } = self;
2753
2754 if begin_token.token != Token::EOF {
2755 f.write_fmt(format_args!("{0} ", begin_token))write!(f, "{begin_token} ")?;
2756 }
2757 if !statements.is_empty() {
2758 format_statement_list(f, statements)?;
2759 }
2760 if end_token.token != Token::EOF {
2761 f.write_fmt(format_args!(" {0}", end_token))write!(f, " {end_token}")?;
2762 }
2763 Ok(())
2764 }
2765}
2766
2767#[derive(#[automatically_derived]
impl ::core::fmt::Debug for RaiseStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"RaiseStatement", "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for RaiseStatement {
#[inline]
fn clone(&self) -> RaiseStatement {
RaiseStatement { value: ::core::clone::Clone::clone(&self.value) }
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for RaiseStatement {
#[inline]
fn eq(&self, other: &RaiseStatement) -> bool { self.value == other.value }
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for RaiseStatement {
#[inline]
fn partial_cmp(&self, other: &RaiseStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for RaiseStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<RaiseStatementValue>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for RaiseStatement {
#[inline]
fn cmp(&self, other: &RaiseStatement) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.value, &other.value)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for RaiseStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
2779#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2780#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for RaiseStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for RaiseStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2781pub struct RaiseStatement {
2782 pub value: Option<RaiseStatementValue>,
2784}
2785
2786impl fmt::Display for RaiseStatement {
2787 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2788 let RaiseStatement { value } = self;
2789
2790 f.write_fmt(format_args!("RAISE"))write!(f, "RAISE")?;
2791 if let Some(value) = value {
2792 f.write_fmt(format_args!(" {0}", value))write!(f, " {value}")?;
2793 }
2794
2795 Ok(())
2796 }
2797}
2798
2799#[derive(#[automatically_derived]
impl ::core::fmt::Debug for RaiseStatementValue {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
RaiseStatementValue::UsingMessage(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"UsingMessage", &__self_0),
RaiseStatementValue::Expr(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Expr",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for RaiseStatementValue {
#[inline]
fn clone(&self) -> RaiseStatementValue {
match self {
RaiseStatementValue::UsingMessage(__self_0) =>
RaiseStatementValue::UsingMessage(::core::clone::Clone::clone(__self_0)),
RaiseStatementValue::Expr(__self_0) =>
RaiseStatementValue::Expr(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for RaiseStatementValue {
#[inline]
fn eq(&self, other: &RaiseStatementValue) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(RaiseStatementValue::UsingMessage(__self_0),
RaiseStatementValue::UsingMessage(__arg1_0)) =>
__self_0 == __arg1_0,
(RaiseStatementValue::Expr(__self_0),
RaiseStatementValue::Expr(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for RaiseStatementValue {
#[inline]
fn partial_cmp(&self, other: &RaiseStatementValue)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for RaiseStatementValue {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for RaiseStatementValue {
#[inline]
fn cmp(&self, other: &RaiseStatementValue) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(RaiseStatementValue::UsingMessage(__self_0),
RaiseStatementValue::UsingMessage(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(RaiseStatementValue::Expr(__self_0),
RaiseStatementValue::Expr(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for RaiseStatementValue {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
RaiseStatementValue::UsingMessage(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
RaiseStatementValue::Expr(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
2801#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2802#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for RaiseStatementValue {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::UsingMessage(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Expr(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for RaiseStatementValue {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::UsingMessage(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Expr(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2803pub enum RaiseStatementValue {
2804 UsingMessage(Expr),
2806 Expr(Expr),
2808}
2809
2810impl fmt::Display for RaiseStatementValue {
2811 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
2812 match self {
2813 RaiseStatementValue::Expr(expr) => f.write_fmt(format_args!("{0}", expr))write!(f, "{expr}"),
2814 RaiseStatementValue::UsingMessage(expr) => f.write_fmt(format_args!("USING MESSAGE = {0}", expr))write!(f, "USING MESSAGE = {expr}"),
2815 }
2816 }
2817}
2818
2819#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DeclareAssignment {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
DeclareAssignment::Expr(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Expr",
&__self_0),
DeclareAssignment::Default(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Default", &__self_0),
DeclareAssignment::DuckAssignment(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DuckAssignment", &__self_0),
DeclareAssignment::For(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "For",
&__self_0),
DeclareAssignment::MsSqlAssignment(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"MsSqlAssignment", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DeclareAssignment {
#[inline]
fn clone(&self) -> DeclareAssignment {
match self {
DeclareAssignment::Expr(__self_0) =>
DeclareAssignment::Expr(::core::clone::Clone::clone(__self_0)),
DeclareAssignment::Default(__self_0) =>
DeclareAssignment::Default(::core::clone::Clone::clone(__self_0)),
DeclareAssignment::DuckAssignment(__self_0) =>
DeclareAssignment::DuckAssignment(::core::clone::Clone::clone(__self_0)),
DeclareAssignment::For(__self_0) =>
DeclareAssignment::For(::core::clone::Clone::clone(__self_0)),
DeclareAssignment::MsSqlAssignment(__self_0) =>
DeclareAssignment::MsSqlAssignment(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DeclareAssignment {
#[inline]
fn eq(&self, other: &DeclareAssignment) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(DeclareAssignment::Expr(__self_0),
DeclareAssignment::Expr(__arg1_0)) => __self_0 == __arg1_0,
(DeclareAssignment::Default(__self_0),
DeclareAssignment::Default(__arg1_0)) =>
__self_0 == __arg1_0,
(DeclareAssignment::DuckAssignment(__self_0),
DeclareAssignment::DuckAssignment(__arg1_0)) =>
__self_0 == __arg1_0,
(DeclareAssignment::For(__self_0),
DeclareAssignment::For(__arg1_0)) => __self_0 == __arg1_0,
(DeclareAssignment::MsSqlAssignment(__self_0),
DeclareAssignment::MsSqlAssignment(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DeclareAssignment {
#[inline]
fn partial_cmp(&self, other: &DeclareAssignment)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DeclareAssignment {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DeclareAssignment {
#[inline]
fn cmp(&self, other: &DeclareAssignment) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(DeclareAssignment::Expr(__self_0),
DeclareAssignment::Expr(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(DeclareAssignment::Default(__self_0),
DeclareAssignment::Default(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(DeclareAssignment::DuckAssignment(__self_0),
DeclareAssignment::DuckAssignment(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(DeclareAssignment::For(__self_0),
DeclareAssignment::For(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(DeclareAssignment::MsSqlAssignment(__self_0),
DeclareAssignment::MsSqlAssignment(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DeclareAssignment {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
DeclareAssignment::Expr(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
DeclareAssignment::Default(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
DeclareAssignment::DuckAssignment(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
DeclareAssignment::For(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
DeclareAssignment::MsSqlAssignment(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
2827#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2828#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DeclareAssignment {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Default(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DuckAssignment(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::For(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::MsSqlAssignment(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DeclareAssignment {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Default(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DuckAssignment(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::For(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::MsSqlAssignment(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2829pub enum DeclareAssignment {
2830 Expr(Box<Expr>),
2832
2833 Default(Box<Expr>),
2835
2836 DuckAssignment(Box<Expr>),
2843
2844 For(Box<Expr>),
2851
2852 MsSqlAssignment(Box<Expr>),
2859}
2860
2861impl fmt::Display for DeclareAssignment {
2862 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2863 match self {
2864 DeclareAssignment::Expr(expr) => {
2865 f.write_fmt(format_args!("{0}", expr))write!(f, "{expr}")
2866 }
2867 DeclareAssignment::Default(expr) => {
2868 f.write_fmt(format_args!("DEFAULT {0}", expr))write!(f, "DEFAULT {expr}")
2869 }
2870 DeclareAssignment::DuckAssignment(expr) => {
2871 f.write_fmt(format_args!(":= {0}", expr))write!(f, ":= {expr}")
2872 }
2873 DeclareAssignment::MsSqlAssignment(expr) => {
2874 f.write_fmt(format_args!("= {0}", expr))write!(f, "= {expr}")
2875 }
2876 DeclareAssignment::For(expr) => {
2877 f.write_fmt(format_args!("FOR {0}", expr))write!(f, "FOR {expr}")
2878 }
2879 }
2880 }
2881}
2882
2883#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DeclareType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
DeclareType::Cursor => "Cursor",
DeclareType::ResultSet => "ResultSet",
DeclareType::Exception => "Exception",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DeclareType {
#[inline]
fn clone(&self) -> DeclareType {
match self {
DeclareType::Cursor => DeclareType::Cursor,
DeclareType::ResultSet => DeclareType::ResultSet,
DeclareType::Exception => DeclareType::Exception,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DeclareType {
#[inline]
fn eq(&self, other: &DeclareType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DeclareType {
#[inline]
fn partial_cmp(&self, other: &DeclareType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DeclareType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DeclareType {
#[inline]
fn cmp(&self, other: &DeclareType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DeclareType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
2885#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2886#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DeclareType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Cursor => {}
Self::ResultSet => {}
Self::Exception => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DeclareType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Cursor => {}
Self::ResultSet => {}
Self::Exception => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2887pub enum DeclareType {
2888 Cursor,
2894
2895 ResultSet,
2903
2904 Exception,
2912}
2913
2914impl fmt::Display for DeclareType {
2915 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2916 match self {
2917 DeclareType::Cursor => {
2918 f.write_fmt(format_args!("CURSOR"))write!(f, "CURSOR")
2919 }
2920 DeclareType::ResultSet => {
2921 f.write_fmt(format_args!("RESULTSET"))write!(f, "RESULTSET")
2922 }
2923 DeclareType::Exception => {
2924 f.write_fmt(format_args!("EXCEPTION"))write!(f, "EXCEPTION")
2925 }
2926 }
2927 }
2928}
2929
2930#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Declare {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["names", "data_type", "assignment", "declare_type", "binary",
"sensitive", "scroll", "hold", "for_query"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.names, &self.data_type, &self.assignment,
&self.declare_type, &self.binary, &self.sensitive,
&self.scroll, &self.hold, &&self.for_query];
::core::fmt::Formatter::debug_struct_fields_finish(f, "Declare",
names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Declare {
#[inline]
fn clone(&self) -> Declare {
Declare {
names: ::core::clone::Clone::clone(&self.names),
data_type: ::core::clone::Clone::clone(&self.data_type),
assignment: ::core::clone::Clone::clone(&self.assignment),
declare_type: ::core::clone::Clone::clone(&self.declare_type),
binary: ::core::clone::Clone::clone(&self.binary),
sensitive: ::core::clone::Clone::clone(&self.sensitive),
scroll: ::core::clone::Clone::clone(&self.scroll),
hold: ::core::clone::Clone::clone(&self.hold),
for_query: ::core::clone::Clone::clone(&self.for_query),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Declare {
#[inline]
fn eq(&self, other: &Declare) -> bool {
self.names == other.names && self.data_type == other.data_type &&
self.assignment == other.assignment &&
self.declare_type == other.declare_type &&
self.binary == other.binary &&
self.sensitive == other.sensitive &&
self.scroll == other.scroll && self.hold == other.hold &&
self.for_query == other.for_query
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Declare {
#[inline]
fn partial_cmp(&self, other: &Declare)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Declare {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<DataType>>;
let _: ::core::cmp::AssertParamIsEq<Option<DeclareAssignment>>;
let _: ::core::cmp::AssertParamIsEq<Option<DeclareType>>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Query>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Declare {
#[inline]
fn cmp(&self, other: &Declare) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.names, &other.names) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.data_type, &other.data_type)
{
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.assignment,
&other.assignment) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.declare_type,
&other.declare_type) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.binary, &other.binary) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.sensitive,
&other.sensitive) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.scroll, &other.scroll) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.hold, &other.hold) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.for_query, &other.for_query),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Declare {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.names, state);
::core::hash::Hash::hash(&self.data_type, state);
::core::hash::Hash::hash(&self.assignment, state);
::core::hash::Hash::hash(&self.declare_type, state);
::core::hash::Hash::hash(&self.binary, state);
::core::hash::Hash::hash(&self.sensitive, state);
::core::hash::Hash::hash(&self.scroll, state);
::core::hash::Hash::hash(&self.hold, state);
::core::hash::Hash::hash(&self.for_query, state)
}
}Hash)]
2943#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
2944#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Declare {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.names, visitor)?;
sqlparser::ast::Visit::visit(&self.data_type, visitor)?;
sqlparser::ast::Visit::visit(&self.assignment, visitor)?;
sqlparser::ast::Visit::visit(&self.declare_type, visitor)?;
sqlparser::ast::Visit::visit(&self.binary, visitor)?;
sqlparser::ast::Visit::visit(&self.sensitive, visitor)?;
sqlparser::ast::Visit::visit(&self.scroll, visitor)?;
sqlparser::ast::Visit::visit(&self.hold, visitor)?;
sqlparser::ast::Visit::visit(&self.for_query, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Declare {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.names, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.data_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.assignment,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.declare_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.binary, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.sensitive,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.scroll, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.hold, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.for_query,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
2945pub struct Declare {
2946 pub names: Vec<Ident>,
2949 pub data_type: Option<DataType>,
2952 pub assignment: Option<DeclareAssignment>,
2954 pub declare_type: Option<DeclareType>,
2956 pub binary: Option<bool>,
2958 pub sensitive: Option<bool>,
2962 pub scroll: Option<bool>,
2966 pub hold: Option<bool>,
2970 pub for_query: Option<Box<Query>>,
2972}
2973
2974impl fmt::Display for Declare {
2975 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
2976 let Declare {
2977 names,
2978 data_type,
2979 assignment,
2980 declare_type,
2981 binary,
2982 sensitive,
2983 scroll,
2984 hold,
2985 for_query,
2986 } = self;
2987 f.write_fmt(format_args!("{0}", display_comma_separated(names)))write!(f, "{}", display_comma_separated(names))?;
2988
2989 if let Some(true) = binary {
2990 f.write_fmt(format_args!(" BINARY"))write!(f, " BINARY")?;
2991 }
2992
2993 if let Some(sensitive) = sensitive {
2994 if *sensitive {
2995 f.write_fmt(format_args!(" INSENSITIVE"))write!(f, " INSENSITIVE")?;
2996 } else {
2997 f.write_fmt(format_args!(" ASENSITIVE"))write!(f, " ASENSITIVE")?;
2998 }
2999 }
3000
3001 if let Some(scroll) = scroll {
3002 if *scroll {
3003 f.write_fmt(format_args!(" SCROLL"))write!(f, " SCROLL")?;
3004 } else {
3005 f.write_fmt(format_args!(" NO SCROLL"))write!(f, " NO SCROLL")?;
3006 }
3007 }
3008
3009 if let Some(declare_type) = declare_type {
3010 f.write_fmt(format_args!(" {0}", declare_type))write!(f, " {declare_type}")?;
3011 }
3012
3013 if let Some(hold) = hold {
3014 if *hold {
3015 f.write_fmt(format_args!(" WITH HOLD"))write!(f, " WITH HOLD")?;
3016 } else {
3017 f.write_fmt(format_args!(" WITHOUT HOLD"))write!(f, " WITHOUT HOLD")?;
3018 }
3019 }
3020
3021 if let Some(query) = for_query {
3022 f.write_fmt(format_args!(" FOR {0}", query))write!(f, " FOR {query}")?;
3023 }
3024
3025 if let Some(data_type) = data_type {
3026 f.write_fmt(format_args!(" {0}", data_type))write!(f, " {data_type}")?;
3027 }
3028
3029 if let Some(expr) = assignment {
3030 f.write_fmt(format_args!(" {0}", expr))write!(f, " {expr}")?;
3031 }
3032 Ok(())
3033 }
3034}
3035
3036#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateTableOptions {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CreateTableOptions::None =>
::core::fmt::Formatter::write_str(f, "None"),
CreateTableOptions::With(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "With",
&__self_0),
CreateTableOptions::Options(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Options", &__self_0),
CreateTableOptions::Plain(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Plain",
&__self_0),
CreateTableOptions::TableProperties(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"TableProperties", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::default::Default for CreateTableOptions {
#[inline]
fn default() -> CreateTableOptions { Self::None }
}Default, #[automatically_derived]
impl ::core::clone::Clone for CreateTableOptions {
#[inline]
fn clone(&self) -> CreateTableOptions {
match self {
CreateTableOptions::None => CreateTableOptions::None,
CreateTableOptions::With(__self_0) =>
CreateTableOptions::With(::core::clone::Clone::clone(__self_0)),
CreateTableOptions::Options(__self_0) =>
CreateTableOptions::Options(::core::clone::Clone::clone(__self_0)),
CreateTableOptions::Plain(__self_0) =>
CreateTableOptions::Plain(::core::clone::Clone::clone(__self_0)),
CreateTableOptions::TableProperties(__self_0) =>
CreateTableOptions::TableProperties(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateTableOptions {
#[inline]
fn eq(&self, other: &CreateTableOptions) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CreateTableOptions::With(__self_0),
CreateTableOptions::With(__arg1_0)) => __self_0 == __arg1_0,
(CreateTableOptions::Options(__self_0),
CreateTableOptions::Options(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateTableOptions::Plain(__self_0),
CreateTableOptions::Plain(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateTableOptions::TableProperties(__self_0),
CreateTableOptions::TableProperties(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateTableOptions {
#[inline]
fn partial_cmp(&self, other: &CreateTableOptions)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateTableOptions {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateTableOptions {
#[inline]
fn cmp(&self, other: &CreateTableOptions) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CreateTableOptions::With(__self_0),
CreateTableOptions::With(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateTableOptions::Options(__self_0),
CreateTableOptions::Options(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateTableOptions::Plain(__self_0),
CreateTableOptions::Plain(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateTableOptions::TableProperties(__self_0),
CreateTableOptions::TableProperties(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateTableOptions {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CreateTableOptions::With(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateTableOptions::Options(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateTableOptions::Plain(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateTableOptions::TableProperties(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
3038#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
3039#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateTableOptions {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::None => {}
Self::With(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Options(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Plain(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::TableProperties(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateTableOptions {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::None => {}
Self::With(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Options(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Plain(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::TableProperties(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
3040pub enum CreateTableOptions {
3042 #[default]
3044 None,
3045 With(Vec<SqlOption>),
3047 Options(Vec<SqlOption>),
3049 Plain(Vec<SqlOption>),
3051 TableProperties(Vec<SqlOption>),
3053}
3054
3055impl fmt::Display for CreateTableOptions {
3056 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3057 match self {
3058 CreateTableOptions::With(with_options) => {
3059 f.write_fmt(format_args!("WITH ({0})", display_comma_separated(with_options)))write!(f, "WITH ({})", display_comma_separated(with_options))
3060 }
3061 CreateTableOptions::Options(options) => {
3062 f.write_fmt(format_args!("OPTIONS({0})", display_comma_separated(options)))write!(f, "OPTIONS({})", display_comma_separated(options))
3063 }
3064 CreateTableOptions::TableProperties(options) => {
3065 f.write_fmt(format_args!("TBLPROPERTIES ({0})",
display_comma_separated(options)))write!(f, "TBLPROPERTIES ({})", display_comma_separated(options))
3066 }
3067 CreateTableOptions::Plain(options) => {
3068 f.write_fmt(format_args!("{0}", display_separated(options, " ")))write!(f, "{}", display_separated(options, " "))
3069 }
3070 CreateTableOptions::None => Ok(()),
3071 }
3072 }
3073}
3074
3075#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FromTable {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FromTable::WithFromKeyword(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"WithFromKeyword", &__self_0),
FromTable::WithoutKeyword(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"WithoutKeyword", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FromTable {
#[inline]
fn clone(&self) -> FromTable {
match self {
FromTable::WithFromKeyword(__self_0) =>
FromTable::WithFromKeyword(::core::clone::Clone::clone(__self_0)),
FromTable::WithoutKeyword(__self_0) =>
FromTable::WithoutKeyword(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FromTable {
#[inline]
fn eq(&self, other: &FromTable) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FromTable::WithFromKeyword(__self_0),
FromTable::WithFromKeyword(__arg1_0)) =>
__self_0 == __arg1_0,
(FromTable::WithoutKeyword(__self_0),
FromTable::WithoutKeyword(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FromTable {
#[inline]
fn partial_cmp(&self, other: &FromTable)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FromTable {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<TableWithJoins>>;
let _: ::core::cmp::AssertParamIsEq<Vec<TableWithJoins>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FromTable {
#[inline]
fn cmp(&self, other: &FromTable) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FromTable::WithFromKeyword(__self_0),
FromTable::WithFromKeyword(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FromTable::WithoutKeyword(__self_0),
FromTable::WithoutKeyword(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FromTable {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FromTable::WithFromKeyword(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FromTable::WithoutKeyword(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
3082#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
3083#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FromTable {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::WithFromKeyword(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::WithoutKeyword(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FromTable {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::WithFromKeyword(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::WithoutKeyword(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
3084pub enum FromTable {
3085 WithFromKeyword(Vec<TableWithJoins>),
3087 WithoutKeyword(Vec<TableWithJoins>),
3090}
3091impl Display for FromTable {
3092 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
3093 match self {
3094 FromTable::WithFromKeyword(tables) => {
3095 f.write_fmt(format_args!("FROM {0}", display_comma_separated(tables)))write!(f, "FROM {}", display_comma_separated(tables))
3096 }
3097 FromTable::WithoutKeyword(tables) => {
3098 f.write_fmt(format_args!("{0}", display_comma_separated(tables)))write!(f, "{}", display_comma_separated(tables))
3099 }
3100 }
3101 }
3102}
3103
3104#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Set {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Set::SingleAssignment {
scope: __self_0,
hivevar: __self_1,
variable: __self_2,
values: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"SingleAssignment", "scope", __self_0, "hivevar", __self_1,
"variable", __self_2, "values", &__self_3),
Set::ParenthesizedAssignments {
variables: __self_0, values: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"ParenthesizedAssignments", "variables", __self_0, "values",
&__self_1),
Set::MultipleAssignments { assignments: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"MultipleAssignments", "assignments", &__self_0),
Set::SetSessionAuthorization(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"SetSessionAuthorization", &__self_0),
Set::SetSessionParam(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"SetSessionParam", &__self_0),
Set::SetRole { context_modifier: __self_0, role_name: __self_1 }
=>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetRole", "context_modifier", __self_0, "role_name",
&__self_1),
Set::SetTimeZone { local: __self_0, value: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetTimeZone", "local", __self_0, "value", &__self_1),
Set::SetNames { charset_name: __self_0, collation_name: __self_1 }
=>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetNames", "charset_name", __self_0, "collation_name",
&__self_1),
Set::SetNamesDefault {} =>
::core::fmt::Formatter::write_str(f, "SetNamesDefault"),
Set::SetTransaction {
modes: __self_0, snapshot: __self_1, session: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"SetTransaction", "modes", __self_0, "snapshot", __self_1,
"session", &__self_2),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Set {
#[inline]
fn clone(&self) -> Set {
match self {
Set::SingleAssignment {
scope: __self_0,
hivevar: __self_1,
variable: __self_2,
values: __self_3 } =>
Set::SingleAssignment {
scope: ::core::clone::Clone::clone(__self_0),
hivevar: ::core::clone::Clone::clone(__self_1),
variable: ::core::clone::Clone::clone(__self_2),
values: ::core::clone::Clone::clone(__self_3),
},
Set::ParenthesizedAssignments {
variables: __self_0, values: __self_1 } =>
Set::ParenthesizedAssignments {
variables: ::core::clone::Clone::clone(__self_0),
values: ::core::clone::Clone::clone(__self_1),
},
Set::MultipleAssignments { assignments: __self_0 } =>
Set::MultipleAssignments {
assignments: ::core::clone::Clone::clone(__self_0),
},
Set::SetSessionAuthorization(__self_0) =>
Set::SetSessionAuthorization(::core::clone::Clone::clone(__self_0)),
Set::SetSessionParam(__self_0) =>
Set::SetSessionParam(::core::clone::Clone::clone(__self_0)),
Set::SetRole { context_modifier: __self_0, role_name: __self_1 }
=>
Set::SetRole {
context_modifier: ::core::clone::Clone::clone(__self_0),
role_name: ::core::clone::Clone::clone(__self_1),
},
Set::SetTimeZone { local: __self_0, value: __self_1 } =>
Set::SetTimeZone {
local: ::core::clone::Clone::clone(__self_0),
value: ::core::clone::Clone::clone(__self_1),
},
Set::SetNames { charset_name: __self_0, collation_name: __self_1 }
=>
Set::SetNames {
charset_name: ::core::clone::Clone::clone(__self_0),
collation_name: ::core::clone::Clone::clone(__self_1),
},
Set::SetNamesDefault {} => Set::SetNamesDefault {},
Set::SetTransaction {
modes: __self_0, snapshot: __self_1, session: __self_2 } =>
Set::SetTransaction {
modes: ::core::clone::Clone::clone(__self_0),
snapshot: ::core::clone::Clone::clone(__self_1),
session: ::core::clone::Clone::clone(__self_2),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Set {
#[inline]
fn eq(&self, other: &Set) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Set::SingleAssignment {
scope: __self_0,
hivevar: __self_1,
variable: __self_2,
values: __self_3 }, Set::SingleAssignment {
scope: __arg1_0,
hivevar: __arg1_1,
variable: __arg1_2,
values: __arg1_3 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Set::ParenthesizedAssignments {
variables: __self_0, values: __self_1 },
Set::ParenthesizedAssignments {
variables: __arg1_0, values: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Set::MultipleAssignments { assignments: __self_0 },
Set::MultipleAssignments { assignments: __arg1_0 }) =>
__self_0 == __arg1_0,
(Set::SetSessionAuthorization(__self_0),
Set::SetSessionAuthorization(__arg1_0)) =>
__self_0 == __arg1_0,
(Set::SetSessionParam(__self_0),
Set::SetSessionParam(__arg1_0)) => __self_0 == __arg1_0,
(Set::SetRole {
context_modifier: __self_0, role_name: __self_1 },
Set::SetRole {
context_modifier: __arg1_0, role_name: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Set::SetTimeZone { local: __self_0, value: __self_1 },
Set::SetTimeZone { local: __arg1_0, value: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Set::SetNames {
charset_name: __self_0, collation_name: __self_1 },
Set::SetNames {
charset_name: __arg1_0, collation_name: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Set::SetTransaction {
modes: __self_0, snapshot: __self_1, session: __self_2 },
Set::SetTransaction {
modes: __arg1_0, snapshot: __arg1_1, session: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Set {
#[inline]
fn partial_cmp(&self, other: &Set)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Set {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ContextModifier>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SetAssignment>>;
let _: ::core::cmp::AssertParamIsEq<SetSessionAuthorizationParam>;
let _: ::core::cmp::AssertParamIsEq<SetSessionParamKind>;
let _: ::core::cmp::AssertParamIsEq<Option<ContextModifier>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Vec<TransactionMode>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Set {
#[inline]
fn cmp(&self, other: &Set) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Set::SingleAssignment {
scope: __self_0,
hivevar: __self_1,
variable: __self_2,
values: __self_3 }, Set::SingleAssignment {
scope: __arg1_0,
hivevar: __arg1_1,
variable: __arg1_2,
values: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Set::ParenthesizedAssignments {
variables: __self_0, values: __self_1 },
Set::ParenthesizedAssignments {
variables: __arg1_0, values: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Set::MultipleAssignments { assignments: __self_0 },
Set::MultipleAssignments { assignments: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Set::SetSessionAuthorization(__self_0),
Set::SetSessionAuthorization(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Set::SetSessionParam(__self_0),
Set::SetSessionParam(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Set::SetRole {
context_modifier: __self_0, role_name: __self_1 },
Set::SetRole {
context_modifier: __arg1_0, role_name: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Set::SetTimeZone { local: __self_0, value: __self_1 },
Set::SetTimeZone { local: __arg1_0, value: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Set::SetNames {
charset_name: __self_0, collation_name: __self_1 },
Set::SetNames {
charset_name: __arg1_0, collation_name: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Set::SetTransaction {
modes: __self_0, snapshot: __self_1, session: __self_2 },
Set::SetTransaction {
modes: __arg1_0, snapshot: __arg1_1, session: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Set {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Set::SingleAssignment {
scope: __self_0,
hivevar: __self_1,
variable: __self_2,
values: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Set::ParenthesizedAssignments {
variables: __self_0, values: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Set::MultipleAssignments { assignments: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Set::SetSessionAuthorization(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Set::SetSessionParam(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Set::SetRole { context_modifier: __self_0, role_name: __self_1 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Set::SetTimeZone { local: __self_0, value: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Set::SetNames { charset_name: __self_0, collation_name: __self_1 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Set::SetTransaction {
modes: __self_0, snapshot: __self_1, session: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
_ => {}
}
}
}Hash)]
3105#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
3106#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Set {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::SingleAssignment { scope, hivevar, variable, values }
=> {
sqlparser::ast::Visit::visit(scope, visitor)?;
sqlparser::ast::Visit::visit(hivevar, visitor)?;
sqlparser::ast::Visit::visit(variable, visitor)?;
sqlparser::ast::Visit::visit(values, visitor)?;
}
Self::ParenthesizedAssignments { variables, values } => {
sqlparser::ast::Visit::visit(variables, visitor)?;
sqlparser::ast::Visit::visit(values, visitor)?;
}
Self::MultipleAssignments { assignments } => {
sqlparser::ast::Visit::visit(assignments, visitor)?;
}
Self::SetSessionAuthorization(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::SetSessionParam(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::SetRole { context_modifier, role_name } => {
sqlparser::ast::Visit::visit(context_modifier, visitor)?;
sqlparser::ast::Visit::visit(role_name, visitor)?;
}
Self::SetTimeZone { local, value } => {
sqlparser::ast::Visit::visit(local, visitor)?;
sqlparser::ast::Visit::visit(value, visitor)?;
}
Self::SetNames { charset_name, collation_name } => {
sqlparser::ast::Visit::visit(charset_name, visitor)?;
sqlparser::ast::Visit::visit(collation_name, visitor)?;
}
Self::SetNamesDefault {} => {}
Self::SetTransaction { modes, snapshot, session } => {
sqlparser::ast::Visit::visit(modes, visitor)?;
sqlparser::ast::Visit::visit(snapshot, visitor)?;
sqlparser::ast::Visit::visit(session, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Set {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::SingleAssignment { scope, hivevar, variable, values }
=> {
sqlparser::ast::VisitMut::visit(scope, visitor)?;
sqlparser::ast::VisitMut::visit(hivevar, visitor)?;
sqlparser::ast::VisitMut::visit(variable, visitor)?;
sqlparser::ast::VisitMut::visit(values, visitor)?;
}
Self::ParenthesizedAssignments { variables, values } => {
sqlparser::ast::VisitMut::visit(variables, visitor)?;
sqlparser::ast::VisitMut::visit(values, visitor)?;
}
Self::MultipleAssignments { assignments } => {
sqlparser::ast::VisitMut::visit(assignments, visitor)?;
}
Self::SetSessionAuthorization(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::SetSessionParam(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::SetRole { context_modifier, role_name } => {
sqlparser::ast::VisitMut::visit(context_modifier, visitor)?;
sqlparser::ast::VisitMut::visit(role_name, visitor)?;
}
Self::SetTimeZone { local, value } => {
sqlparser::ast::VisitMut::visit(local, visitor)?;
sqlparser::ast::VisitMut::visit(value, visitor)?;
}
Self::SetNames { charset_name, collation_name } => {
sqlparser::ast::VisitMut::visit(charset_name, visitor)?;
sqlparser::ast::VisitMut::visit(collation_name, visitor)?;
}
Self::SetNamesDefault {} => {}
Self::SetTransaction { modes, snapshot, session } => {
sqlparser::ast::VisitMut::visit(modes, visitor)?;
sqlparser::ast::VisitMut::visit(snapshot, visitor)?;
sqlparser::ast::VisitMut::visit(session, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
3107pub enum Set {
3109 SingleAssignment {
3113 scope: Option<ContextModifier>,
3115 hivevar: bool,
3117 variable: ObjectName,
3119 values: Vec<Expr>,
3121 },
3122 ParenthesizedAssignments {
3126 variables: Vec<ObjectName>,
3128 values: Vec<Expr>,
3130 },
3131 MultipleAssignments {
3135 assignments: Vec<SetAssignment>,
3137 },
3138 SetSessionAuthorization(SetSessionAuthorizationParam),
3147 SetSessionParam(SetSessionParamKind),
3151 SetRole {
3162 context_modifier: Option<ContextModifier>,
3164 role_name: Option<Ident>,
3166 },
3167 SetTimeZone {
3177 local: bool,
3179 value: Expr,
3181 },
3182 SetNames {
3186 charset_name: Ident,
3188 collation_name: Option<String>,
3190 },
3191 SetNamesDefault {},
3197 SetTransaction {
3201 modes: Vec<TransactionMode>,
3203 snapshot: Option<Value>,
3205 session: bool,
3207 },
3208}
3209
3210impl Display for Set {
3211 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3212 match self {
3213 Self::ParenthesizedAssignments { variables, values } => f.write_fmt(format_args!("SET ({0}) = ({1})",
display_comma_separated(variables), display_comma_separated(values)))write!(
3214 f,
3215 "SET ({}) = ({})",
3216 display_comma_separated(variables),
3217 display_comma_separated(values)
3218 ),
3219 Self::MultipleAssignments { assignments } => {
3220 f.write_fmt(format_args!("SET {0}", display_comma_separated(assignments)))write!(f, "SET {}", display_comma_separated(assignments))
3221 }
3222 Self::SetRole {
3223 context_modifier,
3224 role_name,
3225 } => {
3226 let role_name = role_name.clone().unwrap_or_else(|| Ident::new("NONE"));
3227 f.write_fmt(format_args!("SET {0}ROLE {1}",
context_modifier.map(|m|
::alloc::__export::must_use({
::alloc::fmt::format(format_args!("{0}", m))
})).unwrap_or_default(), role_name))write!(
3228 f,
3229 "SET {modifier}ROLE {role_name}",
3230 modifier = context_modifier.map(|m| format!("{m}")).unwrap_or_default()
3231 )
3232 }
3233 Self::SetSessionAuthorization(kind) => f.write_fmt(format_args!("SET SESSION AUTHORIZATION {0}", kind))write!(f, "SET SESSION AUTHORIZATION {kind}"),
3234 Self::SetSessionParam(kind) => f.write_fmt(format_args!("SET {0}", kind))write!(f, "SET {kind}"),
3235 Self::SetTransaction {
3236 modes,
3237 snapshot,
3238 session,
3239 } => {
3240 if *session {
3241 f.write_fmt(format_args!("SET SESSION CHARACTERISTICS AS TRANSACTION"))write!(f, "SET SESSION CHARACTERISTICS AS TRANSACTION")?;
3242 } else {
3243 f.write_fmt(format_args!("SET TRANSACTION"))write!(f, "SET TRANSACTION")?;
3244 }
3245 if !modes.is_empty() {
3246 f.write_fmt(format_args!(" {0}", display_comma_separated(modes)))write!(f, " {}", display_comma_separated(modes))?;
3247 }
3248 if let Some(snapshot_id) = snapshot {
3249 f.write_fmt(format_args!(" SNAPSHOT {0}", snapshot_id))write!(f, " SNAPSHOT {snapshot_id}")?;
3250 }
3251 Ok(())
3252 }
3253 Self::SetTimeZone { local, value } => {
3254 f.write_str("SET ")?;
3255 if *local {
3256 f.write_str("LOCAL ")?;
3257 }
3258 f.write_fmt(format_args!("TIME ZONE {0}", value))write!(f, "TIME ZONE {value}")
3259 }
3260 Self::SetNames {
3261 charset_name,
3262 collation_name,
3263 } => {
3264 f.write_fmt(format_args!("SET NAMES {0}", charset_name))write!(f, "SET NAMES {charset_name}")?;
3265
3266 if let Some(collation) = collation_name {
3267 f.write_str(" COLLATE ")?;
3268 f.write_str(collation)?;
3269 };
3270
3271 Ok(())
3272 }
3273 Self::SetNamesDefault {} => {
3274 f.write_str("SET NAMES DEFAULT")?;
3275
3276 Ok(())
3277 }
3278 Set::SingleAssignment {
3279 scope,
3280 hivevar,
3281 variable,
3282 values,
3283 } => {
3284 f.write_fmt(format_args!("SET {0}{1}{2} = {3}",
scope.map(|s|
::alloc::__export::must_use({
::alloc::fmt::format(format_args!("{0}", s))
})).unwrap_or_default(),
if *hivevar { "HIVEVAR:" } else { "" }, variable,
display_comma_separated(values)))write!(
3285 f,
3286 "SET {}{}{} = {}",
3287 scope.map(|s| format!("{s}")).unwrap_or_default(),
3288 if *hivevar { "HIVEVAR:" } else { "" },
3289 variable,
3290 display_comma_separated(values)
3291 )
3292 }
3293 }
3294 }
3295}
3296
3297#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ExceptionWhen {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "ExceptionWhen",
"idents", &self.idents, "statements", &&self.statements)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ExceptionWhen {
#[inline]
fn clone(&self) -> ExceptionWhen {
ExceptionWhen {
idents: ::core::clone::Clone::clone(&self.idents),
statements: ::core::clone::Clone::clone(&self.statements),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ExceptionWhen {
#[inline]
fn eq(&self, other: &ExceptionWhen) -> bool {
self.idents == other.idents && self.statements == other.statements
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ExceptionWhen {
#[inline]
fn partial_cmp(&self, other: &ExceptionWhen)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ExceptionWhen {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Statement>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ExceptionWhen {
#[inline]
fn cmp(&self, other: &ExceptionWhen) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.idents, &other.idents) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.statements, &other.statements),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ExceptionWhen {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.idents, state);
::core::hash::Hash::hash(&self.statements, state)
}
}Hash)]
3303#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
3304#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ExceptionWhen {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.idents, visitor)?;
sqlparser::ast::Visit::visit(&self.statements, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ExceptionWhen {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.idents, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.statements,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
3305pub struct ExceptionWhen {
3306 pub idents: Vec<Ident>,
3308 pub statements: Vec<Statement>,
3310}
3311
3312impl Display for ExceptionWhen {
3313 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3314 f.write_fmt(format_args!("WHEN {0} THEN",
display_separated(&self.idents, " OR ")))write!(
3315 f,
3316 "WHEN {idents} THEN",
3317 idents = display_separated(&self.idents, " OR ")
3318 )?;
3319
3320 if !self.statements.is_empty() {
3321 f.write_fmt(format_args!(" "))write!(f, " ")?;
3322 format_statement_list(f, &self.statements)?;
3323 }
3324
3325 Ok(())
3326 }
3327}
3328
3329#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Analyze {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["table_name", "partitions", "for_columns", "columns",
"cache_metadata", "noscan", "compute_statistics",
"has_table_keyword"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.table_name, &self.partitions, &self.for_columns,
&self.columns, &self.cache_metadata, &self.noscan,
&self.compute_statistics, &&self.has_table_keyword];
::core::fmt::Formatter::debug_struct_fields_finish(f, "Analyze",
names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Analyze {
#[inline]
fn clone(&self) -> Analyze {
Analyze {
table_name: ::core::clone::Clone::clone(&self.table_name),
partitions: ::core::clone::Clone::clone(&self.partitions),
for_columns: ::core::clone::Clone::clone(&self.for_columns),
columns: ::core::clone::Clone::clone(&self.columns),
cache_metadata: ::core::clone::Clone::clone(&self.cache_metadata),
noscan: ::core::clone::Clone::clone(&self.noscan),
compute_statistics: ::core::clone::Clone::clone(&self.compute_statistics),
has_table_keyword: ::core::clone::Clone::clone(&self.has_table_keyword),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Analyze {
#[inline]
fn eq(&self, other: &Analyze) -> bool {
self.for_columns == other.for_columns &&
self.cache_metadata == other.cache_metadata &&
self.noscan == other.noscan &&
self.compute_statistics == other.compute_statistics &&
self.has_table_keyword == other.has_table_keyword &&
self.table_name == other.table_name &&
self.partitions == other.partitions &&
self.columns == other.columns
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Analyze {
#[inline]
fn partial_cmp(&self, other: &Analyze)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Analyze {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Analyze {
#[inline]
fn cmp(&self, other: &Analyze) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.table_name, &other.table_name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.partitions,
&other.partitions) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.for_columns,
&other.for_columns) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.columns, &other.columns) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.cache_metadata,
&other.cache_metadata) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.noscan, &other.noscan) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.compute_statistics,
&other.compute_statistics) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.has_table_keyword,
&other.has_table_keyword),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Analyze {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.table_name, state);
::core::hash::Hash::hash(&self.partitions, state);
::core::hash::Hash::hash(&self.for_columns, state);
::core::hash::Hash::hash(&self.columns, state);
::core::hash::Hash::hash(&self.cache_metadata, state);
::core::hash::Hash::hash(&self.noscan, state);
::core::hash::Hash::hash(&self.compute_statistics, state);
::core::hash::Hash::hash(&self.has_table_keyword, state)
}
}Hash)]
3336#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
3337#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Analyze {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
if let Some(value) = &self.table_name {
visitor.pre_visit_relation(value)?;
sqlparser::ast::Visit::visit(value, visitor)?;
visitor.post_visit_relation(value)?;
}
sqlparser::ast::Visit::visit(&self.partitions, visitor)?;
sqlparser::ast::Visit::visit(&self.for_columns, visitor)?;
sqlparser::ast::Visit::visit(&self.columns, visitor)?;
sqlparser::ast::Visit::visit(&self.cache_metadata,
visitor)?;
sqlparser::ast::Visit::visit(&self.noscan, visitor)?;
sqlparser::ast::Visit::visit(&self.compute_statistics,
visitor)?;
sqlparser::ast::Visit::visit(&self.has_table_keyword,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Analyze {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
if let Some(value) = &mut self.table_name {
visitor.pre_visit_relation(value)?;
sqlparser::ast::VisitMut::visit(value, visitor)?;
visitor.post_visit_relation(value)?;
}
sqlparser::ast::VisitMut::visit(&mut self.partitions,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.for_columns,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.columns,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.cache_metadata,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.noscan, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.compute_statistics,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.has_table_keyword,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
3338pub struct Analyze {
3339 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
3340 pub table_name: Option<ObjectName>,
3342 pub partitions: Option<Vec<Expr>>,
3344 pub for_columns: bool,
3346 pub columns: Vec<Ident>,
3348 pub cache_metadata: bool,
3350 pub noscan: bool,
3352 pub compute_statistics: bool,
3354 pub has_table_keyword: bool,
3356}
3357
3358impl fmt::Display for Analyze {
3359 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3360 f.write_fmt(format_args!("ANALYZE"))write!(f, "ANALYZE")?;
3361 if let Some(ref table_name) = self.table_name {
3362 if self.has_table_keyword {
3363 f.write_fmt(format_args!(" TABLE"))write!(f, " TABLE")?;
3364 }
3365 f.write_fmt(format_args!(" {0}", table_name))write!(f, " {table_name}")?;
3366 }
3367 if !self.for_columns && !self.columns.is_empty() {
3368 f.write_fmt(format_args!(" ({0})", display_comma_separated(&self.columns)))write!(f, " ({})", display_comma_separated(&self.columns))?;
3369 }
3370 if let Some(ref parts) = self.partitions {
3371 if !parts.is_empty() {
3372 f.write_fmt(format_args!(" PARTITION ({0})", display_comma_separated(parts)))write!(f, " PARTITION ({})", display_comma_separated(parts))?;
3373 }
3374 }
3375 if self.compute_statistics {
3376 f.write_fmt(format_args!(" COMPUTE STATISTICS"))write!(f, " COMPUTE STATISTICS")?;
3377 }
3378 if self.noscan {
3379 f.write_fmt(format_args!(" NOSCAN"))write!(f, " NOSCAN")?;
3380 }
3381 if self.cache_metadata {
3382 f.write_fmt(format_args!(" CACHE METADATA"))write!(f, " CACHE METADATA")?;
3383 }
3384 if self.for_columns {
3385 f.write_fmt(format_args!(" FOR COLUMNS"))write!(f, " FOR COLUMNS")?;
3386 if !self.columns.is_empty() {
3387 f.write_fmt(format_args!(" {0}", display_comma_separated(&self.columns)))write!(f, " {}", display_comma_separated(&self.columns))?;
3388 }
3389 }
3390 Ok(())
3391 }
3392}
3393
3394#[allow(clippy::large_enum_variant)]
3396#[derive(#[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::fmt::Debug for Statement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Statement::Analyze(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Analyze", &__self_0),
Statement::Set(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Set",
&__self_0),
Statement::Truncate(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Truncate", &__self_0),
Statement::Msck(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Msck",
&__self_0),
Statement::Query(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Query",
&__self_0),
Statement::Insert(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Insert",
&__self_0),
Statement::Install { extension_name: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Install", "extension_name", &__self_0),
Statement::Load { extension_name: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Load",
"extension_name", &__self_0),
Statement::Directory {
overwrite: __self_0,
local: __self_1,
path: __self_2,
file_format: __self_3,
source: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"Directory", "overwrite", __self_0, "local", __self_1,
"path", __self_2, "file_format", __self_3, "source",
&__self_4),
Statement::Case(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Case",
&__self_0),
Statement::If(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "If",
&__self_0),
Statement::While(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "While",
&__self_0),
Statement::Raise(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Raise",
&__self_0),
Statement::Call(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Call",
&__self_0),
Statement::Copy {
source: __self_0,
to: __self_1,
target: __self_2,
options: __self_3,
legacy_options: __self_4,
values: __self_5 } => {
let names: &'static _ =
&["source", "to", "target", "options", "legacy_options",
"values"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f, "Copy",
names, values)
}
Statement::CopyIntoSnowflake {
kind: __self_0,
into: __self_1,
into_columns: __self_2,
from_obj: __self_3,
from_obj_alias: __self_4,
stage_params: __self_5,
from_transformations: __self_6,
from_query: __self_7,
files: __self_8,
pattern: __self_9,
file_format: __self_10,
copy_options: __self_11,
validation_mode: __self_12,
partition: __self_13 } => {
let names: &'static _ =
&["kind", "into", "into_columns", "from_obj",
"from_obj_alias", "stage_params", "from_transformations",
"from_query", "files", "pattern", "file_format",
"copy_options", "validation_mode", "partition"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, __self_6, __self_7, __self_8, __self_9, __self_10,
__self_11, __self_12, &__self_13];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CopyIntoSnowflake", names, values)
}
Statement::Open(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Open",
&__self_0),
Statement::Close { cursor: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Close",
"cursor", &__self_0),
Statement::Update(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Update",
&__self_0),
Statement::Delete(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Delete",
&__self_0),
Statement::CreateView(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateView", &__self_0),
Statement::CreateTable(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateTable", &__self_0),
Statement::CreateVirtualTable {
name: __self_0,
if_not_exists: __self_1,
module_name: __self_2,
module_args: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"CreateVirtualTable", "name", __self_0, "if_not_exists",
__self_1, "module_name", __self_2, "module_args",
&__self_3),
Statement::CreateIndex(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateIndex", &__self_0),
Statement::CreateRole(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateRole", &__self_0),
Statement::CreateSecret {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
storage_specifier: __self_4,
secret_type: __self_5,
options: __self_6 } => {
let names: &'static _ =
&["or_replace", "temporary", "if_not_exists", "name",
"storage_specifier", "secret_type", "options"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, &__self_6];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CreateSecret", names, values)
}
Statement::CreateServer(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateServer", &__self_0),
Statement::CreatePolicy(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreatePolicy", &__self_0),
Statement::CreateConnector(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateConnector", &__self_0),
Statement::CreateOperator(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateOperator", &__self_0),
Statement::CreateOperatorFamily(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateOperatorFamily", &__self_0),
Statement::CreateOperatorClass(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateOperatorClass", &__self_0),
Statement::AlterTable(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterTable", &__self_0),
Statement::AlterSchema(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterSchema", &__self_0),
Statement::AlterIndex { name: __self_0, operation: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterIndex", "name", __self_0, "operation", &__self_1),
Statement::AlterView {
name: __self_0,
columns: __self_1,
query: __self_2,
with_options: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"AlterView", "name", __self_0, "columns", __self_1, "query",
__self_2, "with_options", &__self_3),
Statement::AlterType(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterType", &__self_0),
Statement::AlterOperator(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterOperator", &__self_0),
Statement::AlterOperatorFamily(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterOperatorFamily", &__self_0),
Statement::AlterOperatorClass(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterOperatorClass", &__self_0),
Statement::AlterRole { name: __self_0, operation: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterRole", "name", __self_0, "operation", &__self_1),
Statement::AlterPolicy(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterPolicy", &__self_0),
Statement::AlterConnector {
name: __self_0,
properties: __self_1,
url: __self_2,
owner: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"AlterConnector", "name", __self_0, "properties", __self_1,
"url", __self_2, "owner", &__self_3),
Statement::AlterSession { set: __self_0, session_params: __self_1
} =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterSession", "set", __self_0, "session_params",
&__self_1),
Statement::AttachDatabase {
schema_name: __self_0,
database_file_name: __self_1,
database: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"AttachDatabase", "schema_name", __self_0,
"database_file_name", __self_1, "database", &__self_2),
Statement::AttachDuckDBDatabase {
if_not_exists: __self_0,
database: __self_1,
database_path: __self_2,
database_alias: __self_3,
attach_options: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"AttachDuckDBDatabase", "if_not_exists", __self_0,
"database", __self_1, "database_path", __self_2,
"database_alias", __self_3, "attach_options", &__self_4),
Statement::DetachDuckDBDatabase {
if_exists: __self_0,
database: __self_1,
database_alias: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"DetachDuckDBDatabase", "if_exists", __self_0, "database",
__self_1, "database_alias", &__self_2),
Statement::Drop {
object_type: __self_0,
if_exists: __self_1,
names: __self_2,
cascade: __self_3,
restrict: __self_4,
purge: __self_5,
temporary: __self_6,
table: __self_7 } => {
let names: &'static _ =
&["object_type", "if_exists", "names", "cascade",
"restrict", "purge", "temporary", "table"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, __self_6, &__self_7];
::core::fmt::Formatter::debug_struct_fields_finish(f, "Drop",
names, values)
}
Statement::DropFunction(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropFunction", &__self_0),
Statement::DropDomain(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropDomain", &__self_0),
Statement::DropProcedure {
if_exists: __self_0,
proc_desc: __self_1,
drop_behavior: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"DropProcedure", "if_exists", __self_0, "proc_desc",
__self_1, "drop_behavior", &__self_2),
Statement::DropSecret {
if_exists: __self_0,
temporary: __self_1,
name: __self_2,
storage_specifier: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"DropSecret", "if_exists", __self_0, "temporary", __self_1,
"name", __self_2, "storage_specifier", &__self_3),
Statement::DropPolicy(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropPolicy", &__self_0),
Statement::DropConnector { if_exists: __self_0, name: __self_1 }
=>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"DropConnector", "if_exists", __self_0, "name", &__self_1),
Statement::Declare { stmts: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Declare", "stmts", &__self_0),
Statement::CreateExtension(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateExtension", &__self_0),
Statement::DropExtension(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropExtension", &__self_0),
Statement::DropOperator(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropOperator", &__self_0),
Statement::DropOperatorFamily(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropOperatorFamily", &__self_0),
Statement::DropOperatorClass(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropOperatorClass", &__self_0),
Statement::Fetch {
name: __self_0,
direction: __self_1,
position: __self_2,
into: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f, "Fetch",
"name", __self_0, "direction", __self_1, "position",
__self_2, "into", &__self_3),
Statement::Flush {
object_type: __self_0,
location: __self_1,
channel: __self_2,
read_lock: __self_3,
export: __self_4,
tables: __self_5 } => {
let names: &'static _ =
&["object_type", "location", "channel", "read_lock",
"export", "tables"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f, "Flush",
names, values)
}
Statement::Discard { object_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Discard", "object_type", &__self_0),
Statement::ShowFunctions { filter: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"ShowFunctions", "filter", &__self_0),
Statement::ShowVariable { variable: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"ShowVariable", "variable", &__self_0),
Statement::ShowStatus {
filter: __self_0, global: __self_1, session: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowStatus", "filter", __self_0, "global", __self_1,
"session", &__self_2),
Statement::ShowVariables {
filter: __self_0, global: __self_1, session: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowVariables", "filter", __self_0, "global", __self_1,
"session", &__self_2),
Statement::ShowCreate { obj_type: __self_0, obj_name: __self_1 }
=>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"ShowCreate", "obj_type", __self_0, "obj_name", &__self_1),
Statement::ShowColumns {
extended: __self_0, full: __self_1, show_options: __self_2 }
=>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowColumns", "extended", __self_0, "full", __self_1,
"show_options", &__self_2),
Statement::ShowDatabases {
terse: __self_0, history: __self_1, show_options: __self_2 }
=>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowDatabases", "terse", __self_0, "history", __self_1,
"show_options", &__self_2),
Statement::ShowSchemas {
terse: __self_0, history: __self_1, show_options: __self_2 }
=>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowSchemas", "terse", __self_0, "history", __self_1,
"show_options", &__self_2),
Statement::ShowCharset(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ShowCharset", &__self_0),
Statement::ShowObjects(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ShowObjects", &__self_0),
Statement::ShowTables {
terse: __self_0,
history: __self_1,
extended: __self_2,
full: __self_3,
external: __self_4,
show_options: __self_5 } => {
let names: &'static _ =
&["terse", "history", "extended", "full", "external",
"show_options"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"ShowTables", names, values)
}
Statement::ShowViews {
terse: __self_0,
materialized: __self_1,
show_options: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowViews", "terse", __self_0, "materialized", __self_1,
"show_options", &__self_2),
Statement::ShowCollation { filter: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"ShowCollation", "filter", &__self_0),
Statement::Use(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Use",
&__self_0),
Statement::StartTransaction {
modes: __self_0,
begin: __self_1,
transaction: __self_2,
modifier: __self_3,
statements: __self_4,
exception: __self_5,
has_end_keyword: __self_6 } => {
let names: &'static _ =
&["modes", "begin", "transaction", "modifier", "statements",
"exception", "has_end_keyword"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, &__self_6];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"StartTransaction", names, values)
}
Statement::Comment {
object_type: __self_0,
object_name: __self_1,
comment: __self_2,
if_exists: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"Comment", "object_type", __self_0, "object_name", __self_1,
"comment", __self_2, "if_exists", &__self_3),
Statement::Commit {
chain: __self_0, end: __self_1, modifier: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"Commit", "chain", __self_0, "end", __self_1, "modifier",
&__self_2),
Statement::Rollback { chain: __self_0, savepoint: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Rollback", "chain", __self_0, "savepoint", &__self_1),
Statement::CreateSchema {
schema_name: __self_0,
if_not_exists: __self_1,
with: __self_2,
options: __self_3,
default_collate_spec: __self_4,
clone: __self_5 } => {
let names: &'static _ =
&["schema_name", "if_not_exists", "with", "options",
"default_collate_spec", "clone"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CreateSchema", names, values)
}
Statement::CreateDatabase {
db_name: __self_0,
if_not_exists: __self_1,
location: __self_2,
managed_location: __self_3,
or_replace: __self_4,
transient: __self_5,
clone: __self_6,
data_retention_time_in_days: __self_7,
max_data_extension_time_in_days: __self_8,
external_volume: __self_9,
catalog: __self_10,
replace_invalid_characters: __self_11,
default_ddl_collation: __self_12,
storage_serialization_policy: __self_13,
comment: __self_14,
default_charset: __self_15,
default_collation: __self_16,
catalog_sync: __self_17,
catalog_sync_namespace_mode: __self_18,
catalog_sync_namespace_flatten_delimiter: __self_19,
with_tags: __self_20,
with_contacts: __self_21 } => {
let names: &'static _ =
&["db_name", "if_not_exists", "location",
"managed_location", "or_replace", "transient", "clone",
"data_retention_time_in_days",
"max_data_extension_time_in_days", "external_volume",
"catalog", "replace_invalid_characters",
"default_ddl_collation", "storage_serialization_policy",
"comment", "default_charset", "default_collation",
"catalog_sync", "catalog_sync_namespace_mode",
"catalog_sync_namespace_flatten_delimiter", "with_tags",
"with_contacts"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, __self_6, __self_7, __self_8, __self_9, __self_10,
__self_11, __self_12, __self_13, __self_14, __self_15,
__self_16, __self_17, __self_18, __self_19, __self_20,
&__self_21];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CreateDatabase", names, values)
}
Statement::CreateFunction(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateFunction", &__self_0),
Statement::CreateTrigger(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateTrigger", &__self_0),
Statement::DropTrigger(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DropTrigger", &__self_0),
Statement::CreateProcedure {
or_alter: __self_0,
name: __self_1,
params: __self_2,
language: __self_3,
body: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"CreateProcedure", "or_alter", __self_0, "name", __self_1,
"params", __self_2, "language", __self_3, "body",
&__self_4),
Statement::CreateMacro {
or_replace: __self_0,
temporary: __self_1,
name: __self_2,
args: __self_3,
definition: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"CreateMacro", "or_replace", __self_0, "temporary",
__self_1, "name", __self_2, "args", __self_3, "definition",
&__self_4),
Statement::CreateStage {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
stage_params: __self_4,
directory_table_params: __self_5,
file_format: __self_6,
copy_options: __self_7,
comment: __self_8 } => {
let names: &'static _ =
&["or_replace", "temporary", "if_not_exists", "name",
"stage_params", "directory_table_params", "file_format",
"copy_options", "comment"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, __self_6, __self_7, &__self_8];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CreateStage", names, values)
}
Statement::Assert { condition: __self_0, message: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Assert", "condition", __self_0, "message", &__self_1),
Statement::Grant(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Grant",
&__self_0),
Statement::Deny(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Deny",
&__self_0),
Statement::Revoke(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Revoke",
&__self_0),
Statement::Deallocate { name: __self_0, prepare: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Deallocate", "name", __self_0, "prepare", &__self_1),
Statement::Execute {
name: __self_0,
parameters: __self_1,
has_parentheses: __self_2,
immediate: __self_3,
into: __self_4,
using: __self_5,
output: __self_6,
default: __self_7 } => {
let names: &'static _ =
&["name", "parameters", "has_parentheses", "immediate",
"into", "using", "output", "default"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, __self_6, &__self_7];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"Execute", names, values)
}
Statement::Prepare {
name: __self_0, data_types: __self_1, statement: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"Prepare", "name", __self_0, "data_types", __self_1,
"statement", &__self_2),
Statement::Kill { modifier: __self_0, id: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "Kill",
"modifier", __self_0, "id", &__self_1),
Statement::ExplainTable {
describe_alias: __self_0,
hive_format: __self_1,
has_table_keyword: __self_2,
table_name: __self_3 } =>
::core::fmt::Formatter::debug_struct_field4_finish(f,
"ExplainTable", "describe_alias", __self_0, "hive_format",
__self_1, "has_table_keyword", __self_2, "table_name",
&__self_3),
Statement::Explain {
describe_alias: __self_0,
analyze: __self_1,
verbose: __self_2,
query_plan: __self_3,
estimate: __self_4,
statement: __self_5,
format: __self_6,
options: __self_7 } => {
let names: &'static _ =
&["describe_alias", "analyze", "verbose", "query_plan",
"estimate", "statement", "format", "options"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
__self_5, __self_6, &__self_7];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"Explain", names, values)
}
Statement::Savepoint { name: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Savepoint", "name", &__self_0),
Statement::ReleaseSavepoint { name: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"ReleaseSavepoint", "name", &__self_0),
Statement::Merge(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Merge",
&__self_0),
Statement::Cache {
table_flag: __self_0,
table_name: __self_1,
has_as: __self_2,
options: __self_3,
query: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f, "Cache",
"table_flag", __self_0, "table_name", __self_1, "has_as",
__self_2, "options", __self_3, "query", &__self_4),
Statement::UNCache { table_name: __self_0, if_exists: __self_1 }
=>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"UNCache", "table_name", __self_0, "if_exists", &__self_1),
Statement::CreateSequence {
temporary: __self_0,
if_not_exists: __self_1,
name: __self_2,
data_type: __self_3,
sequence_options: __self_4,
owned_by: __self_5 } => {
let names: &'static _ =
&["temporary", "if_not_exists", "name", "data_type",
"sequence_options", "owned_by"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CreateSequence", names, values)
}
Statement::CreateDomain(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateDomain", &__self_0),
Statement::CreateType { name: __self_0, representation: __self_1 }
=>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"CreateType", "name", __self_0, "representation",
&__self_1),
Statement::Pragma {
name: __self_0, value: __self_1, is_eq: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"Pragma", "name", __self_0, "value", __self_1, "is_eq",
&__self_2),
Statement::LockTables { tables: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"LockTables", "tables", &__self_0),
Statement::UnlockTables =>
::core::fmt::Formatter::write_str(f, "UnlockTables"),
Statement::Unload {
query: __self_0,
query_text: __self_1,
to: __self_2,
auth: __self_3,
with: __self_4,
options: __self_5 } => {
let names: &'static _ =
&["query", "query_text", "to", "auth", "with", "options"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"Unload", names, values)
}
Statement::OptimizeTable {
name: __self_0,
on_cluster: __self_1,
partition: __self_2,
include_final: __self_3,
deduplicate: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"OptimizeTable", "name", __self_0, "on_cluster", __self_1,
"partition", __self_2, "include_final", __self_3,
"deduplicate", &__self_4),
Statement::LISTEN { channel: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"LISTEN", "channel", &__self_0),
Statement::UNLISTEN { channel: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"UNLISTEN", "channel", &__self_0),
Statement::NOTIFY { channel: __self_0, payload: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"NOTIFY", "channel", __self_0, "payload", &__self_1),
Statement::LoadData {
local: __self_0,
inpath: __self_1,
overwrite: __self_2,
table_name: __self_3,
partitioned: __self_4,
table_format: __self_5 } => {
let names: &'static _ =
&["local", "inpath", "overwrite", "table_name",
"partitioned", "table_format"];
let values: &[&dyn ::core::fmt::Debug] =
&[__self_0, __self_1, __self_2, __self_3, __self_4,
&__self_5];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"LoadData", names, values)
}
Statement::RenameTable(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"RenameTable", &__self_0),
Statement::List(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "List",
&__self_0),
Statement::Remove(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Remove",
&__self_0),
Statement::RaisError {
message: __self_0,
severity: __self_1,
state: __self_2,
arguments: __self_3,
options: __self_4 } =>
::core::fmt::Formatter::debug_struct_field5_finish(f,
"RaisError", "message", __self_0, "severity", __self_1,
"state", __self_2, "arguments", __self_3, "options",
&__self_4),
Statement::Print(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Print",
&__self_0),
Statement::Return(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Return",
&__self_0),
Statement::ExportData(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ExportData", &__self_0),
Statement::CreateUser(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"CreateUser", &__self_0),
Statement::AlterUser(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AlterUser", &__self_0),
Statement::Vacuum(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Vacuum",
&__self_0),
Statement::Reset(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Reset",
&__self_0),
}
}
}Debug, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::clone::Clone for Statement {
#[inline]
fn clone(&self) -> Statement {
match self {
Statement::Analyze(__self_0) =>
Statement::Analyze(::core::clone::Clone::clone(__self_0)),
Statement::Set(__self_0) =>
Statement::Set(::core::clone::Clone::clone(__self_0)),
Statement::Truncate(__self_0) =>
Statement::Truncate(::core::clone::Clone::clone(__self_0)),
Statement::Msck(__self_0) =>
Statement::Msck(::core::clone::Clone::clone(__self_0)),
Statement::Query(__self_0) =>
Statement::Query(::core::clone::Clone::clone(__self_0)),
Statement::Insert(__self_0) =>
Statement::Insert(::core::clone::Clone::clone(__self_0)),
Statement::Install { extension_name: __self_0 } =>
Statement::Install {
extension_name: ::core::clone::Clone::clone(__self_0),
},
Statement::Load { extension_name: __self_0 } =>
Statement::Load {
extension_name: ::core::clone::Clone::clone(__self_0),
},
Statement::Directory {
overwrite: __self_0,
local: __self_1,
path: __self_2,
file_format: __self_3,
source: __self_4 } =>
Statement::Directory {
overwrite: ::core::clone::Clone::clone(__self_0),
local: ::core::clone::Clone::clone(__self_1),
path: ::core::clone::Clone::clone(__self_2),
file_format: ::core::clone::Clone::clone(__self_3),
source: ::core::clone::Clone::clone(__self_4),
},
Statement::Case(__self_0) =>
Statement::Case(::core::clone::Clone::clone(__self_0)),
Statement::If(__self_0) =>
Statement::If(::core::clone::Clone::clone(__self_0)),
Statement::While(__self_0) =>
Statement::While(::core::clone::Clone::clone(__self_0)),
Statement::Raise(__self_0) =>
Statement::Raise(::core::clone::Clone::clone(__self_0)),
Statement::Call(__self_0) =>
Statement::Call(::core::clone::Clone::clone(__self_0)),
Statement::Copy {
source: __self_0,
to: __self_1,
target: __self_2,
options: __self_3,
legacy_options: __self_4,
values: __self_5 } =>
Statement::Copy {
source: ::core::clone::Clone::clone(__self_0),
to: ::core::clone::Clone::clone(__self_1),
target: ::core::clone::Clone::clone(__self_2),
options: ::core::clone::Clone::clone(__self_3),
legacy_options: ::core::clone::Clone::clone(__self_4),
values: ::core::clone::Clone::clone(__self_5),
},
Statement::CopyIntoSnowflake {
kind: __self_0,
into: __self_1,
into_columns: __self_2,
from_obj: __self_3,
from_obj_alias: __self_4,
stage_params: __self_5,
from_transformations: __self_6,
from_query: __self_7,
files: __self_8,
pattern: __self_9,
file_format: __self_10,
copy_options: __self_11,
validation_mode: __self_12,
partition: __self_13 } =>
Statement::CopyIntoSnowflake {
kind: ::core::clone::Clone::clone(__self_0),
into: ::core::clone::Clone::clone(__self_1),
into_columns: ::core::clone::Clone::clone(__self_2),
from_obj: ::core::clone::Clone::clone(__self_3),
from_obj_alias: ::core::clone::Clone::clone(__self_4),
stage_params: ::core::clone::Clone::clone(__self_5),
from_transformations: ::core::clone::Clone::clone(__self_6),
from_query: ::core::clone::Clone::clone(__self_7),
files: ::core::clone::Clone::clone(__self_8),
pattern: ::core::clone::Clone::clone(__self_9),
file_format: ::core::clone::Clone::clone(__self_10),
copy_options: ::core::clone::Clone::clone(__self_11),
validation_mode: ::core::clone::Clone::clone(__self_12),
partition: ::core::clone::Clone::clone(__self_13),
},
Statement::Open(__self_0) =>
Statement::Open(::core::clone::Clone::clone(__self_0)),
Statement::Close { cursor: __self_0 } =>
Statement::Close {
cursor: ::core::clone::Clone::clone(__self_0),
},
Statement::Update(__self_0) =>
Statement::Update(::core::clone::Clone::clone(__self_0)),
Statement::Delete(__self_0) =>
Statement::Delete(::core::clone::Clone::clone(__self_0)),
Statement::CreateView(__self_0) =>
Statement::CreateView(::core::clone::Clone::clone(__self_0)),
Statement::CreateTable(__self_0) =>
Statement::CreateTable(::core::clone::Clone::clone(__self_0)),
Statement::CreateVirtualTable {
name: __self_0,
if_not_exists: __self_1,
module_name: __self_2,
module_args: __self_3 } =>
Statement::CreateVirtualTable {
name: ::core::clone::Clone::clone(__self_0),
if_not_exists: ::core::clone::Clone::clone(__self_1),
module_name: ::core::clone::Clone::clone(__self_2),
module_args: ::core::clone::Clone::clone(__self_3),
},
Statement::CreateIndex(__self_0) =>
Statement::CreateIndex(::core::clone::Clone::clone(__self_0)),
Statement::CreateRole(__self_0) =>
Statement::CreateRole(::core::clone::Clone::clone(__self_0)),
Statement::CreateSecret {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
storage_specifier: __self_4,
secret_type: __self_5,
options: __self_6 } =>
Statement::CreateSecret {
or_replace: ::core::clone::Clone::clone(__self_0),
temporary: ::core::clone::Clone::clone(__self_1),
if_not_exists: ::core::clone::Clone::clone(__self_2),
name: ::core::clone::Clone::clone(__self_3),
storage_specifier: ::core::clone::Clone::clone(__self_4),
secret_type: ::core::clone::Clone::clone(__self_5),
options: ::core::clone::Clone::clone(__self_6),
},
Statement::CreateServer(__self_0) =>
Statement::CreateServer(::core::clone::Clone::clone(__self_0)),
Statement::CreatePolicy(__self_0) =>
Statement::CreatePolicy(::core::clone::Clone::clone(__self_0)),
Statement::CreateConnector(__self_0) =>
Statement::CreateConnector(::core::clone::Clone::clone(__self_0)),
Statement::CreateOperator(__self_0) =>
Statement::CreateOperator(::core::clone::Clone::clone(__self_0)),
Statement::CreateOperatorFamily(__self_0) =>
Statement::CreateOperatorFamily(::core::clone::Clone::clone(__self_0)),
Statement::CreateOperatorClass(__self_0) =>
Statement::CreateOperatorClass(::core::clone::Clone::clone(__self_0)),
Statement::AlterTable(__self_0) =>
Statement::AlterTable(::core::clone::Clone::clone(__self_0)),
Statement::AlterSchema(__self_0) =>
Statement::AlterSchema(::core::clone::Clone::clone(__self_0)),
Statement::AlterIndex { name: __self_0, operation: __self_1 } =>
Statement::AlterIndex {
name: ::core::clone::Clone::clone(__self_0),
operation: ::core::clone::Clone::clone(__self_1),
},
Statement::AlterView {
name: __self_0,
columns: __self_1,
query: __self_2,
with_options: __self_3 } =>
Statement::AlterView {
name: ::core::clone::Clone::clone(__self_0),
columns: ::core::clone::Clone::clone(__self_1),
query: ::core::clone::Clone::clone(__self_2),
with_options: ::core::clone::Clone::clone(__self_3),
},
Statement::AlterType(__self_0) =>
Statement::AlterType(::core::clone::Clone::clone(__self_0)),
Statement::AlterOperator(__self_0) =>
Statement::AlterOperator(::core::clone::Clone::clone(__self_0)),
Statement::AlterOperatorFamily(__self_0) =>
Statement::AlterOperatorFamily(::core::clone::Clone::clone(__self_0)),
Statement::AlterOperatorClass(__self_0) =>
Statement::AlterOperatorClass(::core::clone::Clone::clone(__self_0)),
Statement::AlterRole { name: __self_0, operation: __self_1 } =>
Statement::AlterRole {
name: ::core::clone::Clone::clone(__self_0),
operation: ::core::clone::Clone::clone(__self_1),
},
Statement::AlterPolicy(__self_0) =>
Statement::AlterPolicy(::core::clone::Clone::clone(__self_0)),
Statement::AlterConnector {
name: __self_0,
properties: __self_1,
url: __self_2,
owner: __self_3 } =>
Statement::AlterConnector {
name: ::core::clone::Clone::clone(__self_0),
properties: ::core::clone::Clone::clone(__self_1),
url: ::core::clone::Clone::clone(__self_2),
owner: ::core::clone::Clone::clone(__self_3),
},
Statement::AlterSession { set: __self_0, session_params: __self_1
} =>
Statement::AlterSession {
set: ::core::clone::Clone::clone(__self_0),
session_params: ::core::clone::Clone::clone(__self_1),
},
Statement::AttachDatabase {
schema_name: __self_0,
database_file_name: __self_1,
database: __self_2 } =>
Statement::AttachDatabase {
schema_name: ::core::clone::Clone::clone(__self_0),
database_file_name: ::core::clone::Clone::clone(__self_1),
database: ::core::clone::Clone::clone(__self_2),
},
Statement::AttachDuckDBDatabase {
if_not_exists: __self_0,
database: __self_1,
database_path: __self_2,
database_alias: __self_3,
attach_options: __self_4 } =>
Statement::AttachDuckDBDatabase {
if_not_exists: ::core::clone::Clone::clone(__self_0),
database: ::core::clone::Clone::clone(__self_1),
database_path: ::core::clone::Clone::clone(__self_2),
database_alias: ::core::clone::Clone::clone(__self_3),
attach_options: ::core::clone::Clone::clone(__self_4),
},
Statement::DetachDuckDBDatabase {
if_exists: __self_0,
database: __self_1,
database_alias: __self_2 } =>
Statement::DetachDuckDBDatabase {
if_exists: ::core::clone::Clone::clone(__self_0),
database: ::core::clone::Clone::clone(__self_1),
database_alias: ::core::clone::Clone::clone(__self_2),
},
Statement::Drop {
object_type: __self_0,
if_exists: __self_1,
names: __self_2,
cascade: __self_3,
restrict: __self_4,
purge: __self_5,
temporary: __self_6,
table: __self_7 } =>
Statement::Drop {
object_type: ::core::clone::Clone::clone(__self_0),
if_exists: ::core::clone::Clone::clone(__self_1),
names: ::core::clone::Clone::clone(__self_2),
cascade: ::core::clone::Clone::clone(__self_3),
restrict: ::core::clone::Clone::clone(__self_4),
purge: ::core::clone::Clone::clone(__self_5),
temporary: ::core::clone::Clone::clone(__self_6),
table: ::core::clone::Clone::clone(__self_7),
},
Statement::DropFunction(__self_0) =>
Statement::DropFunction(::core::clone::Clone::clone(__self_0)),
Statement::DropDomain(__self_0) =>
Statement::DropDomain(::core::clone::Clone::clone(__self_0)),
Statement::DropProcedure {
if_exists: __self_0,
proc_desc: __self_1,
drop_behavior: __self_2 } =>
Statement::DropProcedure {
if_exists: ::core::clone::Clone::clone(__self_0),
proc_desc: ::core::clone::Clone::clone(__self_1),
drop_behavior: ::core::clone::Clone::clone(__self_2),
},
Statement::DropSecret {
if_exists: __self_0,
temporary: __self_1,
name: __self_2,
storage_specifier: __self_3 } =>
Statement::DropSecret {
if_exists: ::core::clone::Clone::clone(__self_0),
temporary: ::core::clone::Clone::clone(__self_1),
name: ::core::clone::Clone::clone(__self_2),
storage_specifier: ::core::clone::Clone::clone(__self_3),
},
Statement::DropPolicy(__self_0) =>
Statement::DropPolicy(::core::clone::Clone::clone(__self_0)),
Statement::DropConnector { if_exists: __self_0, name: __self_1 }
=>
Statement::DropConnector {
if_exists: ::core::clone::Clone::clone(__self_0),
name: ::core::clone::Clone::clone(__self_1),
},
Statement::Declare { stmts: __self_0 } =>
Statement::Declare {
stmts: ::core::clone::Clone::clone(__self_0),
},
Statement::CreateExtension(__self_0) =>
Statement::CreateExtension(::core::clone::Clone::clone(__self_0)),
Statement::DropExtension(__self_0) =>
Statement::DropExtension(::core::clone::Clone::clone(__self_0)),
Statement::DropOperator(__self_0) =>
Statement::DropOperator(::core::clone::Clone::clone(__self_0)),
Statement::DropOperatorFamily(__self_0) =>
Statement::DropOperatorFamily(::core::clone::Clone::clone(__self_0)),
Statement::DropOperatorClass(__self_0) =>
Statement::DropOperatorClass(::core::clone::Clone::clone(__self_0)),
Statement::Fetch {
name: __self_0,
direction: __self_1,
position: __self_2,
into: __self_3 } =>
Statement::Fetch {
name: ::core::clone::Clone::clone(__self_0),
direction: ::core::clone::Clone::clone(__self_1),
position: ::core::clone::Clone::clone(__self_2),
into: ::core::clone::Clone::clone(__self_3),
},
Statement::Flush {
object_type: __self_0,
location: __self_1,
channel: __self_2,
read_lock: __self_3,
export: __self_4,
tables: __self_5 } =>
Statement::Flush {
object_type: ::core::clone::Clone::clone(__self_0),
location: ::core::clone::Clone::clone(__self_1),
channel: ::core::clone::Clone::clone(__self_2),
read_lock: ::core::clone::Clone::clone(__self_3),
export: ::core::clone::Clone::clone(__self_4),
tables: ::core::clone::Clone::clone(__self_5),
},
Statement::Discard { object_type: __self_0 } =>
Statement::Discard {
object_type: ::core::clone::Clone::clone(__self_0),
},
Statement::ShowFunctions { filter: __self_0 } =>
Statement::ShowFunctions {
filter: ::core::clone::Clone::clone(__self_0),
},
Statement::ShowVariable { variable: __self_0 } =>
Statement::ShowVariable {
variable: ::core::clone::Clone::clone(__self_0),
},
Statement::ShowStatus {
filter: __self_0, global: __self_1, session: __self_2 } =>
Statement::ShowStatus {
filter: ::core::clone::Clone::clone(__self_0),
global: ::core::clone::Clone::clone(__self_1),
session: ::core::clone::Clone::clone(__self_2),
},
Statement::ShowVariables {
filter: __self_0, global: __self_1, session: __self_2 } =>
Statement::ShowVariables {
filter: ::core::clone::Clone::clone(__self_0),
global: ::core::clone::Clone::clone(__self_1),
session: ::core::clone::Clone::clone(__self_2),
},
Statement::ShowCreate { obj_type: __self_0, obj_name: __self_1 }
=>
Statement::ShowCreate {
obj_type: ::core::clone::Clone::clone(__self_0),
obj_name: ::core::clone::Clone::clone(__self_1),
},
Statement::ShowColumns {
extended: __self_0, full: __self_1, show_options: __self_2 }
=>
Statement::ShowColumns {
extended: ::core::clone::Clone::clone(__self_0),
full: ::core::clone::Clone::clone(__self_1),
show_options: ::core::clone::Clone::clone(__self_2),
},
Statement::ShowDatabases {
terse: __self_0, history: __self_1, show_options: __self_2 }
=>
Statement::ShowDatabases {
terse: ::core::clone::Clone::clone(__self_0),
history: ::core::clone::Clone::clone(__self_1),
show_options: ::core::clone::Clone::clone(__self_2),
},
Statement::ShowSchemas {
terse: __self_0, history: __self_1, show_options: __self_2 }
=>
Statement::ShowSchemas {
terse: ::core::clone::Clone::clone(__self_0),
history: ::core::clone::Clone::clone(__self_1),
show_options: ::core::clone::Clone::clone(__self_2),
},
Statement::ShowCharset(__self_0) =>
Statement::ShowCharset(::core::clone::Clone::clone(__self_0)),
Statement::ShowObjects(__self_0) =>
Statement::ShowObjects(::core::clone::Clone::clone(__self_0)),
Statement::ShowTables {
terse: __self_0,
history: __self_1,
extended: __self_2,
full: __self_3,
external: __self_4,
show_options: __self_5 } =>
Statement::ShowTables {
terse: ::core::clone::Clone::clone(__self_0),
history: ::core::clone::Clone::clone(__self_1),
extended: ::core::clone::Clone::clone(__self_2),
full: ::core::clone::Clone::clone(__self_3),
external: ::core::clone::Clone::clone(__self_4),
show_options: ::core::clone::Clone::clone(__self_5),
},
Statement::ShowViews {
terse: __self_0,
materialized: __self_1,
show_options: __self_2 } =>
Statement::ShowViews {
terse: ::core::clone::Clone::clone(__self_0),
materialized: ::core::clone::Clone::clone(__self_1),
show_options: ::core::clone::Clone::clone(__self_2),
},
Statement::ShowCollation { filter: __self_0 } =>
Statement::ShowCollation {
filter: ::core::clone::Clone::clone(__self_0),
},
Statement::Use(__self_0) =>
Statement::Use(::core::clone::Clone::clone(__self_0)),
Statement::StartTransaction {
modes: __self_0,
begin: __self_1,
transaction: __self_2,
modifier: __self_3,
statements: __self_4,
exception: __self_5,
has_end_keyword: __self_6 } =>
Statement::StartTransaction {
modes: ::core::clone::Clone::clone(__self_0),
begin: ::core::clone::Clone::clone(__self_1),
transaction: ::core::clone::Clone::clone(__self_2),
modifier: ::core::clone::Clone::clone(__self_3),
statements: ::core::clone::Clone::clone(__self_4),
exception: ::core::clone::Clone::clone(__self_5),
has_end_keyword: ::core::clone::Clone::clone(__self_6),
},
Statement::Comment {
object_type: __self_0,
object_name: __self_1,
comment: __self_2,
if_exists: __self_3 } =>
Statement::Comment {
object_type: ::core::clone::Clone::clone(__self_0),
object_name: ::core::clone::Clone::clone(__self_1),
comment: ::core::clone::Clone::clone(__self_2),
if_exists: ::core::clone::Clone::clone(__self_3),
},
Statement::Commit {
chain: __self_0, end: __self_1, modifier: __self_2 } =>
Statement::Commit {
chain: ::core::clone::Clone::clone(__self_0),
end: ::core::clone::Clone::clone(__self_1),
modifier: ::core::clone::Clone::clone(__self_2),
},
Statement::Rollback { chain: __self_0, savepoint: __self_1 } =>
Statement::Rollback {
chain: ::core::clone::Clone::clone(__self_0),
savepoint: ::core::clone::Clone::clone(__self_1),
},
Statement::CreateSchema {
schema_name: __self_0,
if_not_exists: __self_1,
with: __self_2,
options: __self_3,
default_collate_spec: __self_4,
clone: __self_5 } =>
Statement::CreateSchema {
schema_name: ::core::clone::Clone::clone(__self_0),
if_not_exists: ::core::clone::Clone::clone(__self_1),
with: ::core::clone::Clone::clone(__self_2),
options: ::core::clone::Clone::clone(__self_3),
default_collate_spec: ::core::clone::Clone::clone(__self_4),
clone: ::core::clone::Clone::clone(__self_5),
},
Statement::CreateDatabase {
db_name: __self_0,
if_not_exists: __self_1,
location: __self_2,
managed_location: __self_3,
or_replace: __self_4,
transient: __self_5,
clone: __self_6,
data_retention_time_in_days: __self_7,
max_data_extension_time_in_days: __self_8,
external_volume: __self_9,
catalog: __self_10,
replace_invalid_characters: __self_11,
default_ddl_collation: __self_12,
storage_serialization_policy: __self_13,
comment: __self_14,
default_charset: __self_15,
default_collation: __self_16,
catalog_sync: __self_17,
catalog_sync_namespace_mode: __self_18,
catalog_sync_namespace_flatten_delimiter: __self_19,
with_tags: __self_20,
with_contacts: __self_21 } =>
Statement::CreateDatabase {
db_name: ::core::clone::Clone::clone(__self_0),
if_not_exists: ::core::clone::Clone::clone(__self_1),
location: ::core::clone::Clone::clone(__self_2),
managed_location: ::core::clone::Clone::clone(__self_3),
or_replace: ::core::clone::Clone::clone(__self_4),
transient: ::core::clone::Clone::clone(__self_5),
clone: ::core::clone::Clone::clone(__self_6),
data_retention_time_in_days: ::core::clone::Clone::clone(__self_7),
max_data_extension_time_in_days: ::core::clone::Clone::clone(__self_8),
external_volume: ::core::clone::Clone::clone(__self_9),
catalog: ::core::clone::Clone::clone(__self_10),
replace_invalid_characters: ::core::clone::Clone::clone(__self_11),
default_ddl_collation: ::core::clone::Clone::clone(__self_12),
storage_serialization_policy: ::core::clone::Clone::clone(__self_13),
comment: ::core::clone::Clone::clone(__self_14),
default_charset: ::core::clone::Clone::clone(__self_15),
default_collation: ::core::clone::Clone::clone(__self_16),
catalog_sync: ::core::clone::Clone::clone(__self_17),
catalog_sync_namespace_mode: ::core::clone::Clone::clone(__self_18),
catalog_sync_namespace_flatten_delimiter: ::core::clone::Clone::clone(__self_19),
with_tags: ::core::clone::Clone::clone(__self_20),
with_contacts: ::core::clone::Clone::clone(__self_21),
},
Statement::CreateFunction(__self_0) =>
Statement::CreateFunction(::core::clone::Clone::clone(__self_0)),
Statement::CreateTrigger(__self_0) =>
Statement::CreateTrigger(::core::clone::Clone::clone(__self_0)),
Statement::DropTrigger(__self_0) =>
Statement::DropTrigger(::core::clone::Clone::clone(__self_0)),
Statement::CreateProcedure {
or_alter: __self_0,
name: __self_1,
params: __self_2,
language: __self_3,
body: __self_4 } =>
Statement::CreateProcedure {
or_alter: ::core::clone::Clone::clone(__self_0),
name: ::core::clone::Clone::clone(__self_1),
params: ::core::clone::Clone::clone(__self_2),
language: ::core::clone::Clone::clone(__self_3),
body: ::core::clone::Clone::clone(__self_4),
},
Statement::CreateMacro {
or_replace: __self_0,
temporary: __self_1,
name: __self_2,
args: __self_3,
definition: __self_4 } =>
Statement::CreateMacro {
or_replace: ::core::clone::Clone::clone(__self_0),
temporary: ::core::clone::Clone::clone(__self_1),
name: ::core::clone::Clone::clone(__self_2),
args: ::core::clone::Clone::clone(__self_3),
definition: ::core::clone::Clone::clone(__self_4),
},
Statement::CreateStage {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
stage_params: __self_4,
directory_table_params: __self_5,
file_format: __self_6,
copy_options: __self_7,
comment: __self_8 } =>
Statement::CreateStage {
or_replace: ::core::clone::Clone::clone(__self_0),
temporary: ::core::clone::Clone::clone(__self_1),
if_not_exists: ::core::clone::Clone::clone(__self_2),
name: ::core::clone::Clone::clone(__self_3),
stage_params: ::core::clone::Clone::clone(__self_4),
directory_table_params: ::core::clone::Clone::clone(__self_5),
file_format: ::core::clone::Clone::clone(__self_6),
copy_options: ::core::clone::Clone::clone(__self_7),
comment: ::core::clone::Clone::clone(__self_8),
},
Statement::Assert { condition: __self_0, message: __self_1 } =>
Statement::Assert {
condition: ::core::clone::Clone::clone(__self_0),
message: ::core::clone::Clone::clone(__self_1),
},
Statement::Grant(__self_0) =>
Statement::Grant(::core::clone::Clone::clone(__self_0)),
Statement::Deny(__self_0) =>
Statement::Deny(::core::clone::Clone::clone(__self_0)),
Statement::Revoke(__self_0) =>
Statement::Revoke(::core::clone::Clone::clone(__self_0)),
Statement::Deallocate { name: __self_0, prepare: __self_1 } =>
Statement::Deallocate {
name: ::core::clone::Clone::clone(__self_0),
prepare: ::core::clone::Clone::clone(__self_1),
},
Statement::Execute {
name: __self_0,
parameters: __self_1,
has_parentheses: __self_2,
immediate: __self_3,
into: __self_4,
using: __self_5,
output: __self_6,
default: __self_7 } =>
Statement::Execute {
name: ::core::clone::Clone::clone(__self_0),
parameters: ::core::clone::Clone::clone(__self_1),
has_parentheses: ::core::clone::Clone::clone(__self_2),
immediate: ::core::clone::Clone::clone(__self_3),
into: ::core::clone::Clone::clone(__self_4),
using: ::core::clone::Clone::clone(__self_5),
output: ::core::clone::Clone::clone(__self_6),
default: ::core::clone::Clone::clone(__self_7),
},
Statement::Prepare {
name: __self_0, data_types: __self_1, statement: __self_2 } =>
Statement::Prepare {
name: ::core::clone::Clone::clone(__self_0),
data_types: ::core::clone::Clone::clone(__self_1),
statement: ::core::clone::Clone::clone(__self_2),
},
Statement::Kill { modifier: __self_0, id: __self_1 } =>
Statement::Kill {
modifier: ::core::clone::Clone::clone(__self_0),
id: ::core::clone::Clone::clone(__self_1),
},
Statement::ExplainTable {
describe_alias: __self_0,
hive_format: __self_1,
has_table_keyword: __self_2,
table_name: __self_3 } =>
Statement::ExplainTable {
describe_alias: ::core::clone::Clone::clone(__self_0),
hive_format: ::core::clone::Clone::clone(__self_1),
has_table_keyword: ::core::clone::Clone::clone(__self_2),
table_name: ::core::clone::Clone::clone(__self_3),
},
Statement::Explain {
describe_alias: __self_0,
analyze: __self_1,
verbose: __self_2,
query_plan: __self_3,
estimate: __self_4,
statement: __self_5,
format: __self_6,
options: __self_7 } =>
Statement::Explain {
describe_alias: ::core::clone::Clone::clone(__self_0),
analyze: ::core::clone::Clone::clone(__self_1),
verbose: ::core::clone::Clone::clone(__self_2),
query_plan: ::core::clone::Clone::clone(__self_3),
estimate: ::core::clone::Clone::clone(__self_4),
statement: ::core::clone::Clone::clone(__self_5),
format: ::core::clone::Clone::clone(__self_6),
options: ::core::clone::Clone::clone(__self_7),
},
Statement::Savepoint { name: __self_0 } =>
Statement::Savepoint {
name: ::core::clone::Clone::clone(__self_0),
},
Statement::ReleaseSavepoint { name: __self_0 } =>
Statement::ReleaseSavepoint {
name: ::core::clone::Clone::clone(__self_0),
},
Statement::Merge(__self_0) =>
Statement::Merge(::core::clone::Clone::clone(__self_0)),
Statement::Cache {
table_flag: __self_0,
table_name: __self_1,
has_as: __self_2,
options: __self_3,
query: __self_4 } =>
Statement::Cache {
table_flag: ::core::clone::Clone::clone(__self_0),
table_name: ::core::clone::Clone::clone(__self_1),
has_as: ::core::clone::Clone::clone(__self_2),
options: ::core::clone::Clone::clone(__self_3),
query: ::core::clone::Clone::clone(__self_4),
},
Statement::UNCache { table_name: __self_0, if_exists: __self_1 }
=>
Statement::UNCache {
table_name: ::core::clone::Clone::clone(__self_0),
if_exists: ::core::clone::Clone::clone(__self_1),
},
Statement::CreateSequence {
temporary: __self_0,
if_not_exists: __self_1,
name: __self_2,
data_type: __self_3,
sequence_options: __self_4,
owned_by: __self_5 } =>
Statement::CreateSequence {
temporary: ::core::clone::Clone::clone(__self_0),
if_not_exists: ::core::clone::Clone::clone(__self_1),
name: ::core::clone::Clone::clone(__self_2),
data_type: ::core::clone::Clone::clone(__self_3),
sequence_options: ::core::clone::Clone::clone(__self_4),
owned_by: ::core::clone::Clone::clone(__self_5),
},
Statement::CreateDomain(__self_0) =>
Statement::CreateDomain(::core::clone::Clone::clone(__self_0)),
Statement::CreateType { name: __self_0, representation: __self_1 }
=>
Statement::CreateType {
name: ::core::clone::Clone::clone(__self_0),
representation: ::core::clone::Clone::clone(__self_1),
},
Statement::Pragma {
name: __self_0, value: __self_1, is_eq: __self_2 } =>
Statement::Pragma {
name: ::core::clone::Clone::clone(__self_0),
value: ::core::clone::Clone::clone(__self_1),
is_eq: ::core::clone::Clone::clone(__self_2),
},
Statement::LockTables { tables: __self_0 } =>
Statement::LockTables {
tables: ::core::clone::Clone::clone(__self_0),
},
Statement::UnlockTables => Statement::UnlockTables,
Statement::Unload {
query: __self_0,
query_text: __self_1,
to: __self_2,
auth: __self_3,
with: __self_4,
options: __self_5 } =>
Statement::Unload {
query: ::core::clone::Clone::clone(__self_0),
query_text: ::core::clone::Clone::clone(__self_1),
to: ::core::clone::Clone::clone(__self_2),
auth: ::core::clone::Clone::clone(__self_3),
with: ::core::clone::Clone::clone(__self_4),
options: ::core::clone::Clone::clone(__self_5),
},
Statement::OptimizeTable {
name: __self_0,
on_cluster: __self_1,
partition: __self_2,
include_final: __self_3,
deduplicate: __self_4 } =>
Statement::OptimizeTable {
name: ::core::clone::Clone::clone(__self_0),
on_cluster: ::core::clone::Clone::clone(__self_1),
partition: ::core::clone::Clone::clone(__self_2),
include_final: ::core::clone::Clone::clone(__self_3),
deduplicate: ::core::clone::Clone::clone(__self_4),
},
Statement::LISTEN { channel: __self_0 } =>
Statement::LISTEN {
channel: ::core::clone::Clone::clone(__self_0),
},
Statement::UNLISTEN { channel: __self_0 } =>
Statement::UNLISTEN {
channel: ::core::clone::Clone::clone(__self_0),
},
Statement::NOTIFY { channel: __self_0, payload: __self_1 } =>
Statement::NOTIFY {
channel: ::core::clone::Clone::clone(__self_0),
payload: ::core::clone::Clone::clone(__self_1),
},
Statement::LoadData {
local: __self_0,
inpath: __self_1,
overwrite: __self_2,
table_name: __self_3,
partitioned: __self_4,
table_format: __self_5 } =>
Statement::LoadData {
local: ::core::clone::Clone::clone(__self_0),
inpath: ::core::clone::Clone::clone(__self_1),
overwrite: ::core::clone::Clone::clone(__self_2),
table_name: ::core::clone::Clone::clone(__self_3),
partitioned: ::core::clone::Clone::clone(__self_4),
table_format: ::core::clone::Clone::clone(__self_5),
},
Statement::RenameTable(__self_0) =>
Statement::RenameTable(::core::clone::Clone::clone(__self_0)),
Statement::List(__self_0) =>
Statement::List(::core::clone::Clone::clone(__self_0)),
Statement::Remove(__self_0) =>
Statement::Remove(::core::clone::Clone::clone(__self_0)),
Statement::RaisError {
message: __self_0,
severity: __self_1,
state: __self_2,
arguments: __self_3,
options: __self_4 } =>
Statement::RaisError {
message: ::core::clone::Clone::clone(__self_0),
severity: ::core::clone::Clone::clone(__self_1),
state: ::core::clone::Clone::clone(__self_2),
arguments: ::core::clone::Clone::clone(__self_3),
options: ::core::clone::Clone::clone(__self_4),
},
Statement::Print(__self_0) =>
Statement::Print(::core::clone::Clone::clone(__self_0)),
Statement::Return(__self_0) =>
Statement::Return(::core::clone::Clone::clone(__self_0)),
Statement::ExportData(__self_0) =>
Statement::ExportData(::core::clone::Clone::clone(__self_0)),
Statement::CreateUser(__self_0) =>
Statement::CreateUser(::core::clone::Clone::clone(__self_0)),
Statement::AlterUser(__self_0) =>
Statement::AlterUser(::core::clone::Clone::clone(__self_0)),
Statement::Vacuum(__self_0) =>
Statement::Vacuum(::core::clone::Clone::clone(__self_0)),
Statement::Reset(__self_0) =>
Statement::Reset(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::PartialEq for Statement {
#[inline]
fn eq(&self, other: &Statement) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Statement::Analyze(__self_0), Statement::Analyze(__arg1_0))
=> __self_0 == __arg1_0,
(Statement::Set(__self_0), Statement::Set(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Truncate(__self_0), Statement::Truncate(__arg1_0))
=> __self_0 == __arg1_0,
(Statement::Msck(__self_0), Statement::Msck(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Query(__self_0), Statement::Query(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Insert(__self_0), Statement::Insert(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Install { extension_name: __self_0 },
Statement::Install { extension_name: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::Load { extension_name: __self_0 },
Statement::Load { extension_name: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::Directory {
overwrite: __self_0,
local: __self_1,
path: __self_2,
file_format: __self_3,
source: __self_4 }, Statement::Directory {
overwrite: __arg1_0,
local: __arg1_1,
path: __arg1_2,
file_format: __arg1_3,
source: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Statement::Case(__self_0), Statement::Case(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::If(__self_0), Statement::If(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::While(__self_0), Statement::While(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Raise(__self_0), Statement::Raise(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Call(__self_0), Statement::Call(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Copy {
source: __self_0,
to: __self_1,
target: __self_2,
options: __self_3,
legacy_options: __self_4,
values: __self_5 }, Statement::Copy {
source: __arg1_0,
to: __arg1_1,
target: __arg1_2,
options: __arg1_3,
legacy_options: __arg1_4,
values: __arg1_5 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::CopyIntoSnowflake {
kind: __self_0,
into: __self_1,
into_columns: __self_2,
from_obj: __self_3,
from_obj_alias: __self_4,
stage_params: __self_5,
from_transformations: __self_6,
from_query: __self_7,
files: __self_8,
pattern: __self_9,
file_format: __self_10,
copy_options: __self_11,
validation_mode: __self_12,
partition: __self_13 }, Statement::CopyIntoSnowflake {
kind: __arg1_0,
into: __arg1_1,
into_columns: __arg1_2,
from_obj: __arg1_3,
from_obj_alias: __arg1_4,
stage_params: __arg1_5,
from_transformations: __arg1_6,
from_query: __arg1_7,
files: __arg1_8,
pattern: __arg1_9,
file_format: __arg1_10,
copy_options: __arg1_11,
validation_mode: __arg1_12,
partition: __arg1_13 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5 &&
__self_6 == __arg1_6 && __self_7 == __arg1_7 &&
__self_8 == __arg1_8 && __self_9 == __arg1_9 &&
__self_10 == __arg1_10 && __self_11 == __arg1_11 &&
__self_12 == __arg1_12 && __self_13 == __arg1_13,
(Statement::Open(__self_0), Statement::Open(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Close { cursor: __self_0 }, Statement::Close {
cursor: __arg1_0 }) => __self_0 == __arg1_0,
(Statement::Update(__self_0), Statement::Update(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Delete(__self_0), Statement::Delete(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::CreateView(__self_0),
Statement::CreateView(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateTable(__self_0),
Statement::CreateTable(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateVirtualTable {
name: __self_0,
if_not_exists: __self_1,
module_name: __self_2,
module_args: __self_3 }, Statement::CreateVirtualTable {
name: __arg1_0,
if_not_exists: __arg1_1,
module_name: __arg1_2,
module_args: __arg1_3 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Statement::CreateIndex(__self_0),
Statement::CreateIndex(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateRole(__self_0),
Statement::CreateRole(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateSecret {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
storage_specifier: __self_4,
secret_type: __self_5,
options: __self_6 }, Statement::CreateSecret {
or_replace: __arg1_0,
temporary: __arg1_1,
if_not_exists: __arg1_2,
name: __arg1_3,
storage_specifier: __arg1_4,
secret_type: __arg1_5,
options: __arg1_6 }) =>
__self_0 == __arg1_0 && __self_2 == __arg1_2 &&
__self_1 == __arg1_1 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5 &&
__self_6 == __arg1_6,
(Statement::CreateServer(__self_0),
Statement::CreateServer(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreatePolicy(__self_0),
Statement::CreatePolicy(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateConnector(__self_0),
Statement::CreateConnector(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::CreateOperator(__self_0),
Statement::CreateOperator(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::CreateOperatorFamily(__self_0),
Statement::CreateOperatorFamily(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::CreateOperatorClass(__self_0),
Statement::CreateOperatorClass(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::AlterTable(__self_0),
Statement::AlterTable(__arg1_0)) => __self_0 == __arg1_0,
(Statement::AlterSchema(__self_0),
Statement::AlterSchema(__arg1_0)) => __self_0 == __arg1_0,
(Statement::AlterIndex { name: __self_0, operation: __self_1
}, Statement::AlterIndex {
name: __arg1_0, operation: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::AlterView {
name: __self_0,
columns: __self_1,
query: __self_2,
with_options: __self_3 }, Statement::AlterView {
name: __arg1_0,
columns: __arg1_1,
query: __arg1_2,
with_options: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Statement::AlterType(__self_0),
Statement::AlterType(__arg1_0)) => __self_0 == __arg1_0,
(Statement::AlterOperator(__self_0),
Statement::AlterOperator(__arg1_0)) => __self_0 == __arg1_0,
(Statement::AlterOperatorFamily(__self_0),
Statement::AlterOperatorFamily(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::AlterOperatorClass(__self_0),
Statement::AlterOperatorClass(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::AlterRole { name: __self_0, operation: __self_1 },
Statement::AlterRole { name: __arg1_0, operation: __arg1_1
}) => __self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::AlterPolicy(__self_0),
Statement::AlterPolicy(__arg1_0)) => __self_0 == __arg1_0,
(Statement::AlterConnector {
name: __self_0,
properties: __self_1,
url: __self_2,
owner: __self_3 }, Statement::AlterConnector {
name: __arg1_0,
properties: __arg1_1,
url: __arg1_2,
owner: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Statement::AlterSession {
set: __self_0, session_params: __self_1 },
Statement::AlterSession {
set: __arg1_0, session_params: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::AttachDatabase {
schema_name: __self_0,
database_file_name: __self_1,
database: __self_2 }, Statement::AttachDatabase {
schema_name: __arg1_0,
database_file_name: __arg1_1,
database: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
(Statement::AttachDuckDBDatabase {
if_not_exists: __self_0,
database: __self_1,
database_path: __self_2,
database_alias: __self_3,
attach_options: __self_4 },
Statement::AttachDuckDBDatabase {
if_not_exists: __arg1_0,
database: __arg1_1,
database_path: __arg1_2,
database_alias: __arg1_3,
attach_options: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Statement::DetachDuckDBDatabase {
if_exists: __self_0,
database: __self_1,
database_alias: __self_2 },
Statement::DetachDuckDBDatabase {
if_exists: __arg1_0,
database: __arg1_1,
database_alias: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::Drop {
object_type: __self_0,
if_exists: __self_1,
names: __self_2,
cascade: __self_3,
restrict: __self_4,
purge: __self_5,
temporary: __self_6,
table: __self_7 }, Statement::Drop {
object_type: __arg1_0,
if_exists: __arg1_1,
names: __arg1_2,
cascade: __arg1_3,
restrict: __arg1_4,
purge: __arg1_5,
temporary: __arg1_6,
table: __arg1_7 }) =>
__self_1 == __arg1_1 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5 &&
__self_6 == __arg1_6 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_7 == __arg1_7,
(Statement::DropFunction(__self_0),
Statement::DropFunction(__arg1_0)) => __self_0 == __arg1_0,
(Statement::DropDomain(__self_0),
Statement::DropDomain(__arg1_0)) => __self_0 == __arg1_0,
(Statement::DropProcedure {
if_exists: __self_0,
proc_desc: __self_1,
drop_behavior: __self_2 }, Statement::DropProcedure {
if_exists: __arg1_0,
proc_desc: __arg1_1,
drop_behavior: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::DropSecret {
if_exists: __self_0,
temporary: __self_1,
name: __self_2,
storage_specifier: __self_3 }, Statement::DropSecret {
if_exists: __arg1_0,
temporary: __arg1_1,
name: __arg1_2,
storage_specifier: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Statement::DropPolicy(__self_0),
Statement::DropPolicy(__arg1_0)) => __self_0 == __arg1_0,
(Statement::DropConnector {
if_exists: __self_0, name: __self_1 },
Statement::DropConnector {
if_exists: __arg1_0, name: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::Declare { stmts: __self_0 }, Statement::Declare {
stmts: __arg1_0 }) => __self_0 == __arg1_0,
(Statement::CreateExtension(__self_0),
Statement::CreateExtension(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::DropExtension(__self_0),
Statement::DropExtension(__arg1_0)) => __self_0 == __arg1_0,
(Statement::DropOperator(__self_0),
Statement::DropOperator(__arg1_0)) => __self_0 == __arg1_0,
(Statement::DropOperatorFamily(__self_0),
Statement::DropOperatorFamily(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::DropOperatorClass(__self_0),
Statement::DropOperatorClass(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Fetch {
name: __self_0,
direction: __self_1,
position: __self_2,
into: __self_3 }, Statement::Fetch {
name: __arg1_0,
direction: __arg1_1,
position: __arg1_2,
into: __arg1_3 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3,
(Statement::Flush {
object_type: __self_0,
location: __self_1,
channel: __self_2,
read_lock: __self_3,
export: __self_4,
tables: __self_5 }, Statement::Flush {
object_type: __arg1_0,
location: __arg1_1,
channel: __arg1_2,
read_lock: __arg1_3,
export: __arg1_4,
tables: __arg1_5 }) =>
__self_3 == __arg1_3 && __self_4 == __arg1_4 &&
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_5 == __arg1_5,
(Statement::Discard { object_type: __self_0 },
Statement::Discard { object_type: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::ShowFunctions { filter: __self_0 },
Statement::ShowFunctions { filter: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::ShowVariable { variable: __self_0 },
Statement::ShowVariable { variable: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::ShowStatus {
filter: __self_0, global: __self_1, session: __self_2 },
Statement::ShowStatus {
filter: __arg1_0, global: __arg1_1, session: __arg1_2 }) =>
__self_1 == __arg1_1 && __self_2 == __arg1_2 &&
__self_0 == __arg1_0,
(Statement::ShowVariables {
filter: __self_0, global: __self_1, session: __self_2 },
Statement::ShowVariables {
filter: __arg1_0, global: __arg1_1, session: __arg1_2 }) =>
__self_1 == __arg1_1 && __self_2 == __arg1_2 &&
__self_0 == __arg1_0,
(Statement::ShowCreate {
obj_type: __self_0, obj_name: __self_1 },
Statement::ShowCreate {
obj_type: __arg1_0, obj_name: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::ShowColumns {
extended: __self_0, full: __self_1, show_options: __self_2
}, Statement::ShowColumns {
extended: __arg1_0, full: __arg1_1, show_options: __arg1_2
}) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::ShowDatabases {
terse: __self_0, history: __self_1, show_options: __self_2
}, Statement::ShowDatabases {
terse: __arg1_0, history: __arg1_1, show_options: __arg1_2
}) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::ShowSchemas {
terse: __self_0, history: __self_1, show_options: __self_2
}, Statement::ShowSchemas {
terse: __arg1_0, history: __arg1_1, show_options: __arg1_2
}) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::ShowCharset(__self_0),
Statement::ShowCharset(__arg1_0)) => __self_0 == __arg1_0,
(Statement::ShowObjects(__self_0),
Statement::ShowObjects(__arg1_0)) => __self_0 == __arg1_0,
(Statement::ShowTables {
terse: __self_0,
history: __self_1,
extended: __self_2,
full: __self_3,
external: __self_4,
show_options: __self_5 }, Statement::ShowTables {
terse: __arg1_0,
history: __arg1_1,
extended: __arg1_2,
full: __arg1_3,
external: __arg1_4,
show_options: __arg1_5 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::ShowViews {
terse: __self_0,
materialized: __self_1,
show_options: __self_2 }, Statement::ShowViews {
terse: __arg1_0,
materialized: __arg1_1,
show_options: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::ShowCollation { filter: __self_0 },
Statement::ShowCollation { filter: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::Use(__self_0), Statement::Use(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::StartTransaction {
modes: __self_0,
begin: __self_1,
transaction: __self_2,
modifier: __self_3,
statements: __self_4,
exception: __self_5,
has_end_keyword: __self_6 }, Statement::StartTransaction {
modes: __arg1_0,
begin: __arg1_1,
transaction: __arg1_2,
modifier: __arg1_3,
statements: __arg1_4,
exception: __arg1_5,
has_end_keyword: __arg1_6 }) =>
__self_1 == __arg1_1 && __self_6 == __arg1_6 &&
__self_0 == __arg1_0 && __self_2 == __arg1_2 &&
__self_3 == __arg1_3 && __self_4 == __arg1_4 &&
__self_5 == __arg1_5,
(Statement::Comment {
object_type: __self_0,
object_name: __self_1,
comment: __self_2,
if_exists: __self_3 }, Statement::Comment {
object_type: __arg1_0,
object_name: __arg1_1,
comment: __arg1_2,
if_exists: __arg1_3 }) =>
__self_3 == __arg1_3 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1 && __self_2 == __arg1_2,
(Statement::Commit {
chain: __self_0, end: __self_1, modifier: __self_2 },
Statement::Commit {
chain: __arg1_0, end: __arg1_1, modifier: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::Rollback { chain: __self_0, savepoint: __self_1 },
Statement::Rollback { chain: __arg1_0, savepoint: __arg1_1
}) => __self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::CreateSchema {
schema_name: __self_0,
if_not_exists: __self_1,
with: __self_2,
options: __self_3,
default_collate_spec: __self_4,
clone: __self_5 }, Statement::CreateSchema {
schema_name: __arg1_0,
if_not_exists: __arg1_1,
with: __arg1_2,
options: __arg1_3,
default_collate_spec: __arg1_4,
clone: __arg1_5 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::CreateDatabase {
db_name: __self_0,
if_not_exists: __self_1,
location: __self_2,
managed_location: __self_3,
or_replace: __self_4,
transient: __self_5,
clone: __self_6,
data_retention_time_in_days: __self_7,
max_data_extension_time_in_days: __self_8,
external_volume: __self_9,
catalog: __self_10,
replace_invalid_characters: __self_11,
default_ddl_collation: __self_12,
storage_serialization_policy: __self_13,
comment: __self_14,
default_charset: __self_15,
default_collation: __self_16,
catalog_sync: __self_17,
catalog_sync_namespace_mode: __self_18,
catalog_sync_namespace_flatten_delimiter: __self_19,
with_tags: __self_20,
with_contacts: __self_21 }, Statement::CreateDatabase {
db_name: __arg1_0,
if_not_exists: __arg1_1,
location: __arg1_2,
managed_location: __arg1_3,
or_replace: __arg1_4,
transient: __arg1_5,
clone: __arg1_6,
data_retention_time_in_days: __arg1_7,
max_data_extension_time_in_days: __arg1_8,
external_volume: __arg1_9,
catalog: __arg1_10,
replace_invalid_characters: __arg1_11,
default_ddl_collation: __arg1_12,
storage_serialization_policy: __arg1_13,
comment: __arg1_14,
default_charset: __arg1_15,
default_collation: __arg1_16,
catalog_sync: __arg1_17,
catalog_sync_namespace_mode: __arg1_18,
catalog_sync_namespace_flatten_delimiter: __arg1_19,
with_tags: __arg1_20,
with_contacts: __arg1_21 }) =>
__self_1 == __arg1_1 && __self_4 == __arg1_4 &&
__self_5 == __arg1_5 && __self_0 == __arg1_0 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_6 == __arg1_6 && __self_7 == __arg1_7 &&
__self_8 == __arg1_8 && __self_9 == __arg1_9 &&
__self_10 == __arg1_10 && __self_11 == __arg1_11 &&
__self_12 == __arg1_12 && __self_13 == __arg1_13 &&
__self_14 == __arg1_14 && __self_15 == __arg1_15 &&
__self_16 == __arg1_16 && __self_17 == __arg1_17 &&
__self_18 == __arg1_18 && __self_19 == __arg1_19 &&
__self_20 == __arg1_20 && __self_21 == __arg1_21,
(Statement::CreateFunction(__self_0),
Statement::CreateFunction(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::CreateTrigger(__self_0),
Statement::CreateTrigger(__arg1_0)) => __self_0 == __arg1_0,
(Statement::DropTrigger(__self_0),
Statement::DropTrigger(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateProcedure {
or_alter: __self_0,
name: __self_1,
params: __self_2,
language: __self_3,
body: __self_4 }, Statement::CreateProcedure {
or_alter: __arg1_0,
name: __arg1_1,
params: __arg1_2,
language: __arg1_3,
body: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Statement::CreateMacro {
or_replace: __self_0,
temporary: __self_1,
name: __self_2,
args: __self_3,
definition: __self_4 }, Statement::CreateMacro {
or_replace: __arg1_0,
temporary: __arg1_1,
name: __arg1_2,
args: __arg1_3,
definition: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Statement::CreateStage {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
stage_params: __self_4,
directory_table_params: __self_5,
file_format: __self_6,
copy_options: __self_7,
comment: __self_8 }, Statement::CreateStage {
or_replace: __arg1_0,
temporary: __arg1_1,
if_not_exists: __arg1_2,
name: __arg1_3,
stage_params: __arg1_4,
directory_table_params: __arg1_5,
file_format: __arg1_6,
copy_options: __arg1_7,
comment: __arg1_8 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5 &&
__self_6 == __arg1_6 && __self_7 == __arg1_7 &&
__self_8 == __arg1_8,
(Statement::Assert { condition: __self_0, message: __self_1 },
Statement::Assert { condition: __arg1_0, message: __arg1_1
}) => __self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::Grant(__self_0), Statement::Grant(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Deny(__self_0), Statement::Deny(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Revoke(__self_0), Statement::Revoke(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Deallocate { name: __self_0, prepare: __self_1 },
Statement::Deallocate { name: __arg1_0, prepare: __arg1_1 })
=> __self_1 == __arg1_1 && __self_0 == __arg1_0,
(Statement::Execute {
name: __self_0,
parameters: __self_1,
has_parentheses: __self_2,
immediate: __self_3,
into: __self_4,
using: __self_5,
output: __self_6,
default: __self_7 }, Statement::Execute {
name: __arg1_0,
parameters: __arg1_1,
has_parentheses: __arg1_2,
immediate: __arg1_3,
into: __arg1_4,
using: __arg1_5,
output: __arg1_6,
default: __arg1_7 }) =>
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_6 == __arg1_6 && __self_7 == __arg1_7 &&
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::Prepare {
name: __self_0, data_types: __self_1, statement: __self_2 },
Statement::Prepare {
name: __arg1_0, data_types: __arg1_1, statement: __arg1_2 })
=>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(Statement::Kill { modifier: __self_0, id: __self_1 },
Statement::Kill { modifier: __arg1_0, id: __arg1_1 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
(Statement::ExplainTable {
describe_alias: __self_0,
hive_format: __self_1,
has_table_keyword: __self_2,
table_name: __self_3 }, Statement::ExplainTable {
describe_alias: __arg1_0,
hive_format: __arg1_1,
has_table_keyword: __arg1_2,
table_name: __arg1_3 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1 && __self_3 == __arg1_3,
(Statement::Explain {
describe_alias: __self_0,
analyze: __self_1,
verbose: __self_2,
query_plan: __self_3,
estimate: __self_4,
statement: __self_5,
format: __self_6,
options: __self_7 }, Statement::Explain {
describe_alias: __arg1_0,
analyze: __arg1_1,
verbose: __arg1_2,
query_plan: __arg1_3,
estimate: __arg1_4,
statement: __arg1_5,
format: __arg1_6,
options: __arg1_7 }) =>
__self_1 == __arg1_1 && __self_2 == __arg1_2 &&
__self_3 == __arg1_3 && __self_4 == __arg1_4 &&
__self_0 == __arg1_0 && __self_5 == __arg1_5 &&
__self_6 == __arg1_6 && __self_7 == __arg1_7,
(Statement::Savepoint { name: __self_0 },
Statement::Savepoint { name: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::ReleaseSavepoint { name: __self_0 },
Statement::ReleaseSavepoint { name: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::Merge(__self_0), Statement::Merge(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Cache {
table_flag: __self_0,
table_name: __self_1,
has_as: __self_2,
options: __self_3,
query: __self_4 }, Statement::Cache {
table_flag: __arg1_0,
table_name: __arg1_1,
has_as: __arg1_2,
options: __arg1_3,
query: __arg1_4 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Statement::UNCache {
table_name: __self_0, if_exists: __self_1 },
Statement::UNCache {
table_name: __arg1_0, if_exists: __arg1_1 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
(Statement::CreateSequence {
temporary: __self_0,
if_not_exists: __self_1,
name: __self_2,
data_type: __self_3,
sequence_options: __self_4,
owned_by: __self_5 }, Statement::CreateSequence {
temporary: __arg1_0,
if_not_exists: __arg1_1,
name: __arg1_2,
data_type: __arg1_3,
sequence_options: __arg1_4,
owned_by: __arg1_5 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::CreateDomain(__self_0),
Statement::CreateDomain(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateType {
name: __self_0, representation: __self_1 },
Statement::CreateType {
name: __arg1_0, representation: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::Pragma {
name: __self_0, value: __self_1, is_eq: __self_2 },
Statement::Pragma {
name: __arg1_0, value: __arg1_1, is_eq: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
(Statement::LockTables { tables: __self_0 },
Statement::LockTables { tables: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::Unload {
query: __self_0,
query_text: __self_1,
to: __self_2,
auth: __self_3,
with: __self_4,
options: __self_5 }, Statement::Unload {
query: __arg1_0,
query_text: __arg1_1,
to: __arg1_2,
auth: __arg1_3,
with: __arg1_4,
options: __arg1_5 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::OptimizeTable {
name: __self_0,
on_cluster: __self_1,
partition: __self_2,
include_final: __self_3,
deduplicate: __self_4 }, Statement::OptimizeTable {
name: __arg1_0,
on_cluster: __arg1_1,
partition: __arg1_2,
include_final: __arg1_3,
deduplicate: __arg1_4 }) =>
__self_3 == __arg1_3 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1 && __self_2 == __arg1_2 &&
__self_4 == __arg1_4,
(Statement::LISTEN { channel: __self_0 }, Statement::LISTEN {
channel: __arg1_0 }) => __self_0 == __arg1_0,
(Statement::UNLISTEN { channel: __self_0 },
Statement::UNLISTEN { channel: __arg1_0 }) =>
__self_0 == __arg1_0,
(Statement::NOTIFY { channel: __self_0, payload: __self_1 },
Statement::NOTIFY { channel: __arg1_0, payload: __arg1_1 })
=> __self_0 == __arg1_0 && __self_1 == __arg1_1,
(Statement::LoadData {
local: __self_0,
inpath: __self_1,
overwrite: __self_2,
table_name: __self_3,
partitioned: __self_4,
table_format: __self_5 }, Statement::LoadData {
local: __arg1_0,
inpath: __arg1_1,
overwrite: __arg1_2,
table_name: __arg1_3,
partitioned: __arg1_4,
table_format: __arg1_5 }) =>
__self_0 == __arg1_0 && __self_2 == __arg1_2 &&
__self_1 == __arg1_1 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4 && __self_5 == __arg1_5,
(Statement::RenameTable(__self_0),
Statement::RenameTable(__arg1_0)) => __self_0 == __arg1_0,
(Statement::List(__self_0), Statement::List(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Remove(__self_0), Statement::Remove(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::RaisError {
message: __self_0,
severity: __self_1,
state: __self_2,
arguments: __self_3,
options: __self_4 }, Statement::RaisError {
message: __arg1_0,
severity: __arg1_1,
state: __arg1_2,
arguments: __arg1_3,
options: __arg1_4 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2 && __self_3 == __arg1_3 &&
__self_4 == __arg1_4,
(Statement::Print(__self_0), Statement::Print(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Return(__self_0), Statement::Return(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::ExportData(__self_0),
Statement::ExportData(__arg1_0)) => __self_0 == __arg1_0,
(Statement::CreateUser(__self_0),
Statement::CreateUser(__arg1_0)) => __self_0 == __arg1_0,
(Statement::AlterUser(__self_0),
Statement::AlterUser(__arg1_0)) => __self_0 == __arg1_0,
(Statement::Vacuum(__self_0), Statement::Vacuum(__arg1_0)) =>
__self_0 == __arg1_0,
(Statement::Reset(__self_0), Statement::Reset(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::PartialOrd for Statement {
#[inline]
fn partial_cmp(&self, other: &Statement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::Eq for Statement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Analyze>;
let _: ::core::cmp::AssertParamIsEq<Set>;
let _: ::core::cmp::AssertParamIsEq<Truncate>;
let _: ::core::cmp::AssertParamIsEq<Msck>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<Insert>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<Option<FileFormat>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<CaseStatement>;
let _: ::core::cmp::AssertParamIsEq<IfStatement>;
let _: ::core::cmp::AssertParamIsEq<WhileStatement>;
let _: ::core::cmp::AssertParamIsEq<RaiseStatement>;
let _: ::core::cmp::AssertParamIsEq<Function>;
let _: ::core::cmp::AssertParamIsEq<CopySource>;
let _: ::core::cmp::AssertParamIsEq<CopyTarget>;
let _: ::core::cmp::AssertParamIsEq<Vec<CopyOption>>;
let _: ::core::cmp::AssertParamIsEq<Vec<CopyLegacyOption>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Option<String>>>;
let _: ::core::cmp::AssertParamIsEq<CopyIntoSnowflakeKind>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Ident>>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<StageParamsObject>;
let _:
::core::cmp::AssertParamIsEq<Option<Vec<StageLoadSelectItemKind>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Query>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<String>>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<KeyValueOptions>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<OpenStatement>;
let _: ::core::cmp::AssertParamIsEq<CloseCursor>;
let _: ::core::cmp::AssertParamIsEq<Update>;
let _: ::core::cmp::AssertParamIsEq<Delete>;
let _: ::core::cmp::AssertParamIsEq<CreateView>;
let _: ::core::cmp::AssertParamIsEq<CreateTable>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<CreateIndex>;
let _: ::core::cmp::AssertParamIsEq<CreateRole>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SecretOption>>;
let _: ::core::cmp::AssertParamIsEq<CreateServerStatement>;
let _: ::core::cmp::AssertParamIsEq<CreatePolicy>;
let _: ::core::cmp::AssertParamIsEq<CreateConnector>;
let _: ::core::cmp::AssertParamIsEq<CreateOperator>;
let _: ::core::cmp::AssertParamIsEq<CreateOperatorFamily>;
let _: ::core::cmp::AssertParamIsEq<CreateOperatorClass>;
let _: ::core::cmp::AssertParamIsEq<AlterTable>;
let _: ::core::cmp::AssertParamIsEq<AlterSchema>;
let _: ::core::cmp::AssertParamIsEq<AlterIndexOperation>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<AlterType>;
let _: ::core::cmp::AssertParamIsEq<AlterOperator>;
let _: ::core::cmp::AssertParamIsEq<AlterOperatorFamily>;
let _: ::core::cmp::AssertParamIsEq<AlterOperatorClass>;
let _: ::core::cmp::AssertParamIsEq<AlterRoleOperation>;
let _: ::core::cmp::AssertParamIsEq<AlterPolicy>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<SqlOption>>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<ddl::AlterConnectorOwner>>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<AttachDuckDBDatabaseOption>>;
let _: ::core::cmp::AssertParamIsEq<ObjectType>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<DropFunction>;
let _: ::core::cmp::AssertParamIsEq<DropDomain>;
let _: ::core::cmp::AssertParamIsEq<Vec<FunctionDesc>>;
let _: ::core::cmp::AssertParamIsEq<Option<DropBehavior>>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<DropPolicy>;
let _: ::core::cmp::AssertParamIsEq<Vec<Declare>>;
let _: ::core::cmp::AssertParamIsEq<CreateExtension>;
let _: ::core::cmp::AssertParamIsEq<DropExtension>;
let _: ::core::cmp::AssertParamIsEq<DropOperator>;
let _: ::core::cmp::AssertParamIsEq<DropOperatorFamily>;
let _: ::core::cmp::AssertParamIsEq<DropOperatorClass>;
let _: ::core::cmp::AssertParamIsEq<FetchDirection>;
let _: ::core::cmp::AssertParamIsEq<FetchPosition>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<FlushType>;
let _: ::core::cmp::AssertParamIsEq<Option<FlushLocation>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<DiscardObject>;
let _: ::core::cmp::AssertParamIsEq<Option<ShowStatementFilter>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<ShowStatementFilter>>;
let _: ::core::cmp::AssertParamIsEq<Option<ShowStatementFilter>>;
let _: ::core::cmp::AssertParamIsEq<ShowCreateObject>;
let _: ::core::cmp::AssertParamIsEq<ShowStatementOptions>;
let _: ::core::cmp::AssertParamIsEq<ShowCharset>;
let _: ::core::cmp::AssertParamIsEq<ShowObjects>;
let _: ::core::cmp::AssertParamIsEq<Option<ShowStatementFilter>>;
let _: ::core::cmp::AssertParamIsEq<Use>;
let _: ::core::cmp::AssertParamIsEq<Vec<TransactionMode>>;
let _: ::core::cmp::AssertParamIsEq<Option<BeginTransactionKind>>;
let _: ::core::cmp::AssertParamIsEq<Option<TransactionModifier>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Statement>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<ExceptionWhen>>>;
let _: ::core::cmp::AssertParamIsEq<CommentObject>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<TransactionModifier>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<SchemaName>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<SqlOption>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<SqlOption>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Option<u64>>;
let _: ::core::cmp::AssertParamIsEq<Option<u64>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _:
::core::cmp::AssertParamIsEq<Option<StorageSerializationPolicy>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<CatalogSyncNamespaceMode>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Tag>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<ContactEntry>>>;
let _: ::core::cmp::AssertParamIsEq<CreateFunction>;
let _: ::core::cmp::AssertParamIsEq<CreateTrigger>;
let _: ::core::cmp::AssertParamIsEq<DropTrigger>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<ProcedureParam>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<ConditionalStatements>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<MacroArg>>>;
let _: ::core::cmp::AssertParamIsEq<MacroDefinition>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Grant>;
let _: ::core::cmp::AssertParamIsEq<DenyStatement>;
let _: ::core::cmp::AssertParamIsEq<Revoke>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ExprWithAlias>>;
let _: ::core::cmp::AssertParamIsEq<Vec<DataType>>;
let _: ::core::cmp::AssertParamIsEq<Box<Statement>>;
let _: ::core::cmp::AssertParamIsEq<Option<KillType>>;
let _: ::core::cmp::AssertParamIsEq<u64>;
let _: ::core::cmp::AssertParamIsEq<DescribeAlias>;
let _: ::core::cmp::AssertParamIsEq<Option<HiveDescribeFormat>>;
let _: ::core::cmp::AssertParamIsEq<Box<Statement>>;
let _: ::core::cmp::AssertParamIsEq<Option<AnalyzeFormatKind>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<UtilityOption>>>;
let _: ::core::cmp::AssertParamIsEq<Merge>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Query>>>;
let _: ::core::cmp::AssertParamIsEq<Option<DataType>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SequenceOptions>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<CreateDomain>;
let _:
::core::cmp::AssertParamIsEq<Option<UserDefinedTypeRepresentation>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _: ::core::cmp::AssertParamIsEq<Vec<LockTable>>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Query>>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<IamRoleKind>>;
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<Vec<CopyLegacyOption>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<Partition>>;
let _: ::core::cmp::AssertParamIsEq<Option<Deduplicate>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Option<HiveLoadDataFormat>>;
let _: ::core::cmp::AssertParamIsEq<Vec<RenameTable>>;
let _: ::core::cmp::AssertParamIsEq<FileStagingCommand>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<RaisErrorOption>>;
let _: ::core::cmp::AssertParamIsEq<PrintStatement>;
let _: ::core::cmp::AssertParamIsEq<ReturnStatement>;
let _: ::core::cmp::AssertParamIsEq<ExportData>;
let _: ::core::cmp::AssertParamIsEq<CreateUser>;
let _: ::core::cmp::AssertParamIsEq<AlterUser>;
let _: ::core::cmp::AssertParamIsEq<VacuumStatement>;
let _: ::core::cmp::AssertParamIsEq<ResetStatement>;
}
}Eq, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::Ord for Statement {
#[inline]
fn cmp(&self, other: &Statement) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Statement::Analyze(__self_0), Statement::Analyze(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Set(__self_0), Statement::Set(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Truncate(__self_0),
Statement::Truncate(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Msck(__self_0), Statement::Msck(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Query(__self_0), Statement::Query(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Insert(__self_0), Statement::Insert(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Install { extension_name: __self_0 },
Statement::Install { extension_name: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Load { extension_name: __self_0 },
Statement::Load { extension_name: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Directory {
overwrite: __self_0,
local: __self_1,
path: __self_2,
file_format: __self_3,
source: __self_4 }, Statement::Directory {
overwrite: __arg1_0,
local: __arg1_1,
path: __arg1_2,
file_format: __arg1_3,
source: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Case(__self_0), Statement::Case(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::If(__self_0), Statement::If(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::While(__self_0), Statement::While(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Raise(__self_0), Statement::Raise(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Call(__self_0), Statement::Call(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Copy {
source: __self_0,
to: __self_1,
target: __self_2,
options: __self_3,
legacy_options: __self_4,
values: __self_5 }, Statement::Copy {
source: __arg1_0,
to: __arg1_1,
target: __arg1_2,
options: __arg1_3,
legacy_options: __arg1_4,
values: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CopyIntoSnowflake {
kind: __self_0,
into: __self_1,
into_columns: __self_2,
from_obj: __self_3,
from_obj_alias: __self_4,
stage_params: __self_5,
from_transformations: __self_6,
from_query: __self_7,
files: __self_8,
pattern: __self_9,
file_format: __self_10,
copy_options: __self_11,
validation_mode: __self_12,
partition: __self_13 }, Statement::CopyIntoSnowflake {
kind: __arg1_0,
into: __arg1_1,
into_columns: __arg1_2,
from_obj: __arg1_3,
from_obj_alias: __arg1_4,
stage_params: __arg1_5,
from_transformations: __arg1_6,
from_query: __arg1_7,
files: __arg1_8,
pattern: __arg1_9,
file_format: __arg1_10,
copy_options: __arg1_11,
validation_mode: __arg1_12,
partition: __arg1_13 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_6, __arg1_6) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_7, __arg1_7) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_8, __arg1_8) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_9, __arg1_9) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_10, __arg1_10) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_11, __arg1_11) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_12, __arg1_12) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_13, __arg1_13),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Open(__self_0), Statement::Open(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Close { cursor: __self_0 }, Statement::Close {
cursor: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Update(__self_0), Statement::Update(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Delete(__self_0), Statement::Delete(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateView(__self_0),
Statement::CreateView(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateTable(__self_0),
Statement::CreateTable(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateVirtualTable {
name: __self_0,
if_not_exists: __self_1,
module_name: __self_2,
module_args: __self_3 }, Statement::CreateVirtualTable {
name: __arg1_0,
if_not_exists: __arg1_1,
module_name: __arg1_2,
module_args: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateIndex(__self_0),
Statement::CreateIndex(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateRole(__self_0),
Statement::CreateRole(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateSecret {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
storage_specifier: __self_4,
secret_type: __self_5,
options: __self_6 }, Statement::CreateSecret {
or_replace: __arg1_0,
temporary: __arg1_1,
if_not_exists: __arg1_2,
name: __arg1_3,
storage_specifier: __arg1_4,
secret_type: __arg1_5,
options: __arg1_6 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_6, __arg1_6),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateServer(__self_0),
Statement::CreateServer(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreatePolicy(__self_0),
Statement::CreatePolicy(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateConnector(__self_0),
Statement::CreateConnector(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateOperator(__self_0),
Statement::CreateOperator(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateOperatorFamily(__self_0),
Statement::CreateOperatorFamily(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateOperatorClass(__self_0),
Statement::CreateOperatorClass(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterTable(__self_0),
Statement::AlterTable(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterSchema(__self_0),
Statement::AlterSchema(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterIndex { name: __self_0, operation: __self_1
}, Statement::AlterIndex {
name: __arg1_0, operation: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::AlterView {
name: __self_0,
columns: __self_1,
query: __self_2,
with_options: __self_3 }, Statement::AlterView {
name: __arg1_0,
columns: __arg1_1,
query: __arg1_2,
with_options: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::AlterType(__self_0),
Statement::AlterType(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterOperator(__self_0),
Statement::AlterOperator(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterOperatorFamily(__self_0),
Statement::AlterOperatorFamily(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterOperatorClass(__self_0),
Statement::AlterOperatorClass(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterRole { name: __self_0, operation: __self_1
}, Statement::AlterRole {
name: __arg1_0, operation: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::AlterPolicy(__self_0),
Statement::AlterPolicy(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterConnector {
name: __self_0,
properties: __self_1,
url: __self_2,
owner: __self_3 }, Statement::AlterConnector {
name: __arg1_0,
properties: __arg1_1,
url: __arg1_2,
owner: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::AlterSession {
set: __self_0, session_params: __self_1 },
Statement::AlterSession {
set: __arg1_0, session_params: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::AttachDatabase {
schema_name: __self_0,
database_file_name: __self_1,
database: __self_2 }, Statement::AttachDatabase {
schema_name: __arg1_0,
database_file_name: __arg1_1,
database: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::AttachDuckDBDatabase {
if_not_exists: __self_0,
database: __self_1,
database_path: __self_2,
database_alias: __self_3,
attach_options: __self_4 },
Statement::AttachDuckDBDatabase {
if_not_exists: __arg1_0,
database: __arg1_1,
database_path: __arg1_2,
database_alias: __arg1_3,
attach_options: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::DetachDuckDBDatabase {
if_exists: __self_0,
database: __self_1,
database_alias: __self_2 },
Statement::DetachDuckDBDatabase {
if_exists: __arg1_0,
database: __arg1_1,
database_alias: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::Drop {
object_type: __self_0,
if_exists: __self_1,
names: __self_2,
cascade: __self_3,
restrict: __self_4,
purge: __self_5,
temporary: __self_6,
table: __self_7 }, Statement::Drop {
object_type: __arg1_0,
if_exists: __arg1_1,
names: __arg1_2,
cascade: __arg1_3,
restrict: __arg1_4,
purge: __arg1_5,
temporary: __arg1_6,
table: __arg1_7 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_6, __arg1_6) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_7, __arg1_7),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::DropFunction(__self_0),
Statement::DropFunction(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropDomain(__self_0),
Statement::DropDomain(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropProcedure {
if_exists: __self_0,
proc_desc: __self_1,
drop_behavior: __self_2 }, Statement::DropProcedure {
if_exists: __arg1_0,
proc_desc: __arg1_1,
drop_behavior: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::DropSecret {
if_exists: __self_0,
temporary: __self_1,
name: __self_2,
storage_specifier: __self_3 }, Statement::DropSecret {
if_exists: __arg1_0,
temporary: __arg1_1,
name: __arg1_2,
storage_specifier: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::DropPolicy(__self_0),
Statement::DropPolicy(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropConnector {
if_exists: __self_0, name: __self_1 },
Statement::DropConnector {
if_exists: __arg1_0, name: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::Declare { stmts: __self_0 },
Statement::Declare { stmts: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateExtension(__self_0),
Statement::CreateExtension(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropExtension(__self_0),
Statement::DropExtension(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropOperator(__self_0),
Statement::DropOperator(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropOperatorFamily(__self_0),
Statement::DropOperatorFamily(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropOperatorClass(__self_0),
Statement::DropOperatorClass(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Fetch {
name: __self_0,
direction: __self_1,
position: __self_2,
into: __self_3 }, Statement::Fetch {
name: __arg1_0,
direction: __arg1_1,
position: __arg1_2,
into: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Flush {
object_type: __self_0,
location: __self_1,
channel: __self_2,
read_lock: __self_3,
export: __self_4,
tables: __self_5 }, Statement::Flush {
object_type: __arg1_0,
location: __arg1_1,
channel: __arg1_2,
read_lock: __arg1_3,
export: __arg1_4,
tables: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Discard { object_type: __self_0 },
Statement::Discard { object_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ShowFunctions { filter: __self_0 },
Statement::ShowFunctions { filter: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ShowVariable { variable: __self_0 },
Statement::ShowVariable { variable: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ShowStatus {
filter: __self_0, global: __self_1, session: __self_2 },
Statement::ShowStatus {
filter: __arg1_0, global: __arg1_1, session: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowVariables {
filter: __self_0, global: __self_1, session: __self_2 },
Statement::ShowVariables {
filter: __arg1_0, global: __arg1_1, session: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowCreate {
obj_type: __self_0, obj_name: __self_1 },
Statement::ShowCreate {
obj_type: __arg1_0, obj_name: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::ShowColumns {
extended: __self_0, full: __self_1, show_options: __self_2
}, Statement::ShowColumns {
extended: __arg1_0, full: __arg1_1, show_options: __arg1_2
}) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowDatabases {
terse: __self_0, history: __self_1, show_options: __self_2
}, Statement::ShowDatabases {
terse: __arg1_0, history: __arg1_1, show_options: __arg1_2
}) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowSchemas {
terse: __self_0, history: __self_1, show_options: __self_2
}, Statement::ShowSchemas {
terse: __arg1_0, history: __arg1_1, show_options: __arg1_2
}) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowCharset(__self_0),
Statement::ShowCharset(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ShowObjects(__self_0),
Statement::ShowObjects(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ShowTables {
terse: __self_0,
history: __self_1,
extended: __self_2,
full: __self_3,
external: __self_4,
show_options: __self_5 }, Statement::ShowTables {
terse: __arg1_0,
history: __arg1_1,
extended: __arg1_2,
full: __arg1_3,
external: __arg1_4,
show_options: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowViews {
terse: __self_0,
materialized: __self_1,
show_options: __self_2 }, Statement::ShowViews {
terse: __arg1_0,
materialized: __arg1_1,
show_options: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::ShowCollation { filter: __self_0 },
Statement::ShowCollation { filter: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Use(__self_0), Statement::Use(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::StartTransaction {
modes: __self_0,
begin: __self_1,
transaction: __self_2,
modifier: __self_3,
statements: __self_4,
exception: __self_5,
has_end_keyword: __self_6 }, Statement::StartTransaction {
modes: __arg1_0,
begin: __arg1_1,
transaction: __arg1_2,
modifier: __arg1_3,
statements: __arg1_4,
exception: __arg1_5,
has_end_keyword: __arg1_6 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_6, __arg1_6),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Comment {
object_type: __self_0,
object_name: __self_1,
comment: __self_2,
if_exists: __self_3 }, Statement::Comment {
object_type: __arg1_0,
object_name: __arg1_1,
comment: __arg1_2,
if_exists: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Commit {
chain: __self_0, end: __self_1, modifier: __self_2 },
Statement::Commit {
chain: __arg1_0, end: __arg1_1, modifier: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::Rollback { chain: __self_0, savepoint: __self_1
}, Statement::Rollback {
chain: __arg1_0, savepoint: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::CreateSchema {
schema_name: __self_0,
if_not_exists: __self_1,
with: __self_2,
options: __self_3,
default_collate_spec: __self_4,
clone: __self_5 }, Statement::CreateSchema {
schema_name: __arg1_0,
if_not_exists: __arg1_1,
with: __arg1_2,
options: __arg1_3,
default_collate_spec: __arg1_4,
clone: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateDatabase {
db_name: __self_0,
if_not_exists: __self_1,
location: __self_2,
managed_location: __self_3,
or_replace: __self_4,
transient: __self_5,
clone: __self_6,
data_retention_time_in_days: __self_7,
max_data_extension_time_in_days: __self_8,
external_volume: __self_9,
catalog: __self_10,
replace_invalid_characters: __self_11,
default_ddl_collation: __self_12,
storage_serialization_policy: __self_13,
comment: __self_14,
default_charset: __self_15,
default_collation: __self_16,
catalog_sync: __self_17,
catalog_sync_namespace_mode: __self_18,
catalog_sync_namespace_flatten_delimiter: __self_19,
with_tags: __self_20,
with_contacts: __self_21 }, Statement::CreateDatabase {
db_name: __arg1_0,
if_not_exists: __arg1_1,
location: __arg1_2,
managed_location: __arg1_3,
or_replace: __arg1_4,
transient: __arg1_5,
clone: __arg1_6,
data_retention_time_in_days: __arg1_7,
max_data_extension_time_in_days: __arg1_8,
external_volume: __arg1_9,
catalog: __arg1_10,
replace_invalid_characters: __arg1_11,
default_ddl_collation: __arg1_12,
storage_serialization_policy: __arg1_13,
comment: __arg1_14,
default_charset: __arg1_15,
default_collation: __arg1_16,
catalog_sync: __arg1_17,
catalog_sync_namespace_mode: __arg1_18,
catalog_sync_namespace_flatten_delimiter: __arg1_19,
with_tags: __arg1_20,
with_contacts: __arg1_21 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_6, __arg1_6) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_7, __arg1_7) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_8, __arg1_8) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_9, __arg1_9) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_10, __arg1_10) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_11, __arg1_11) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_12, __arg1_12) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_13, __arg1_13) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_14, __arg1_14) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_15, __arg1_15) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_16, __arg1_16) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_17, __arg1_17) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_18, __arg1_18) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_19, __arg1_19) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_20, __arg1_20) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_21, __arg1_21),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateFunction(__self_0),
Statement::CreateFunction(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateTrigger(__self_0),
Statement::CreateTrigger(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::DropTrigger(__self_0),
Statement::DropTrigger(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateProcedure {
or_alter: __self_0,
name: __self_1,
params: __self_2,
language: __self_3,
body: __self_4 }, Statement::CreateProcedure {
or_alter: __arg1_0,
name: __arg1_1,
params: __arg1_2,
language: __arg1_3,
body: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateMacro {
or_replace: __self_0,
temporary: __self_1,
name: __self_2,
args: __self_3,
definition: __self_4 }, Statement::CreateMacro {
or_replace: __arg1_0,
temporary: __arg1_1,
name: __arg1_2,
args: __arg1_3,
definition: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateStage {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
stage_params: __self_4,
directory_table_params: __self_5,
file_format: __self_6,
copy_options: __self_7,
comment: __self_8 }, Statement::CreateStage {
or_replace: __arg1_0,
temporary: __arg1_1,
if_not_exists: __arg1_2,
name: __arg1_3,
stage_params: __arg1_4,
directory_table_params: __arg1_5,
file_format: __arg1_6,
copy_options: __arg1_7,
comment: __arg1_8 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_6, __arg1_6) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_7, __arg1_7) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_8, __arg1_8),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Assert { condition: __self_0, message: __self_1
}, Statement::Assert {
condition: __arg1_0, message: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::Grant(__self_0), Statement::Grant(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Deny(__self_0), Statement::Deny(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Revoke(__self_0), Statement::Revoke(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Deallocate { name: __self_0, prepare: __self_1
}, Statement::Deallocate { name: __arg1_0, prepare: __arg1_1
}) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::Execute {
name: __self_0,
parameters: __self_1,
has_parentheses: __self_2,
immediate: __self_3,
into: __self_4,
using: __self_5,
output: __self_6,
default: __self_7 }, Statement::Execute {
name: __arg1_0,
parameters: __arg1_1,
has_parentheses: __arg1_2,
immediate: __arg1_3,
into: __arg1_4,
using: __arg1_5,
output: __arg1_6,
default: __arg1_7 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_6, __arg1_6) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_7, __arg1_7),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Prepare {
name: __self_0, data_types: __self_1, statement: __self_2 },
Statement::Prepare {
name: __arg1_0, data_types: __arg1_1, statement: __arg1_2 })
=>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::Kill { modifier: __self_0, id: __self_1 },
Statement::Kill { modifier: __arg1_0, id: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::ExplainTable {
describe_alias: __self_0,
hive_format: __self_1,
has_table_keyword: __self_2,
table_name: __self_3 }, Statement::ExplainTable {
describe_alias: __arg1_0,
hive_format: __arg1_1,
has_table_keyword: __arg1_2,
table_name: __arg1_3 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_3, __arg1_3),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Explain {
describe_alias: __self_0,
analyze: __self_1,
verbose: __self_2,
query_plan: __self_3,
estimate: __self_4,
statement: __self_5,
format: __self_6,
options: __self_7 }, Statement::Explain {
describe_alias: __arg1_0,
analyze: __arg1_1,
verbose: __arg1_2,
query_plan: __arg1_3,
estimate: __arg1_4,
statement: __arg1_5,
format: __arg1_6,
options: __arg1_7 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_5, __arg1_5) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_6, __arg1_6) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_7, __arg1_7),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Savepoint { name: __self_0 },
Statement::Savepoint { name: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ReleaseSavepoint { name: __self_0 },
Statement::ReleaseSavepoint { name: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Merge(__self_0), Statement::Merge(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Cache {
table_flag: __self_0,
table_name: __self_1,
has_as: __self_2,
options: __self_3,
query: __self_4 }, Statement::Cache {
table_flag: __arg1_0,
table_name: __arg1_1,
has_as: __arg1_2,
options: __arg1_3,
query: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::UNCache {
table_name: __self_0, if_exists: __self_1 },
Statement::UNCache {
table_name: __arg1_0, if_exists: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::CreateSequence {
temporary: __self_0,
if_not_exists: __self_1,
name: __self_2,
data_type: __self_3,
sequence_options: __self_4,
owned_by: __self_5 }, Statement::CreateSequence {
temporary: __arg1_0,
if_not_exists: __arg1_1,
name: __arg1_2,
data_type: __arg1_3,
sequence_options: __arg1_4,
owned_by: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::CreateDomain(__self_0),
Statement::CreateDomain(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateType {
name: __self_0, representation: __self_1 },
Statement::CreateType {
name: __arg1_0, representation: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::Pragma {
name: __self_0, value: __self_1, is_eq: __self_2 },
Statement::Pragma {
name: __arg1_0, value: __arg1_1, is_eq: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(Statement::LockTables { tables: __self_0 },
Statement::LockTables { tables: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Unload {
query: __self_0,
query_text: __self_1,
to: __self_2,
auth: __self_3,
with: __self_4,
options: __self_5 }, Statement::Unload {
query: __arg1_0,
query_text: __arg1_1,
to: __arg1_2,
auth: __arg1_3,
with: __arg1_4,
options: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::OptimizeTable {
name: __self_0,
on_cluster: __self_1,
partition: __self_2,
include_final: __self_3,
deduplicate: __self_4 }, Statement::OptimizeTable {
name: __arg1_0,
on_cluster: __arg1_1,
partition: __arg1_2,
include_final: __arg1_3,
deduplicate: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::LISTEN { channel: __self_0 },
Statement::LISTEN { channel: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::UNLISTEN { channel: __self_0 },
Statement::UNLISTEN { channel: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::NOTIFY { channel: __self_0, payload: __self_1 },
Statement::NOTIFY { channel: __arg1_0, payload: __arg1_1 })
=>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(Statement::LoadData {
local: __self_0,
inpath: __self_1,
overwrite: __self_2,
table_name: __self_3,
partitioned: __self_4,
table_format: __self_5 }, Statement::LoadData {
local: __arg1_0,
inpath: __arg1_1,
overwrite: __arg1_2,
table_name: __arg1_3,
partitioned: __arg1_4,
table_format: __arg1_5 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_4, __arg1_4) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_5, __arg1_5),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::RenameTable(__self_0),
Statement::RenameTable(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::List(__self_0), Statement::List(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Remove(__self_0), Statement::Remove(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::RaisError {
message: __self_0,
severity: __self_1,
state: __self_2,
arguments: __self_3,
options: __self_4 }, Statement::RaisError {
message: __arg1_0,
severity: __arg1_1,
state: __arg1_2,
arguments: __arg1_3,
options: __arg1_4 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_2, __arg1_2) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_3, __arg1_3) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_4, __arg1_4),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
(Statement::Print(__self_0), Statement::Print(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Return(__self_0), Statement::Return(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::ExportData(__self_0),
Statement::ExportData(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::CreateUser(__self_0),
Statement::CreateUser(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::AlterUser(__self_0),
Statement::AlterUser(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Vacuum(__self_0), Statement::Vacuum(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Statement::Reset(__self_0), Statement::Reset(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::hash::Hash for Statement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Statement::Analyze(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Set(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Truncate(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Msck(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Query(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Insert(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Install { extension_name: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::Load { extension_name: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::Directory {
overwrite: __self_0,
local: __self_1,
path: __self_2,
file_format: __self_3,
source: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::Case(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::If(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::While(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Raise(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Call(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Copy {
source: __self_0,
to: __self_1,
target: __self_2,
options: __self_3,
legacy_options: __self_4,
values: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::CopyIntoSnowflake {
kind: __self_0,
into: __self_1,
into_columns: __self_2,
from_obj: __self_3,
from_obj_alias: __self_4,
stage_params: __self_5,
from_transformations: __self_6,
from_query: __self_7,
files: __self_8,
pattern: __self_9,
file_format: __self_10,
copy_options: __self_11,
validation_mode: __self_12,
partition: __self_13 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state);
::core::hash::Hash::hash(__self_7, state);
::core::hash::Hash::hash(__self_8, state);
::core::hash::Hash::hash(__self_9, state);
::core::hash::Hash::hash(__self_10, state);
::core::hash::Hash::hash(__self_11, state);
::core::hash::Hash::hash(__self_12, state);
::core::hash::Hash::hash(__self_13, state)
}
Statement::Open(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Close { cursor: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::Update(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Delete(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateView(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateTable(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateVirtualTable {
name: __self_0,
if_not_exists: __self_1,
module_name: __self_2,
module_args: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::CreateIndex(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateRole(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateSecret {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
storage_specifier: __self_4,
secret_type: __self_5,
options: __self_6 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state)
}
Statement::CreateServer(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreatePolicy(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateConnector(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateOperator(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateOperatorFamily(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateOperatorClass(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterTable(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterSchema(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterIndex { name: __self_0, operation: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::AlterView {
name: __self_0,
columns: __self_1,
query: __self_2,
with_options: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::AlterType(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterOperator(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterOperatorFamily(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterOperatorClass(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterRole { name: __self_0, operation: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::AlterPolicy(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterConnector {
name: __self_0,
properties: __self_1,
url: __self_2,
owner: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::AlterSession { set: __self_0, session_params: __self_1
} => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::AttachDatabase {
schema_name: __self_0,
database_file_name: __self_1,
database: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::AttachDuckDBDatabase {
if_not_exists: __self_0,
database: __self_1,
database_path: __self_2,
database_alias: __self_3,
attach_options: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::DetachDuckDBDatabase {
if_exists: __self_0,
database: __self_1,
database_alias: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::Drop {
object_type: __self_0,
if_exists: __self_1,
names: __self_2,
cascade: __self_3,
restrict: __self_4,
purge: __self_5,
temporary: __self_6,
table: __self_7 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state);
::core::hash::Hash::hash(__self_7, state)
}
Statement::DropFunction(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropDomain(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropProcedure {
if_exists: __self_0,
proc_desc: __self_1,
drop_behavior: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::DropSecret {
if_exists: __self_0,
temporary: __self_1,
name: __self_2,
storage_specifier: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::DropPolicy(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropConnector { if_exists: __self_0, name: __self_1 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::Declare { stmts: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateExtension(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropExtension(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropOperator(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropOperatorFamily(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropOperatorClass(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Fetch {
name: __self_0,
direction: __self_1,
position: __self_2,
into: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::Flush {
object_type: __self_0,
location: __self_1,
channel: __self_2,
read_lock: __self_3,
export: __self_4,
tables: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::Discard { object_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::ShowFunctions { filter: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::ShowVariable { variable: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::ShowStatus {
filter: __self_0, global: __self_1, session: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::ShowVariables {
filter: __self_0, global: __self_1, session: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::ShowCreate { obj_type: __self_0, obj_name: __self_1 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::ShowColumns {
extended: __self_0, full: __self_1, show_options: __self_2 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::ShowDatabases {
terse: __self_0, history: __self_1, show_options: __self_2 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::ShowSchemas {
terse: __self_0, history: __self_1, show_options: __self_2 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::ShowCharset(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::ShowObjects(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::ShowTables {
terse: __self_0,
history: __self_1,
extended: __self_2,
full: __self_3,
external: __self_4,
show_options: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::ShowViews {
terse: __self_0,
materialized: __self_1,
show_options: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::ShowCollation { filter: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::Use(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::StartTransaction {
modes: __self_0,
begin: __self_1,
transaction: __self_2,
modifier: __self_3,
statements: __self_4,
exception: __self_5,
has_end_keyword: __self_6 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state)
}
Statement::Comment {
object_type: __self_0,
object_name: __self_1,
comment: __self_2,
if_exists: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::Commit {
chain: __self_0, end: __self_1, modifier: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::Rollback { chain: __self_0, savepoint: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::CreateSchema {
schema_name: __self_0,
if_not_exists: __self_1,
with: __self_2,
options: __self_3,
default_collate_spec: __self_4,
clone: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::CreateDatabase {
db_name: __self_0,
if_not_exists: __self_1,
location: __self_2,
managed_location: __self_3,
or_replace: __self_4,
transient: __self_5,
clone: __self_6,
data_retention_time_in_days: __self_7,
max_data_extension_time_in_days: __self_8,
external_volume: __self_9,
catalog: __self_10,
replace_invalid_characters: __self_11,
default_ddl_collation: __self_12,
storage_serialization_policy: __self_13,
comment: __self_14,
default_charset: __self_15,
default_collation: __self_16,
catalog_sync: __self_17,
catalog_sync_namespace_mode: __self_18,
catalog_sync_namespace_flatten_delimiter: __self_19,
with_tags: __self_20,
with_contacts: __self_21 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state);
::core::hash::Hash::hash(__self_7, state);
::core::hash::Hash::hash(__self_8, state);
::core::hash::Hash::hash(__self_9, state);
::core::hash::Hash::hash(__self_10, state);
::core::hash::Hash::hash(__self_11, state);
::core::hash::Hash::hash(__self_12, state);
::core::hash::Hash::hash(__self_13, state);
::core::hash::Hash::hash(__self_14, state);
::core::hash::Hash::hash(__self_15, state);
::core::hash::Hash::hash(__self_16, state);
::core::hash::Hash::hash(__self_17, state);
::core::hash::Hash::hash(__self_18, state);
::core::hash::Hash::hash(__self_19, state);
::core::hash::Hash::hash(__self_20, state);
::core::hash::Hash::hash(__self_21, state)
}
Statement::CreateFunction(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateTrigger(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::DropTrigger(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateProcedure {
or_alter: __self_0,
name: __self_1,
params: __self_2,
language: __self_3,
body: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::CreateMacro {
or_replace: __self_0,
temporary: __self_1,
name: __self_2,
args: __self_3,
definition: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::CreateStage {
or_replace: __self_0,
temporary: __self_1,
if_not_exists: __self_2,
name: __self_3,
stage_params: __self_4,
directory_table_params: __self_5,
file_format: __self_6,
copy_options: __self_7,
comment: __self_8 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state);
::core::hash::Hash::hash(__self_7, state);
::core::hash::Hash::hash(__self_8, state)
}
Statement::Assert { condition: __self_0, message: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::Grant(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Deny(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Revoke(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Deallocate { name: __self_0, prepare: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::Execute {
name: __self_0,
parameters: __self_1,
has_parentheses: __self_2,
immediate: __self_3,
into: __self_4,
using: __self_5,
output: __self_6,
default: __self_7 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state);
::core::hash::Hash::hash(__self_7, state)
}
Statement::Prepare {
name: __self_0, data_types: __self_1, statement: __self_2 } =>
{
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::Kill { modifier: __self_0, id: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::ExplainTable {
describe_alias: __self_0,
hive_format: __self_1,
has_table_keyword: __self_2,
table_name: __self_3 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state)
}
Statement::Explain {
describe_alias: __self_0,
analyze: __self_1,
verbose: __self_2,
query_plan: __self_3,
estimate: __self_4,
statement: __self_5,
format: __self_6,
options: __self_7 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state);
::core::hash::Hash::hash(__self_6, state);
::core::hash::Hash::hash(__self_7, state)
}
Statement::Savepoint { name: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::ReleaseSavepoint { name: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::Merge(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Cache {
table_flag: __self_0,
table_name: __self_1,
has_as: __self_2,
options: __self_3,
query: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::UNCache { table_name: __self_0, if_exists: __self_1 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::CreateSequence {
temporary: __self_0,
if_not_exists: __self_1,
name: __self_2,
data_type: __self_3,
sequence_options: __self_4,
owned_by: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::CreateDomain(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateType { name: __self_0, representation: __self_1 }
=> {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::Pragma {
name: __self_0, value: __self_1, is_eq: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
Statement::LockTables { tables: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::Unload {
query: __self_0,
query_text: __self_1,
to: __self_2,
auth: __self_3,
with: __self_4,
options: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::OptimizeTable {
name: __self_0,
on_cluster: __self_1,
partition: __self_2,
include_final: __self_3,
deduplicate: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::LISTEN { channel: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::UNLISTEN { channel: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Statement::NOTIFY { channel: __self_0, payload: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
Statement::LoadData {
local: __self_0,
inpath: __self_1,
overwrite: __self_2,
table_name: __self_3,
partitioned: __self_4,
table_format: __self_5 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state);
::core::hash::Hash::hash(__self_5, state)
}
Statement::RenameTable(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::List(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Remove(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::RaisError {
message: __self_0,
severity: __self_1,
state: __self_2,
arguments: __self_3,
options: __self_4 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state);
::core::hash::Hash::hash(__self_3, state);
::core::hash::Hash::hash(__self_4, state)
}
Statement::Print(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Return(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::ExportData(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::CreateUser(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::AlterUser(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Vacuum(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
Statement::Reset(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
3397#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
3398#[cfg_attr(
3399 feature = "visitor",
3400 derive(impl sqlparser::ast::Visit for Statement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
visitor.pre_visit_statement(self)?;
match self {
Self::Analyze(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Set(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Truncate(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Msck(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Query(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Insert(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Install { extension_name } => {
sqlparser::ast::Visit::visit(extension_name, visitor)?;
}
Self::Load { extension_name } => {
sqlparser::ast::Visit::visit(extension_name, visitor)?;
}
Self::Directory {
overwrite, local, path, file_format, source } => {
sqlparser::ast::Visit::visit(overwrite, visitor)?;
sqlparser::ast::Visit::visit(local, visitor)?;
sqlparser::ast::Visit::visit(path, visitor)?;
sqlparser::ast::Visit::visit(file_format, visitor)?;
sqlparser::ast::Visit::visit(source, visitor)?;
}
Self::Case(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::If(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::While(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Raise(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Call(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Copy {
source, to, target, options, legacy_options, values } => {
sqlparser::ast::Visit::visit(source, visitor)?;
sqlparser::ast::Visit::visit(to, visitor)?;
sqlparser::ast::Visit::visit(target, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
sqlparser::ast::Visit::visit(legacy_options, visitor)?;
sqlparser::ast::Visit::visit(values, visitor)?;
}
Self::CopyIntoSnowflake {
kind,
into,
into_columns,
from_obj,
from_obj_alias,
stage_params,
from_transformations,
from_query,
files,
pattern,
file_format,
copy_options,
validation_mode,
partition } => {
sqlparser::ast::Visit::visit(kind, visitor)?;
sqlparser::ast::Visit::visit(into, visitor)?;
sqlparser::ast::Visit::visit(into_columns, visitor)?;
sqlparser::ast::Visit::visit(from_obj, visitor)?;
sqlparser::ast::Visit::visit(from_obj_alias, visitor)?;
sqlparser::ast::Visit::visit(stage_params, visitor)?;
sqlparser::ast::Visit::visit(from_transformations,
visitor)?;
sqlparser::ast::Visit::visit(from_query, visitor)?;
sqlparser::ast::Visit::visit(files, visitor)?;
sqlparser::ast::Visit::visit(pattern, visitor)?;
sqlparser::ast::Visit::visit(file_format, visitor)?;
sqlparser::ast::Visit::visit(copy_options, visitor)?;
sqlparser::ast::Visit::visit(validation_mode, visitor)?;
sqlparser::ast::Visit::visit(partition, visitor)?;
}
Self::Open(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Close { cursor } => {
sqlparser::ast::Visit::visit(cursor, visitor)?;
}
Self::Update(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Delete(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateView(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateTable(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateVirtualTable {
name, if_not_exists, module_name, module_args } => {
visitor.pre_visit_relation(name)?;
sqlparser::ast::Visit::visit(name, visitor)?;
visitor.post_visit_relation(name)?;
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(module_name, visitor)?;
sqlparser::ast::Visit::visit(module_args, visitor)?;
}
Self::CreateIndex(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateRole(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateSecret {
or_replace,
temporary,
if_not_exists,
name,
storage_specifier,
secret_type,
options } => {
sqlparser::ast::Visit::visit(or_replace, visitor)?;
sqlparser::ast::Visit::visit(temporary, visitor)?;
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(storage_specifier, visitor)?;
sqlparser::ast::Visit::visit(secret_type, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
}
Self::CreateServer(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreatePolicy(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateConnector(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateOperator(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateOperatorFamily(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateOperatorClass(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterTable(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterSchema(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterIndex { name, operation } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(operation, visitor)?;
}
Self::AlterView { name, columns, query, with_options } => {
visitor.pre_visit_relation(name)?;
sqlparser::ast::Visit::visit(name, visitor)?;
visitor.post_visit_relation(name)?;
sqlparser::ast::Visit::visit(columns, visitor)?;
sqlparser::ast::Visit::visit(query, visitor)?;
sqlparser::ast::Visit::visit(with_options, visitor)?;
}
Self::AlterType(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterOperator(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterOperatorFamily(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterOperatorClass(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterRole { name, operation } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(operation, visitor)?;
}
Self::AlterPolicy(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterConnector { name, properties, url, owner } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(properties, visitor)?;
sqlparser::ast::Visit::visit(url, visitor)?;
sqlparser::ast::Visit::visit(owner, visitor)?;
}
Self::AlterSession { set, session_params } => {
sqlparser::ast::Visit::visit(set, visitor)?;
sqlparser::ast::Visit::visit(session_params, visitor)?;
}
Self::AttachDatabase {
schema_name, database_file_name, database } => {
sqlparser::ast::Visit::visit(schema_name, visitor)?;
sqlparser::ast::Visit::visit(database_file_name, visitor)?;
sqlparser::ast::Visit::visit(database, visitor)?;
}
Self::AttachDuckDBDatabase {
if_not_exists,
database,
database_path,
database_alias,
attach_options } => {
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(database, visitor)?;
sqlparser::ast::Visit::visit(database_path, visitor)?;
sqlparser::ast::Visit::visit(database_alias, visitor)?;
sqlparser::ast::Visit::visit(attach_options, visitor)?;
}
Self::DetachDuckDBDatabase {
if_exists, database, database_alias } => {
sqlparser::ast::Visit::visit(if_exists, visitor)?;
sqlparser::ast::Visit::visit(database, visitor)?;
sqlparser::ast::Visit::visit(database_alias, visitor)?;
}
Self::Drop {
object_type,
if_exists,
names,
cascade,
restrict,
purge,
temporary,
table } => {
sqlparser::ast::Visit::visit(object_type, visitor)?;
sqlparser::ast::Visit::visit(if_exists, visitor)?;
sqlparser::ast::Visit::visit(names, visitor)?;
sqlparser::ast::Visit::visit(cascade, visitor)?;
sqlparser::ast::Visit::visit(restrict, visitor)?;
sqlparser::ast::Visit::visit(purge, visitor)?;
sqlparser::ast::Visit::visit(temporary, visitor)?;
sqlparser::ast::Visit::visit(table, visitor)?;
}
Self::DropFunction(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropDomain(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropProcedure { if_exists, proc_desc, drop_behavior }
=> {
sqlparser::ast::Visit::visit(if_exists, visitor)?;
sqlparser::ast::Visit::visit(proc_desc, visitor)?;
sqlparser::ast::Visit::visit(drop_behavior, visitor)?;
}
Self::DropSecret {
if_exists, temporary, name, storage_specifier } => {
sqlparser::ast::Visit::visit(if_exists, visitor)?;
sqlparser::ast::Visit::visit(temporary, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(storage_specifier, visitor)?;
}
Self::DropPolicy(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropConnector { if_exists, name } => {
sqlparser::ast::Visit::visit(if_exists, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
}
Self::Declare { stmts } => {
sqlparser::ast::Visit::visit(stmts, visitor)?;
}
Self::CreateExtension(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropExtension(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropOperator(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropOperatorFamily(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropOperatorClass(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Fetch { name, direction, position, into } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(direction, visitor)?;
sqlparser::ast::Visit::visit(position, visitor)?;
sqlparser::ast::Visit::visit(into, visitor)?;
}
Self::Flush {
object_type, location, channel, read_lock, export, tables }
=> {
sqlparser::ast::Visit::visit(object_type, visitor)?;
sqlparser::ast::Visit::visit(location, visitor)?;
sqlparser::ast::Visit::visit(channel, visitor)?;
sqlparser::ast::Visit::visit(read_lock, visitor)?;
sqlparser::ast::Visit::visit(export, visitor)?;
sqlparser::ast::Visit::visit(tables, visitor)?;
}
Self::Discard { object_type } => {
sqlparser::ast::Visit::visit(object_type, visitor)?;
}
Self::ShowFunctions { filter } => {
sqlparser::ast::Visit::visit(filter, visitor)?;
}
Self::ShowVariable { variable } => {
sqlparser::ast::Visit::visit(variable, visitor)?;
}
Self::ShowStatus { filter, global, session } => {
sqlparser::ast::Visit::visit(filter, visitor)?;
sqlparser::ast::Visit::visit(global, visitor)?;
sqlparser::ast::Visit::visit(session, visitor)?;
}
Self::ShowVariables { filter, global, session } => {
sqlparser::ast::Visit::visit(filter, visitor)?;
sqlparser::ast::Visit::visit(global, visitor)?;
sqlparser::ast::Visit::visit(session, visitor)?;
}
Self::ShowCreate { obj_type, obj_name } => {
sqlparser::ast::Visit::visit(obj_type, visitor)?;
sqlparser::ast::Visit::visit(obj_name, visitor)?;
}
Self::ShowColumns { extended, full, show_options } => {
sqlparser::ast::Visit::visit(extended, visitor)?;
sqlparser::ast::Visit::visit(full, visitor)?;
sqlparser::ast::Visit::visit(show_options, visitor)?;
}
Self::ShowDatabases { terse, history, show_options } => {
sqlparser::ast::Visit::visit(terse, visitor)?;
sqlparser::ast::Visit::visit(history, visitor)?;
sqlparser::ast::Visit::visit(show_options, visitor)?;
}
Self::ShowSchemas { terse, history, show_options } => {
sqlparser::ast::Visit::visit(terse, visitor)?;
sqlparser::ast::Visit::visit(history, visitor)?;
sqlparser::ast::Visit::visit(show_options, visitor)?;
}
Self::ShowCharset(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ShowObjects(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ShowTables {
terse, history, extended, full, external, show_options } =>
{
sqlparser::ast::Visit::visit(terse, visitor)?;
sqlparser::ast::Visit::visit(history, visitor)?;
sqlparser::ast::Visit::visit(extended, visitor)?;
sqlparser::ast::Visit::visit(full, visitor)?;
sqlparser::ast::Visit::visit(external, visitor)?;
sqlparser::ast::Visit::visit(show_options, visitor)?;
}
Self::ShowViews { terse, materialized, show_options } => {
sqlparser::ast::Visit::visit(terse, visitor)?;
sqlparser::ast::Visit::visit(materialized, visitor)?;
sqlparser::ast::Visit::visit(show_options, visitor)?;
}
Self::ShowCollation { filter } => {
sqlparser::ast::Visit::visit(filter, visitor)?;
}
Self::Use(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::StartTransaction {
modes,
begin,
transaction,
modifier,
statements,
exception,
has_end_keyword } => {
sqlparser::ast::Visit::visit(modes, visitor)?;
sqlparser::ast::Visit::visit(begin, visitor)?;
sqlparser::ast::Visit::visit(transaction, visitor)?;
sqlparser::ast::Visit::visit(modifier, visitor)?;
sqlparser::ast::Visit::visit(statements, visitor)?;
sqlparser::ast::Visit::visit(exception, visitor)?;
sqlparser::ast::Visit::visit(has_end_keyword, visitor)?;
}
Self::Comment { object_type, object_name, comment, if_exists
} => {
sqlparser::ast::Visit::visit(object_type, visitor)?;
sqlparser::ast::Visit::visit(object_name, visitor)?;
sqlparser::ast::Visit::visit(comment, visitor)?;
sqlparser::ast::Visit::visit(if_exists, visitor)?;
}
Self::Commit { chain, end, modifier } => {
sqlparser::ast::Visit::visit(chain, visitor)?;
sqlparser::ast::Visit::visit(end, visitor)?;
sqlparser::ast::Visit::visit(modifier, visitor)?;
}
Self::Rollback { chain, savepoint } => {
sqlparser::ast::Visit::visit(chain, visitor)?;
sqlparser::ast::Visit::visit(savepoint, visitor)?;
}
Self::CreateSchema {
schema_name,
if_not_exists,
with,
options,
default_collate_spec,
clone } => {
sqlparser::ast::Visit::visit(schema_name, visitor)?;
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(with, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
sqlparser::ast::Visit::visit(default_collate_spec,
visitor)?;
sqlparser::ast::Visit::visit(clone, visitor)?;
}
Self::CreateDatabase {
db_name,
if_not_exists,
location,
managed_location,
or_replace,
transient,
clone,
data_retention_time_in_days,
max_data_extension_time_in_days,
external_volume,
catalog,
replace_invalid_characters,
default_ddl_collation,
storage_serialization_policy,
comment,
default_charset,
default_collation,
catalog_sync,
catalog_sync_namespace_mode,
catalog_sync_namespace_flatten_delimiter,
with_tags,
with_contacts } => {
sqlparser::ast::Visit::visit(db_name, visitor)?;
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(location, visitor)?;
sqlparser::ast::Visit::visit(managed_location, visitor)?;
sqlparser::ast::Visit::visit(or_replace, visitor)?;
sqlparser::ast::Visit::visit(transient, visitor)?;
sqlparser::ast::Visit::visit(clone, visitor)?;
sqlparser::ast::Visit::visit(data_retention_time_in_days,
visitor)?;
sqlparser::ast::Visit::visit(max_data_extension_time_in_days,
visitor)?;
sqlparser::ast::Visit::visit(external_volume, visitor)?;
sqlparser::ast::Visit::visit(catalog, visitor)?;
sqlparser::ast::Visit::visit(replace_invalid_characters,
visitor)?;
sqlparser::ast::Visit::visit(default_ddl_collation,
visitor)?;
sqlparser::ast::Visit::visit(storage_serialization_policy,
visitor)?;
sqlparser::ast::Visit::visit(comment, visitor)?;
sqlparser::ast::Visit::visit(default_charset, visitor)?;
sqlparser::ast::Visit::visit(default_collation, visitor)?;
sqlparser::ast::Visit::visit(catalog_sync, visitor)?;
sqlparser::ast::Visit::visit(catalog_sync_namespace_mode,
visitor)?;
sqlparser::ast::Visit::visit(catalog_sync_namespace_flatten_delimiter,
visitor)?;
sqlparser::ast::Visit::visit(with_tags, visitor)?;
sqlparser::ast::Visit::visit(with_contacts, visitor)?;
}
Self::CreateFunction(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateTrigger(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DropTrigger(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateProcedure {
or_alter, name, params, language, body } => {
sqlparser::ast::Visit::visit(or_alter, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(params, visitor)?;
sqlparser::ast::Visit::visit(language, visitor)?;
sqlparser::ast::Visit::visit(body, visitor)?;
}
Self::CreateMacro {
or_replace, temporary, name, args, definition } => {
sqlparser::ast::Visit::visit(or_replace, visitor)?;
sqlparser::ast::Visit::visit(temporary, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(args, visitor)?;
sqlparser::ast::Visit::visit(definition, visitor)?;
}
Self::CreateStage {
or_replace,
temporary,
if_not_exists,
name,
stage_params,
directory_table_params,
file_format,
copy_options,
comment } => {
sqlparser::ast::Visit::visit(or_replace, visitor)?;
sqlparser::ast::Visit::visit(temporary, visitor)?;
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(stage_params, visitor)?;
sqlparser::ast::Visit::visit(directory_table_params,
visitor)?;
sqlparser::ast::Visit::visit(file_format, visitor)?;
sqlparser::ast::Visit::visit(copy_options, visitor)?;
sqlparser::ast::Visit::visit(comment, visitor)?;
}
Self::Assert { condition, message } => {
sqlparser::ast::Visit::visit(condition, visitor)?;
sqlparser::ast::Visit::visit(message, visitor)?;
}
Self::Grant(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Deny(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Revoke(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Deallocate { name, prepare } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(prepare, visitor)?;
}
Self::Execute {
name,
parameters,
has_parentheses,
immediate,
into,
using,
output,
default } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(parameters, visitor)?;
sqlparser::ast::Visit::visit(has_parentheses, visitor)?;
sqlparser::ast::Visit::visit(immediate, visitor)?;
sqlparser::ast::Visit::visit(into, visitor)?;
sqlparser::ast::Visit::visit(using, visitor)?;
sqlparser::ast::Visit::visit(output, visitor)?;
sqlparser::ast::Visit::visit(default, visitor)?;
}
Self::Prepare { name, data_types, statement } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(data_types, visitor)?;
sqlparser::ast::Visit::visit(statement, visitor)?;
}
Self::Kill { modifier, id } => {
sqlparser::ast::Visit::visit(modifier, visitor)?;
sqlparser::ast::Visit::visit(id, visitor)?;
}
Self::ExplainTable {
describe_alias, hive_format, has_table_keyword, table_name }
=> {
sqlparser::ast::Visit::visit(describe_alias, visitor)?;
sqlparser::ast::Visit::visit(hive_format, visitor)?;
sqlparser::ast::Visit::visit(has_table_keyword, visitor)?;
visitor.pre_visit_relation(table_name)?;
sqlparser::ast::Visit::visit(table_name, visitor)?;
visitor.post_visit_relation(table_name)?;
}
Self::Explain {
describe_alias,
analyze,
verbose,
query_plan,
estimate,
statement,
format,
options } => {
sqlparser::ast::Visit::visit(describe_alias, visitor)?;
sqlparser::ast::Visit::visit(analyze, visitor)?;
sqlparser::ast::Visit::visit(verbose, visitor)?;
sqlparser::ast::Visit::visit(query_plan, visitor)?;
sqlparser::ast::Visit::visit(estimate, visitor)?;
sqlparser::ast::Visit::visit(statement, visitor)?;
sqlparser::ast::Visit::visit(format, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
}
Self::Savepoint { name } => {
sqlparser::ast::Visit::visit(name, visitor)?;
}
Self::ReleaseSavepoint { name } => {
sqlparser::ast::Visit::visit(name, visitor)?;
}
Self::Merge(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Cache { table_flag, table_name, has_as, options, query
} => {
sqlparser::ast::Visit::visit(table_flag, visitor)?;
visitor.pre_visit_relation(table_name)?;
sqlparser::ast::Visit::visit(table_name, visitor)?;
visitor.post_visit_relation(table_name)?;
sqlparser::ast::Visit::visit(has_as, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
sqlparser::ast::Visit::visit(query, visitor)?;
}
Self::UNCache { table_name, if_exists } => {
visitor.pre_visit_relation(table_name)?;
sqlparser::ast::Visit::visit(table_name, visitor)?;
visitor.post_visit_relation(table_name)?;
sqlparser::ast::Visit::visit(if_exists, visitor)?;
}
Self::CreateSequence {
temporary,
if_not_exists,
name,
data_type,
sequence_options,
owned_by } => {
sqlparser::ast::Visit::visit(temporary, visitor)?;
sqlparser::ast::Visit::visit(if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(data_type, visitor)?;
sqlparser::ast::Visit::visit(sequence_options, visitor)?;
sqlparser::ast::Visit::visit(owned_by, visitor)?;
}
Self::CreateDomain(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateType { name, representation } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(representation, visitor)?;
}
Self::Pragma { name, value, is_eq } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(value, visitor)?;
sqlparser::ast::Visit::visit(is_eq, visitor)?;
}
Self::LockTables { tables } => {
sqlparser::ast::Visit::visit(tables, visitor)?;
}
Self::UnlockTables => {}
Self::Unload { query, query_text, to, auth, with, options }
=> {
sqlparser::ast::Visit::visit(query, visitor)?;
sqlparser::ast::Visit::visit(query_text, visitor)?;
sqlparser::ast::Visit::visit(to, visitor)?;
sqlparser::ast::Visit::visit(auth, visitor)?;
sqlparser::ast::Visit::visit(with, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
}
Self::OptimizeTable {
name, on_cluster, partition, include_final, deduplicate } =>
{
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(on_cluster, visitor)?;
sqlparser::ast::Visit::visit(partition, visitor)?;
sqlparser::ast::Visit::visit(include_final, visitor)?;
sqlparser::ast::Visit::visit(deduplicate, visitor)?;
}
Self::LISTEN { channel } => {
sqlparser::ast::Visit::visit(channel, visitor)?;
}
Self::UNLISTEN { channel } => {
sqlparser::ast::Visit::visit(channel, visitor)?;
}
Self::NOTIFY { channel, payload } => {
sqlparser::ast::Visit::visit(channel, visitor)?;
sqlparser::ast::Visit::visit(payload, visitor)?;
}
Self::LoadData {
local,
inpath,
overwrite,
table_name,
partitioned,
table_format } => {
sqlparser::ast::Visit::visit(local, visitor)?;
sqlparser::ast::Visit::visit(inpath, visitor)?;
sqlparser::ast::Visit::visit(overwrite, visitor)?;
sqlparser::ast::Visit::visit(table_name, visitor)?;
sqlparser::ast::Visit::visit(partitioned, visitor)?;
sqlparser::ast::Visit::visit(table_format, visitor)?;
}
Self::RenameTable(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::List(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Remove(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::RaisError {
message, severity, state, arguments, options } => {
sqlparser::ast::Visit::visit(message, visitor)?;
sqlparser::ast::Visit::visit(severity, visitor)?;
sqlparser::ast::Visit::visit(state, visitor)?;
sqlparser::ast::Visit::visit(arguments, visitor)?;
sqlparser::ast::Visit::visit(options, visitor)?;
}
Self::Print(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Return(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ExportData(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::CreateUser(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AlterUser(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Vacuum(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Reset(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
visitor.post_visit_statement(self)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Statement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
visitor.pre_visit_statement(self)?;
match self {
Self::Analyze(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Set(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Truncate(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Msck(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Query(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Insert(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Install { extension_name } => {
sqlparser::ast::VisitMut::visit(extension_name, visitor)?;
}
Self::Load { extension_name } => {
sqlparser::ast::VisitMut::visit(extension_name, visitor)?;
}
Self::Directory {
overwrite, local, path, file_format, source } => {
sqlparser::ast::VisitMut::visit(overwrite, visitor)?;
sqlparser::ast::VisitMut::visit(local, visitor)?;
sqlparser::ast::VisitMut::visit(path, visitor)?;
sqlparser::ast::VisitMut::visit(file_format, visitor)?;
sqlparser::ast::VisitMut::visit(source, visitor)?;
}
Self::Case(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::If(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::While(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Raise(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Call(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Copy {
source, to, target, options, legacy_options, values } => {
sqlparser::ast::VisitMut::visit(source, visitor)?;
sqlparser::ast::VisitMut::visit(to, visitor)?;
sqlparser::ast::VisitMut::visit(target, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
sqlparser::ast::VisitMut::visit(legacy_options, visitor)?;
sqlparser::ast::VisitMut::visit(values, visitor)?;
}
Self::CopyIntoSnowflake {
kind,
into,
into_columns,
from_obj,
from_obj_alias,
stage_params,
from_transformations,
from_query,
files,
pattern,
file_format,
copy_options,
validation_mode,
partition } => {
sqlparser::ast::VisitMut::visit(kind, visitor)?;
sqlparser::ast::VisitMut::visit(into, visitor)?;
sqlparser::ast::VisitMut::visit(into_columns, visitor)?;
sqlparser::ast::VisitMut::visit(from_obj, visitor)?;
sqlparser::ast::VisitMut::visit(from_obj_alias, visitor)?;
sqlparser::ast::VisitMut::visit(stage_params, visitor)?;
sqlparser::ast::VisitMut::visit(from_transformations,
visitor)?;
sqlparser::ast::VisitMut::visit(from_query, visitor)?;
sqlparser::ast::VisitMut::visit(files, visitor)?;
sqlparser::ast::VisitMut::visit(pattern, visitor)?;
sqlparser::ast::VisitMut::visit(file_format, visitor)?;
sqlparser::ast::VisitMut::visit(copy_options, visitor)?;
sqlparser::ast::VisitMut::visit(validation_mode, visitor)?;
sqlparser::ast::VisitMut::visit(partition, visitor)?;
}
Self::Open(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Close { cursor } => {
sqlparser::ast::VisitMut::visit(cursor, visitor)?;
}
Self::Update(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Delete(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateView(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateTable(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateVirtualTable {
name, if_not_exists, module_name, module_args } => {
visitor.pre_visit_relation(name)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
visitor.post_visit_relation(name)?;
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(module_name, visitor)?;
sqlparser::ast::VisitMut::visit(module_args, visitor)?;
}
Self::CreateIndex(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateRole(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateSecret {
or_replace,
temporary,
if_not_exists,
name,
storage_specifier,
secret_type,
options } => {
sqlparser::ast::VisitMut::visit(or_replace, visitor)?;
sqlparser::ast::VisitMut::visit(temporary, visitor)?;
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(storage_specifier,
visitor)?;
sqlparser::ast::VisitMut::visit(secret_type, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
}
Self::CreateServer(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreatePolicy(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateConnector(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateOperator(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateOperatorFamily(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateOperatorClass(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterTable(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterSchema(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterIndex { name, operation } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(operation, visitor)?;
}
Self::AlterView { name, columns, query, with_options } => {
visitor.pre_visit_relation(name)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
visitor.post_visit_relation(name)?;
sqlparser::ast::VisitMut::visit(columns, visitor)?;
sqlparser::ast::VisitMut::visit(query, visitor)?;
sqlparser::ast::VisitMut::visit(with_options, visitor)?;
}
Self::AlterType(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterOperator(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterOperatorFamily(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterOperatorClass(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterRole { name, operation } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(operation, visitor)?;
}
Self::AlterPolicy(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterConnector { name, properties, url, owner } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(properties, visitor)?;
sqlparser::ast::VisitMut::visit(url, visitor)?;
sqlparser::ast::VisitMut::visit(owner, visitor)?;
}
Self::AlterSession { set, session_params } => {
sqlparser::ast::VisitMut::visit(set, visitor)?;
sqlparser::ast::VisitMut::visit(session_params, visitor)?;
}
Self::AttachDatabase {
schema_name, database_file_name, database } => {
sqlparser::ast::VisitMut::visit(schema_name, visitor)?;
sqlparser::ast::VisitMut::visit(database_file_name,
visitor)?;
sqlparser::ast::VisitMut::visit(database, visitor)?;
}
Self::AttachDuckDBDatabase {
if_not_exists,
database,
database_path,
database_alias,
attach_options } => {
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(database, visitor)?;
sqlparser::ast::VisitMut::visit(database_path, visitor)?;
sqlparser::ast::VisitMut::visit(database_alias, visitor)?;
sqlparser::ast::VisitMut::visit(attach_options, visitor)?;
}
Self::DetachDuckDBDatabase {
if_exists, database, database_alias } => {
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
sqlparser::ast::VisitMut::visit(database, visitor)?;
sqlparser::ast::VisitMut::visit(database_alias, visitor)?;
}
Self::Drop {
object_type,
if_exists,
names,
cascade,
restrict,
purge,
temporary,
table } => {
sqlparser::ast::VisitMut::visit(object_type, visitor)?;
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
sqlparser::ast::VisitMut::visit(names, visitor)?;
sqlparser::ast::VisitMut::visit(cascade, visitor)?;
sqlparser::ast::VisitMut::visit(restrict, visitor)?;
sqlparser::ast::VisitMut::visit(purge, visitor)?;
sqlparser::ast::VisitMut::visit(temporary, visitor)?;
sqlparser::ast::VisitMut::visit(table, visitor)?;
}
Self::DropFunction(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropDomain(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropProcedure { if_exists, proc_desc, drop_behavior }
=> {
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
sqlparser::ast::VisitMut::visit(proc_desc, visitor)?;
sqlparser::ast::VisitMut::visit(drop_behavior, visitor)?;
}
Self::DropSecret {
if_exists, temporary, name, storage_specifier } => {
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
sqlparser::ast::VisitMut::visit(temporary, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(storage_specifier,
visitor)?;
}
Self::DropPolicy(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropConnector { if_exists, name } => {
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
}
Self::Declare { stmts } => {
sqlparser::ast::VisitMut::visit(stmts, visitor)?;
}
Self::CreateExtension(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropExtension(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropOperator(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropOperatorFamily(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropOperatorClass(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Fetch { name, direction, position, into } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(direction, visitor)?;
sqlparser::ast::VisitMut::visit(position, visitor)?;
sqlparser::ast::VisitMut::visit(into, visitor)?;
}
Self::Flush {
object_type, location, channel, read_lock, export, tables }
=> {
sqlparser::ast::VisitMut::visit(object_type, visitor)?;
sqlparser::ast::VisitMut::visit(location, visitor)?;
sqlparser::ast::VisitMut::visit(channel, visitor)?;
sqlparser::ast::VisitMut::visit(read_lock, visitor)?;
sqlparser::ast::VisitMut::visit(export, visitor)?;
sqlparser::ast::VisitMut::visit(tables, visitor)?;
}
Self::Discard { object_type } => {
sqlparser::ast::VisitMut::visit(object_type, visitor)?;
}
Self::ShowFunctions { filter } => {
sqlparser::ast::VisitMut::visit(filter, visitor)?;
}
Self::ShowVariable { variable } => {
sqlparser::ast::VisitMut::visit(variable, visitor)?;
}
Self::ShowStatus { filter, global, session } => {
sqlparser::ast::VisitMut::visit(filter, visitor)?;
sqlparser::ast::VisitMut::visit(global, visitor)?;
sqlparser::ast::VisitMut::visit(session, visitor)?;
}
Self::ShowVariables { filter, global, session } => {
sqlparser::ast::VisitMut::visit(filter, visitor)?;
sqlparser::ast::VisitMut::visit(global, visitor)?;
sqlparser::ast::VisitMut::visit(session, visitor)?;
}
Self::ShowCreate { obj_type, obj_name } => {
sqlparser::ast::VisitMut::visit(obj_type, visitor)?;
sqlparser::ast::VisitMut::visit(obj_name, visitor)?;
}
Self::ShowColumns { extended, full, show_options } => {
sqlparser::ast::VisitMut::visit(extended, visitor)?;
sqlparser::ast::VisitMut::visit(full, visitor)?;
sqlparser::ast::VisitMut::visit(show_options, visitor)?;
}
Self::ShowDatabases { terse, history, show_options } => {
sqlparser::ast::VisitMut::visit(terse, visitor)?;
sqlparser::ast::VisitMut::visit(history, visitor)?;
sqlparser::ast::VisitMut::visit(show_options, visitor)?;
}
Self::ShowSchemas { terse, history, show_options } => {
sqlparser::ast::VisitMut::visit(terse, visitor)?;
sqlparser::ast::VisitMut::visit(history, visitor)?;
sqlparser::ast::VisitMut::visit(show_options, visitor)?;
}
Self::ShowCharset(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ShowObjects(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ShowTables {
terse, history, extended, full, external, show_options } =>
{
sqlparser::ast::VisitMut::visit(terse, visitor)?;
sqlparser::ast::VisitMut::visit(history, visitor)?;
sqlparser::ast::VisitMut::visit(extended, visitor)?;
sqlparser::ast::VisitMut::visit(full, visitor)?;
sqlparser::ast::VisitMut::visit(external, visitor)?;
sqlparser::ast::VisitMut::visit(show_options, visitor)?;
}
Self::ShowViews { terse, materialized, show_options } => {
sqlparser::ast::VisitMut::visit(terse, visitor)?;
sqlparser::ast::VisitMut::visit(materialized, visitor)?;
sqlparser::ast::VisitMut::visit(show_options, visitor)?;
}
Self::ShowCollation { filter } => {
sqlparser::ast::VisitMut::visit(filter, visitor)?;
}
Self::Use(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::StartTransaction {
modes,
begin,
transaction,
modifier,
statements,
exception,
has_end_keyword } => {
sqlparser::ast::VisitMut::visit(modes, visitor)?;
sqlparser::ast::VisitMut::visit(begin, visitor)?;
sqlparser::ast::VisitMut::visit(transaction, visitor)?;
sqlparser::ast::VisitMut::visit(modifier, visitor)?;
sqlparser::ast::VisitMut::visit(statements, visitor)?;
sqlparser::ast::VisitMut::visit(exception, visitor)?;
sqlparser::ast::VisitMut::visit(has_end_keyword, visitor)?;
}
Self::Comment { object_type, object_name, comment, if_exists
} => {
sqlparser::ast::VisitMut::visit(object_type, visitor)?;
sqlparser::ast::VisitMut::visit(object_name, visitor)?;
sqlparser::ast::VisitMut::visit(comment, visitor)?;
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
}
Self::Commit { chain, end, modifier } => {
sqlparser::ast::VisitMut::visit(chain, visitor)?;
sqlparser::ast::VisitMut::visit(end, visitor)?;
sqlparser::ast::VisitMut::visit(modifier, visitor)?;
}
Self::Rollback { chain, savepoint } => {
sqlparser::ast::VisitMut::visit(chain, visitor)?;
sqlparser::ast::VisitMut::visit(savepoint, visitor)?;
}
Self::CreateSchema {
schema_name,
if_not_exists,
with,
options,
default_collate_spec,
clone } => {
sqlparser::ast::VisitMut::visit(schema_name, visitor)?;
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(with, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
sqlparser::ast::VisitMut::visit(default_collate_spec,
visitor)?;
sqlparser::ast::VisitMut::visit(clone, visitor)?;
}
Self::CreateDatabase {
db_name,
if_not_exists,
location,
managed_location,
or_replace,
transient,
clone,
data_retention_time_in_days,
max_data_extension_time_in_days,
external_volume,
catalog,
replace_invalid_characters,
default_ddl_collation,
storage_serialization_policy,
comment,
default_charset,
default_collation,
catalog_sync,
catalog_sync_namespace_mode,
catalog_sync_namespace_flatten_delimiter,
with_tags,
with_contacts } => {
sqlparser::ast::VisitMut::visit(db_name, visitor)?;
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(location, visitor)?;
sqlparser::ast::VisitMut::visit(managed_location, visitor)?;
sqlparser::ast::VisitMut::visit(or_replace, visitor)?;
sqlparser::ast::VisitMut::visit(transient, visitor)?;
sqlparser::ast::VisitMut::visit(clone, visitor)?;
sqlparser::ast::VisitMut::visit(data_retention_time_in_days,
visitor)?;
sqlparser::ast::VisitMut::visit(max_data_extension_time_in_days,
visitor)?;
sqlparser::ast::VisitMut::visit(external_volume, visitor)?;
sqlparser::ast::VisitMut::visit(catalog, visitor)?;
sqlparser::ast::VisitMut::visit(replace_invalid_characters,
visitor)?;
sqlparser::ast::VisitMut::visit(default_ddl_collation,
visitor)?;
sqlparser::ast::VisitMut::visit(storage_serialization_policy,
visitor)?;
sqlparser::ast::VisitMut::visit(comment, visitor)?;
sqlparser::ast::VisitMut::visit(default_charset, visitor)?;
sqlparser::ast::VisitMut::visit(default_collation,
visitor)?;
sqlparser::ast::VisitMut::visit(catalog_sync, visitor)?;
sqlparser::ast::VisitMut::visit(catalog_sync_namespace_mode,
visitor)?;
sqlparser::ast::VisitMut::visit(catalog_sync_namespace_flatten_delimiter,
visitor)?;
sqlparser::ast::VisitMut::visit(with_tags, visitor)?;
sqlparser::ast::VisitMut::visit(with_contacts, visitor)?;
}
Self::CreateFunction(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateTrigger(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DropTrigger(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateProcedure {
or_alter, name, params, language, body } => {
sqlparser::ast::VisitMut::visit(or_alter, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(params, visitor)?;
sqlparser::ast::VisitMut::visit(language, visitor)?;
sqlparser::ast::VisitMut::visit(body, visitor)?;
}
Self::CreateMacro {
or_replace, temporary, name, args, definition } => {
sqlparser::ast::VisitMut::visit(or_replace, visitor)?;
sqlparser::ast::VisitMut::visit(temporary, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(args, visitor)?;
sqlparser::ast::VisitMut::visit(definition, visitor)?;
}
Self::CreateStage {
or_replace,
temporary,
if_not_exists,
name,
stage_params,
directory_table_params,
file_format,
copy_options,
comment } => {
sqlparser::ast::VisitMut::visit(or_replace, visitor)?;
sqlparser::ast::VisitMut::visit(temporary, visitor)?;
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(stage_params, visitor)?;
sqlparser::ast::VisitMut::visit(directory_table_params,
visitor)?;
sqlparser::ast::VisitMut::visit(file_format, visitor)?;
sqlparser::ast::VisitMut::visit(copy_options, visitor)?;
sqlparser::ast::VisitMut::visit(comment, visitor)?;
}
Self::Assert { condition, message } => {
sqlparser::ast::VisitMut::visit(condition, visitor)?;
sqlparser::ast::VisitMut::visit(message, visitor)?;
}
Self::Grant(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Deny(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Revoke(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Deallocate { name, prepare } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(prepare, visitor)?;
}
Self::Execute {
name,
parameters,
has_parentheses,
immediate,
into,
using,
output,
default } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(parameters, visitor)?;
sqlparser::ast::VisitMut::visit(has_parentheses, visitor)?;
sqlparser::ast::VisitMut::visit(immediate, visitor)?;
sqlparser::ast::VisitMut::visit(into, visitor)?;
sqlparser::ast::VisitMut::visit(using, visitor)?;
sqlparser::ast::VisitMut::visit(output, visitor)?;
sqlparser::ast::VisitMut::visit(default, visitor)?;
}
Self::Prepare { name, data_types, statement } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(data_types, visitor)?;
sqlparser::ast::VisitMut::visit(statement, visitor)?;
}
Self::Kill { modifier, id } => {
sqlparser::ast::VisitMut::visit(modifier, visitor)?;
sqlparser::ast::VisitMut::visit(id, visitor)?;
}
Self::ExplainTable {
describe_alias, hive_format, has_table_keyword, table_name }
=> {
sqlparser::ast::VisitMut::visit(describe_alias, visitor)?;
sqlparser::ast::VisitMut::visit(hive_format, visitor)?;
sqlparser::ast::VisitMut::visit(has_table_keyword,
visitor)?;
visitor.pre_visit_relation(table_name)?;
sqlparser::ast::VisitMut::visit(table_name, visitor)?;
visitor.post_visit_relation(table_name)?;
}
Self::Explain {
describe_alias,
analyze,
verbose,
query_plan,
estimate,
statement,
format,
options } => {
sqlparser::ast::VisitMut::visit(describe_alias, visitor)?;
sqlparser::ast::VisitMut::visit(analyze, visitor)?;
sqlparser::ast::VisitMut::visit(verbose, visitor)?;
sqlparser::ast::VisitMut::visit(query_plan, visitor)?;
sqlparser::ast::VisitMut::visit(estimate, visitor)?;
sqlparser::ast::VisitMut::visit(statement, visitor)?;
sqlparser::ast::VisitMut::visit(format, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
}
Self::Savepoint { name } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
}
Self::ReleaseSavepoint { name } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
}
Self::Merge(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Cache { table_flag, table_name, has_as, options, query
} => {
sqlparser::ast::VisitMut::visit(table_flag, visitor)?;
visitor.pre_visit_relation(table_name)?;
sqlparser::ast::VisitMut::visit(table_name, visitor)?;
visitor.post_visit_relation(table_name)?;
sqlparser::ast::VisitMut::visit(has_as, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
sqlparser::ast::VisitMut::visit(query, visitor)?;
}
Self::UNCache { table_name, if_exists } => {
visitor.pre_visit_relation(table_name)?;
sqlparser::ast::VisitMut::visit(table_name, visitor)?;
visitor.post_visit_relation(table_name)?;
sqlparser::ast::VisitMut::visit(if_exists, visitor)?;
}
Self::CreateSequence {
temporary,
if_not_exists,
name,
data_type,
sequence_options,
owned_by } => {
sqlparser::ast::VisitMut::visit(temporary, visitor)?;
sqlparser::ast::VisitMut::visit(if_not_exists, visitor)?;
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(data_type, visitor)?;
sqlparser::ast::VisitMut::visit(sequence_options, visitor)?;
sqlparser::ast::VisitMut::visit(owned_by, visitor)?;
}
Self::CreateDomain(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateType { name, representation } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(representation, visitor)?;
}
Self::Pragma { name, value, is_eq } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(value, visitor)?;
sqlparser::ast::VisitMut::visit(is_eq, visitor)?;
}
Self::LockTables { tables } => {
sqlparser::ast::VisitMut::visit(tables, visitor)?;
}
Self::UnlockTables => {}
Self::Unload { query, query_text, to, auth, with, options }
=> {
sqlparser::ast::VisitMut::visit(query, visitor)?;
sqlparser::ast::VisitMut::visit(query_text, visitor)?;
sqlparser::ast::VisitMut::visit(to, visitor)?;
sqlparser::ast::VisitMut::visit(auth, visitor)?;
sqlparser::ast::VisitMut::visit(with, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
}
Self::OptimizeTable {
name, on_cluster, partition, include_final, deduplicate } =>
{
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(on_cluster, visitor)?;
sqlparser::ast::VisitMut::visit(partition, visitor)?;
sqlparser::ast::VisitMut::visit(include_final, visitor)?;
sqlparser::ast::VisitMut::visit(deduplicate, visitor)?;
}
Self::LISTEN { channel } => {
sqlparser::ast::VisitMut::visit(channel, visitor)?;
}
Self::UNLISTEN { channel } => {
sqlparser::ast::VisitMut::visit(channel, visitor)?;
}
Self::NOTIFY { channel, payload } => {
sqlparser::ast::VisitMut::visit(channel, visitor)?;
sqlparser::ast::VisitMut::visit(payload, visitor)?;
}
Self::LoadData {
local,
inpath,
overwrite,
table_name,
partitioned,
table_format } => {
sqlparser::ast::VisitMut::visit(local, visitor)?;
sqlparser::ast::VisitMut::visit(inpath, visitor)?;
sqlparser::ast::VisitMut::visit(overwrite, visitor)?;
sqlparser::ast::VisitMut::visit(table_name, visitor)?;
sqlparser::ast::VisitMut::visit(partitioned, visitor)?;
sqlparser::ast::VisitMut::visit(table_format, visitor)?;
}
Self::RenameTable(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::List(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Remove(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::RaisError {
message, severity, state, arguments, options } => {
sqlparser::ast::VisitMut::visit(message, visitor)?;
sqlparser::ast::VisitMut::visit(severity, visitor)?;
sqlparser::ast::VisitMut::visit(state, visitor)?;
sqlparser::ast::VisitMut::visit(arguments, visitor)?;
sqlparser::ast::VisitMut::visit(options, visitor)?;
}
Self::Print(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Return(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ExportData(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::CreateUser(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AlterUser(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Vacuum(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Reset(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
visitor.post_visit_statement(self)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut),
3401 visit(with = "visit_statement")
3402)]
3403pub enum Statement {
3404 Analyze(Analyze),
3409 Set(Set),
3411 Truncate(Truncate),
3416 Msck(Msck),
3421 Query(Box<Query>),
3425 Insert(Insert),
3429 Install {
3433 extension_name: Ident,
3435 },
3436 Load {
3440 extension_name: Ident,
3442 },
3443 Directory {
3446 overwrite: bool,
3448 local: bool,
3450 path: String,
3452 file_format: Option<FileFormat>,
3454 source: Box<Query>,
3456 },
3457 Case(CaseStatement),
3459 If(IfStatement),
3461 While(WhileStatement),
3463 Raise(RaiseStatement),
3465 Call(Function),
3469 Copy {
3473 source: CopySource,
3475 to: bool,
3477 target: CopyTarget,
3479 options: Vec<CopyOption>,
3481 legacy_options: Vec<CopyLegacyOption>,
3483 values: Vec<Option<String>>,
3485 },
3486 CopyIntoSnowflake {
3498 kind: CopyIntoSnowflakeKind,
3500 into: ObjectName,
3502 into_columns: Option<Vec<Ident>>,
3504 from_obj: Option<ObjectName>,
3506 from_obj_alias: Option<Ident>,
3508 stage_params: StageParamsObject,
3510 from_transformations: Option<Vec<StageLoadSelectItemKind>>,
3512 from_query: Option<Box<Query>>,
3514 files: Option<Vec<String>>,
3516 pattern: Option<String>,
3518 file_format: KeyValueOptions,
3520 copy_options: KeyValueOptions,
3522 validation_mode: Option<String>,
3524 partition: Option<Box<Expr>>,
3526 },
3527 Open(OpenStatement),
3532 Close {
3537 cursor: CloseCursor,
3539 },
3540 Update(Update),
3544 Delete(Delete),
3548 CreateView(CreateView),
3552 CreateTable(CreateTable),
3556 CreateVirtualTable {
3561 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
3562 name: ObjectName,
3564 if_not_exists: bool,
3566 module_name: Ident,
3568 module_args: Vec<Ident>,
3570 },
3571 CreateIndex(CreateIndex),
3575 CreateRole(CreateRole),
3580 CreateSecret {
3585 or_replace: bool,
3587 temporary: Option<bool>,
3589 if_not_exists: bool,
3591 name: Option<Ident>,
3593 storage_specifier: Option<Ident>,
3595 secret_type: Ident,
3597 options: Vec<SecretOption>,
3599 },
3600 CreateServer(CreateServerStatement),
3602 CreatePolicy(CreatePolicy),
3607 CreateConnector(CreateConnector),
3612 CreateOperator(CreateOperator),
3617 CreateOperatorFamily(CreateOperatorFamily),
3622 CreateOperatorClass(CreateOperatorClass),
3627 AlterTable(AlterTable),
3631 AlterSchema(AlterSchema),
3636 AlterIndex {
3640 name: ObjectName,
3642 operation: AlterIndexOperation,
3644 },
3645 AlterView {
3649 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
3651 name: ObjectName,
3652 columns: Vec<Ident>,
3654 query: Box<Query>,
3656 with_options: Vec<SqlOption>,
3658 },
3659 AlterType(AlterType),
3664 AlterOperator(AlterOperator),
3669 AlterOperatorFamily(AlterOperatorFamily),
3674 AlterOperatorClass(AlterOperatorClass),
3679 AlterRole {
3683 name: Ident,
3685 operation: AlterRoleOperation,
3687 },
3688 AlterPolicy(AlterPolicy),
3693 AlterConnector {
3702 name: Ident,
3704 properties: Option<Vec<SqlOption>>,
3706 url: Option<String>,
3708 owner: Option<ddl::AlterConnectorOwner>,
3710 },
3711 AlterSession {
3717 set: bool,
3719 session_params: KeyValueOptions,
3721 },
3722 AttachDatabase {
3727 schema_name: Ident,
3729 database_file_name: Expr,
3731 database: bool,
3733 },
3734 AttachDuckDBDatabase {
3740 if_not_exists: bool,
3742 database: bool,
3744 database_path: Ident,
3746 database_alias: Option<Ident>,
3748 attach_options: Vec<AttachDuckDBDatabaseOption>,
3750 },
3751 DetachDuckDBDatabase {
3757 if_exists: bool,
3759 database: bool,
3761 database_alias: Ident,
3763 },
3764 Drop {
3768 object_type: ObjectType,
3770 if_exists: bool,
3772 names: Vec<ObjectName>,
3774 cascade: bool,
3777 restrict: bool,
3780 purge: bool,
3783 temporary: bool,
3785 table: Option<ObjectName>,
3788 },
3789 DropFunction(DropFunction),
3793 DropDomain(DropDomain),
3801 DropProcedure {
3805 if_exists: bool,
3807 proc_desc: Vec<FunctionDesc>,
3809 drop_behavior: Option<DropBehavior>,
3811 },
3812 DropSecret {
3816 if_exists: bool,
3818 temporary: Option<bool>,
3820 name: Ident,
3822 storage_specifier: Option<Ident>,
3824 },
3825 DropPolicy(DropPolicy),
3830 DropConnector {
3835 if_exists: bool,
3837 name: Ident,
3839 },
3840 Declare {
3848 stmts: Vec<Declare>,
3850 },
3851 CreateExtension(CreateExtension),
3860 DropExtension(DropExtension),
3866 DropOperator(DropOperator),
3872 DropOperatorFamily(DropOperatorFamily),
3878 DropOperatorClass(DropOperatorClass),
3884 Fetch {
3892 name: Ident,
3894 direction: FetchDirection,
3896 position: FetchPosition,
3898 into: Option<ObjectName>,
3900 },
3901 Flush {
3908 object_type: FlushType,
3910 location: Option<FlushLocation>,
3912 channel: Option<String>,
3914 read_lock: bool,
3916 export: bool,
3918 tables: Vec<ObjectName>,
3920 },
3921 Discard {
3928 object_type: DiscardObject,
3930 },
3931 ShowFunctions {
3935 filter: Option<ShowStatementFilter>,
3937 },
3938 ShowVariable {
3944 variable: Vec<Ident>,
3946 },
3947 ShowStatus {
3953 filter: Option<ShowStatementFilter>,
3955 global: bool,
3957 session: bool,
3959 },
3960 ShowVariables {
3966 filter: Option<ShowStatementFilter>,
3968 global: bool,
3970 session: bool,
3972 },
3973 ShowCreate {
3979 obj_type: ShowCreateObject,
3981 obj_name: ObjectName,
3983 },
3984 ShowColumns {
3988 extended: bool,
3990 full: bool,
3992 show_options: ShowStatementOptions,
3994 },
3995 ShowDatabases {
3999 terse: bool,
4001 history: bool,
4003 show_options: ShowStatementOptions,
4005 },
4006 ShowSchemas {
4010 terse: bool,
4012 history: bool,
4014 show_options: ShowStatementOptions,
4016 },
4017 ShowCharset(ShowCharset),
4024 ShowObjects(ShowObjects),
4030 ShowTables {
4034 terse: bool,
4036 history: bool,
4038 extended: bool,
4040 full: bool,
4042 external: bool,
4044 show_options: ShowStatementOptions,
4046 },
4047 ShowViews {
4051 terse: bool,
4053 materialized: bool,
4055 show_options: ShowStatementOptions,
4057 },
4058 ShowCollation {
4064 filter: Option<ShowStatementFilter>,
4066 },
4067 Use(Use),
4071 StartTransaction {
4081 modes: Vec<TransactionMode>,
4083 begin: bool,
4085 transaction: Option<BeginTransactionKind>,
4087 modifier: Option<TransactionModifier>,
4089 statements: Vec<Statement>,
4098 exception: Option<Vec<ExceptionWhen>>,
4112 has_end_keyword: bool,
4114 },
4115 Comment {
4121 object_type: CommentObject,
4123 object_name: ObjectName,
4125 comment: Option<String>,
4127 if_exists: bool,
4130 },
4131 Commit {
4141 chain: bool,
4143 end: bool,
4145 modifier: Option<TransactionModifier>,
4147 },
4148 Rollback {
4152 chain: bool,
4154 savepoint: Option<Ident>,
4156 },
4157 CreateSchema {
4161 schema_name: SchemaName,
4163 if_not_exists: bool,
4165 with: Option<Vec<SqlOption>>,
4173 options: Option<Vec<SqlOption>>,
4181 default_collate_spec: Option<Expr>,
4189 clone: Option<ObjectName>,
4197 },
4198 CreateDatabase {
4204 db_name: ObjectName,
4206 if_not_exists: bool,
4208 location: Option<String>,
4210 managed_location: Option<String>,
4212 or_replace: bool,
4214 transient: bool,
4216 clone: Option<ObjectName>,
4218 data_retention_time_in_days: Option<u64>,
4220 max_data_extension_time_in_days: Option<u64>,
4222 external_volume: Option<String>,
4224 catalog: Option<String>,
4226 replace_invalid_characters: Option<bool>,
4228 default_ddl_collation: Option<String>,
4230 storage_serialization_policy: Option<StorageSerializationPolicy>,
4232 comment: Option<String>,
4234 default_charset: Option<String>,
4236 default_collation: Option<String>,
4238 catalog_sync: Option<String>,
4240 catalog_sync_namespace_mode: Option<CatalogSyncNamespaceMode>,
4242 catalog_sync_namespace_flatten_delimiter: Option<String>,
4244 with_tags: Option<Vec<Tag>>,
4246 with_contacts: Option<Vec<ContactEntry>>,
4248 },
4249 CreateFunction(CreateFunction),
4259 CreateTrigger(CreateTrigger),
4261 DropTrigger(DropTrigger),
4263 CreateProcedure {
4267 or_alter: bool,
4269 name: ObjectName,
4271 params: Option<Vec<ProcedureParam>>,
4273 language: Option<Ident>,
4275 body: ConditionalStatements,
4277 },
4278 CreateMacro {
4285 or_replace: bool,
4287 temporary: bool,
4289 name: ObjectName,
4291 args: Option<Vec<MacroArg>>,
4293 definition: MacroDefinition,
4295 },
4296 CreateStage {
4301 or_replace: bool,
4303 temporary: bool,
4305 if_not_exists: bool,
4307 name: ObjectName,
4309 stage_params: StageParamsObject,
4311 directory_table_params: KeyValueOptions,
4313 file_format: KeyValueOptions,
4315 copy_options: KeyValueOptions,
4317 comment: Option<String>,
4319 },
4320 Assert {
4324 condition: Expr,
4326 message: Option<Expr>,
4328 },
4329 Grant(Grant),
4333 Deny(DenyStatement),
4337 Revoke(Revoke),
4341 Deallocate {
4347 name: Ident,
4349 prepare: bool,
4351 },
4352 Execute {
4361 name: Option<ObjectName>,
4363 parameters: Vec<Expr>,
4365 has_parentheses: bool,
4367 immediate: bool,
4369 into: Vec<Ident>,
4371 using: Vec<ExprWithAlias>,
4373 output: bool,
4376 default: bool,
4379 },
4380 Prepare {
4386 name: Ident,
4388 data_types: Vec<DataType>,
4390 statement: Box<Statement>,
4392 },
4393 Kill {
4400 modifier: Option<KillType>,
4402 id: u64,
4405 },
4406 ExplainTable {
4411 describe_alias: DescribeAlias,
4413 hive_format: Option<HiveDescribeFormat>,
4415 has_table_keyword: bool,
4420 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
4422 table_name: ObjectName,
4423 },
4424 Explain {
4428 describe_alias: DescribeAlias,
4430 analyze: bool,
4432 verbose: bool,
4434 query_plan: bool,
4439 estimate: bool,
4442 statement: Box<Statement>,
4444 format: Option<AnalyzeFormatKind>,
4446 options: Option<Vec<UtilityOption>>,
4448 },
4449 Savepoint {
4454 name: Ident,
4456 },
4457 ReleaseSavepoint {
4461 name: Ident,
4463 },
4464 Merge(Merge),
4473 Cache {
4481 table_flag: Option<ObjectName>,
4483 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
4485 table_name: ObjectName,
4486 has_as: bool,
4488 options: Vec<SqlOption>,
4490 query: Option<Box<Query>>,
4492 },
4493 UNCache {
4497 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
4499 table_name: ObjectName,
4500 if_exists: bool,
4502 },
4503 CreateSequence {
4508 temporary: bool,
4510 if_not_exists: bool,
4512 name: ObjectName,
4514 data_type: Option<DataType>,
4516 sequence_options: Vec<SequenceOptions>,
4518 owned_by: Option<ObjectName>,
4520 },
4521 CreateDomain(CreateDomain),
4523 CreateType {
4527 name: ObjectName,
4529 representation: Option<UserDefinedTypeRepresentation>,
4531 },
4532 Pragma {
4536 name: ObjectName,
4538 value: Option<Value>,
4540 is_eq: bool,
4542 },
4543 LockTables {
4548 tables: Vec<LockTable>,
4550 },
4551 UnlockTables,
4556 Unload {
4568 query: Option<Box<Query>>,
4570 query_text: Option<String>,
4572 to: Ident,
4574 auth: Option<IamRoleKind>,
4576 with: Vec<SqlOption>,
4578 options: Vec<CopyLegacyOption>,
4580 },
4581 OptimizeTable {
4587 name: ObjectName,
4589 on_cluster: Option<Ident>,
4591 partition: Option<Partition>,
4593 include_final: bool,
4595 deduplicate: Option<Deduplicate>,
4597 },
4598 LISTEN {
4605 channel: Ident,
4607 },
4608 UNLISTEN {
4615 channel: Ident,
4617 },
4618 NOTIFY {
4625 channel: Ident,
4627 payload: Option<String>,
4629 },
4630 LoadData {
4639 local: bool,
4641 inpath: String,
4643 overwrite: bool,
4645 table_name: ObjectName,
4647 partitioned: Option<Vec<Expr>>,
4649 table_format: Option<HiveLoadDataFormat>,
4651 },
4652 RenameTable(Vec<RenameTable>),
4659 List(FileStagingCommand),
4662 Remove(FileStagingCommand),
4665 RaisError {
4672 message: Box<Expr>,
4674 severity: Box<Expr>,
4676 state: Box<Expr>,
4678 arguments: Vec<Expr>,
4680 options: Vec<RaisErrorOption>,
4682 },
4683 Print(PrintStatement),
4689 Return(ReturnStatement),
4695 ExportData(ExportData),
4704 CreateUser(CreateUser),
4709 AlterUser(AlterUser),
4714 Vacuum(VacuumStatement),
4721 Reset(ResetStatement),
4729}
4730
4731impl From<Analyze> for Statement {
4732 fn from(analyze: Analyze) -> Self {
4733 Statement::Analyze(analyze)
4734 }
4735}
4736
4737impl From<ddl::Truncate> for Statement {
4738 fn from(truncate: ddl::Truncate) -> Self {
4739 Statement::Truncate(truncate)
4740 }
4741}
4742
4743impl From<ddl::Msck> for Statement {
4744 fn from(msck: ddl::Msck) -> Self {
4745 Statement::Msck(msck)
4746 }
4747}
4748
4749#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CurrentGrantsKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CurrentGrantsKind::CopyCurrentGrants => "CopyCurrentGrants",
CurrentGrantsKind::RevokeCurrentGrants =>
"RevokeCurrentGrants",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CurrentGrantsKind {
#[inline]
fn clone(&self) -> CurrentGrantsKind {
match self {
CurrentGrantsKind::CopyCurrentGrants =>
CurrentGrantsKind::CopyCurrentGrants,
CurrentGrantsKind::RevokeCurrentGrants =>
CurrentGrantsKind::RevokeCurrentGrants,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CurrentGrantsKind {
#[inline]
fn eq(&self, other: &CurrentGrantsKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CurrentGrantsKind {
#[inline]
fn partial_cmp(&self, other: &CurrentGrantsKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CurrentGrantsKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CurrentGrantsKind {
#[inline]
fn cmp(&self, other: &CurrentGrantsKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CurrentGrantsKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
4755#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
4756#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CurrentGrantsKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::CopyCurrentGrants => {}
Self::RevokeCurrentGrants => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CurrentGrantsKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::CopyCurrentGrants => {}
Self::RevokeCurrentGrants => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
4757pub enum CurrentGrantsKind {
4758 CopyCurrentGrants,
4760 RevokeCurrentGrants,
4762}
4763
4764impl fmt::Display for CurrentGrantsKind {
4765 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4766 match self {
4767 CurrentGrantsKind::CopyCurrentGrants => f.write_fmt(format_args!("COPY CURRENT GRANTS"))write!(f, "COPY CURRENT GRANTS"),
4768 CurrentGrantsKind::RevokeCurrentGrants => f.write_fmt(format_args!("REVOKE CURRENT GRANTS"))write!(f, "REVOKE CURRENT GRANTS"),
4769 }
4770 }
4771}
4772
4773#[derive(#[automatically_derived]
impl ::core::fmt::Debug for RaisErrorOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
RaisErrorOption::Log => "Log",
RaisErrorOption::NoWait => "NoWait",
RaisErrorOption::SetError => "SetError",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for RaisErrorOption {
#[inline]
fn clone(&self) -> RaisErrorOption {
match self {
RaisErrorOption::Log => RaisErrorOption::Log,
RaisErrorOption::NoWait => RaisErrorOption::NoWait,
RaisErrorOption::SetError => RaisErrorOption::SetError,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for RaisErrorOption {
#[inline]
fn eq(&self, other: &RaisErrorOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for RaisErrorOption {
#[inline]
fn partial_cmp(&self, other: &RaisErrorOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for RaisErrorOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for RaisErrorOption {
#[inline]
fn cmp(&self, other: &RaisErrorOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for RaisErrorOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
4774#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
4775#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for RaisErrorOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Log => {}
Self::NoWait => {}
Self::SetError => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for RaisErrorOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Log => {}
Self::NoWait => {}
Self::SetError => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
4776pub enum RaisErrorOption {
4779 Log,
4781 NoWait,
4783 SetError,
4785}
4786
4787impl fmt::Display for RaisErrorOption {
4788 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4789 match self {
4790 RaisErrorOption::Log => f.write_fmt(format_args!("LOG"))write!(f, "LOG"),
4791 RaisErrorOption::NoWait => f.write_fmt(format_args!("NOWAIT"))write!(f, "NOWAIT"),
4792 RaisErrorOption::SetError => f.write_fmt(format_args!("SETERROR"))write!(f, "SETERROR"),
4793 }
4794 }
4795}
4796
4797impl fmt::Display for Statement {
4798 #[allow(clippy::cognitive_complexity)]
4823 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4824 match self {
4825 Statement::Flush {
4826 object_type,
4827 location,
4828 channel,
4829 read_lock,
4830 export,
4831 tables,
4832 } => {
4833 f.write_fmt(format_args!("FLUSH"))write!(f, "FLUSH")?;
4834 if let Some(location) = location {
4835 f.write_str(" ")?;
4836 location.fmt(f)?;
4837 }
4838 f.write_fmt(format_args!(" {0}", object_type))write!(f, " {object_type}")?;
4839
4840 if let Some(channel) = channel {
4841 f.write_fmt(format_args!(" FOR CHANNEL {0}", channel))write!(f, " FOR CHANNEL {channel}")?;
4842 }
4843
4844 f.write_fmt(format_args!("{0}{2}{1}",
if !tables.is_empty() {
::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" {0}",
display_comma_separated(tables)))
})
} else { String::new() }, if *export { " FOR EXPORT" } else { "" },
if *read_lock { " WITH READ LOCK" } else { "" }))write!(
4845 f,
4846 "{tables}{read}{export}",
4847 tables = if !tables.is_empty() {
4848 format!(" {}", display_comma_separated(tables))
4849 } else {
4850 String::new()
4851 },
4852 export = if *export { " FOR EXPORT" } else { "" },
4853 read = if *read_lock { " WITH READ LOCK" } else { "" }
4854 )
4855 }
4856 Statement::Kill { modifier, id } => {
4857 f.write_fmt(format_args!("KILL "))write!(f, "KILL ")?;
4858
4859 if let Some(m) = modifier {
4860 f.write_fmt(format_args!("{0} ", m))write!(f, "{m} ")?;
4861 }
4862
4863 f.write_fmt(format_args!("{0}", id))write!(f, "{id}")
4864 }
4865 Statement::ExplainTable {
4866 describe_alias,
4867 hive_format,
4868 has_table_keyword,
4869 table_name,
4870 } => {
4871 f.write_fmt(format_args!("{0} ", describe_alias))write!(f, "{describe_alias} ")?;
4872
4873 if let Some(format) = hive_format {
4874 f.write_fmt(format_args!("{0} ", format))write!(f, "{format} ")?;
4875 }
4876 if *has_table_keyword {
4877 f.write_fmt(format_args!("TABLE "))write!(f, "TABLE ")?;
4878 }
4879
4880 f.write_fmt(format_args!("{0}", table_name))write!(f, "{table_name}")
4881 }
4882 Statement::Explain {
4883 describe_alias,
4884 verbose,
4885 analyze,
4886 query_plan,
4887 estimate,
4888 statement,
4889 format,
4890 options,
4891 } => {
4892 f.write_fmt(format_args!("{0} ", describe_alias))write!(f, "{describe_alias} ")?;
4893
4894 if *query_plan {
4895 f.write_fmt(format_args!("QUERY PLAN "))write!(f, "QUERY PLAN ")?;
4896 }
4897 if *analyze {
4898 f.write_fmt(format_args!("ANALYZE "))write!(f, "ANALYZE ")?;
4899 }
4900 if *estimate {
4901 f.write_fmt(format_args!("ESTIMATE "))write!(f, "ESTIMATE ")?;
4902 }
4903
4904 if *verbose {
4905 f.write_fmt(format_args!("VERBOSE "))write!(f, "VERBOSE ")?;
4906 }
4907
4908 if let Some(format) = format {
4909 f.write_fmt(format_args!("{0} ", format))write!(f, "{format} ")?;
4910 }
4911
4912 if let Some(options) = options {
4913 f.write_fmt(format_args!("({0}) ", display_comma_separated(options)))write!(f, "({}) ", display_comma_separated(options))?;
4914 }
4915
4916 f.write_fmt(format_args!("{0}", statement))write!(f, "{statement}")
4917 }
4918 Statement::Query(s) => s.fmt(f),
4919 Statement::Declare { stmts } => {
4920 f.write_fmt(format_args!("DECLARE "))write!(f, "DECLARE ")?;
4921 f.write_fmt(format_args!("{0}", display_separated(stmts, "; ")))write!(f, "{}", display_separated(stmts, "; "))
4922 }
4923 Statement::Fetch {
4924 name,
4925 direction,
4926 position,
4927 into,
4928 } => {
4929 f.write_fmt(format_args!("FETCH {0} {1} {2}", direction, position, name))write!(f, "FETCH {direction} {position} {name}")?;
4930
4931 if let Some(into) = into {
4932 f.write_fmt(format_args!(" INTO {0}", into))write!(f, " INTO {into}")?;
4933 }
4934
4935 Ok(())
4936 }
4937 Statement::Directory {
4938 overwrite,
4939 local,
4940 path,
4941 file_format,
4942 source,
4943 } => {
4944 f.write_fmt(format_args!("INSERT{0}{1} DIRECTORY \'{2}\'",
if *overwrite { " OVERWRITE" } else { "" },
if *local { " LOCAL" } else { "" }, path))write!(
4945 f,
4946 "INSERT{overwrite}{local} DIRECTORY '{path}'",
4947 overwrite = if *overwrite { " OVERWRITE" } else { "" },
4948 local = if *local { " LOCAL" } else { "" },
4949 path = path
4950 )?;
4951 if let Some(ref ff) = file_format {
4952 f.write_fmt(format_args!(" STORED AS {0}", ff))write!(f, " STORED AS {ff}")?
4953 }
4954 f.write_fmt(format_args!(" {0}", source))write!(f, " {source}")
4955 }
4956 Statement::Msck(msck) => msck.fmt(f),
4957 Statement::Truncate(truncate) => truncate.fmt(f),
4958 Statement::Case(stmt) => {
4959 f.write_fmt(format_args!("{0}", stmt))write!(f, "{stmt}")
4960 }
4961 Statement::If(stmt) => {
4962 f.write_fmt(format_args!("{0}", stmt))write!(f, "{stmt}")
4963 }
4964 Statement::While(stmt) => {
4965 f.write_fmt(format_args!("{0}", stmt))write!(f, "{stmt}")
4966 }
4967 Statement::Raise(stmt) => {
4968 f.write_fmt(format_args!("{0}", stmt))write!(f, "{stmt}")
4969 }
4970 Statement::AttachDatabase {
4971 schema_name,
4972 database_file_name,
4973 database,
4974 } => {
4975 let keyword = if *database { "DATABASE " } else { "" };
4976 f.write_fmt(format_args!("ATTACH {0}{1} AS {2}", keyword, database_file_name,
schema_name))write!(f, "ATTACH {keyword}{database_file_name} AS {schema_name}")
4977 }
4978 Statement::AttachDuckDBDatabase {
4979 if_not_exists,
4980 database,
4981 database_path,
4982 database_alias,
4983 attach_options,
4984 } => {
4985 f.write_fmt(format_args!("ATTACH{0}{1} {2}",
if *database { " DATABASE" } else { "" },
if *if_not_exists { " IF NOT EXISTS" } else { "" }, database_path))write!(
4986 f,
4987 "ATTACH{database}{if_not_exists} {database_path}",
4988 database = if *database { " DATABASE" } else { "" },
4989 if_not_exists = if *if_not_exists { " IF NOT EXISTS" } else { "" },
4990 )?;
4991 if let Some(alias) = database_alias {
4992 f.write_fmt(format_args!(" AS {0}", alias))write!(f, " AS {alias}")?;
4993 }
4994 if !attach_options.is_empty() {
4995 f.write_fmt(format_args!(" ({0})", display_comma_separated(attach_options)))write!(f, " ({})", display_comma_separated(attach_options))?;
4996 }
4997 Ok(())
4998 }
4999 Statement::DetachDuckDBDatabase {
5000 if_exists,
5001 database,
5002 database_alias,
5003 } => {
5004 f.write_fmt(format_args!("DETACH{0}{1} {2}",
if *database { " DATABASE" } else { "" },
if *if_exists { " IF EXISTS" } else { "" }, database_alias))write!(
5005 f,
5006 "DETACH{database}{if_exists} {database_alias}",
5007 database = if *database { " DATABASE" } else { "" },
5008 if_exists = if *if_exists { " IF EXISTS" } else { "" },
5009 )?;
5010 Ok(())
5011 }
5012 Statement::Analyze(analyze) => analyze.fmt(f),
5013 Statement::Insert(insert) => insert.fmt(f),
5014 Statement::Install {
5015 extension_name: name,
5016 } => f.write_fmt(format_args!("INSTALL {0}", name))write!(f, "INSTALL {name}"),
5017
5018 Statement::Load {
5019 extension_name: name,
5020 } => f.write_fmt(format_args!("LOAD {0}", name))write!(f, "LOAD {name}"),
5021
5022 Statement::Call(function) => f.write_fmt(format_args!("CALL {0}", function))write!(f, "CALL {function}"),
5023
5024 Statement::Copy {
5025 source,
5026 to,
5027 target,
5028 options,
5029 legacy_options,
5030 values,
5031 } => {
5032 f.write_fmt(format_args!("COPY"))write!(f, "COPY")?;
5033 match source {
5034 CopySource::Query(query) => f.write_fmt(format_args!(" ({0})", query))write!(f, " ({query})")?,
5035 CopySource::Table {
5036 table_name,
5037 columns,
5038 } => {
5039 f.write_fmt(format_args!(" {0}", table_name))write!(f, " {table_name}")?;
5040 if !columns.is_empty() {
5041 f.write_fmt(format_args!(" ({0})", display_comma_separated(columns)))write!(f, " ({})", display_comma_separated(columns))?;
5042 }
5043 }
5044 }
5045 f.write_fmt(format_args!(" {0} {1}", if *to { "TO" } else { "FROM" }, target))write!(f, " {} {}", if *to { "TO" } else { "FROM" }, target)?;
5046 if !options.is_empty() {
5047 f.write_fmt(format_args!(" ({0})", display_comma_separated(options)))write!(f, " ({})", display_comma_separated(options))?;
5048 }
5049 if !legacy_options.is_empty() {
5050 f.write_fmt(format_args!(" {0}", display_separated(legacy_options, " ")))write!(f, " {}", display_separated(legacy_options, " "))?;
5051 }
5052 if !values.is_empty() {
5053 f.write_fmt(format_args!(";\n"))writeln!(f, ";")?;
5054 let mut delim = "";
5055 for v in values {
5056 f.write_fmt(format_args!("{0}", delim))write!(f, "{delim}")?;
5057 delim = "\t";
5058 if let Some(v) = v {
5059 f.write_fmt(format_args!("{0}", v))write!(f, "{v}")?;
5060 } else {
5061 f.write_fmt(format_args!("\\N"))write!(f, "\\N")?;
5062 }
5063 }
5064 f.write_fmt(format_args!("\n\\."))write!(f, "\n\\.")?;
5065 }
5066 Ok(())
5067 }
5068 Statement::Update(update) => update.fmt(f),
5069 Statement::Delete(delete) => delete.fmt(f),
5070 Statement::Open(open) => open.fmt(f),
5071 Statement::Close { cursor } => {
5072 f.write_fmt(format_args!("CLOSE {0}", cursor))write!(f, "CLOSE {cursor}")?;
5073
5074 Ok(())
5075 }
5076 Statement::CreateDatabase {
5077 db_name,
5078 if_not_exists,
5079 location,
5080 managed_location,
5081 or_replace,
5082 transient,
5083 clone,
5084 data_retention_time_in_days,
5085 max_data_extension_time_in_days,
5086 external_volume,
5087 catalog,
5088 replace_invalid_characters,
5089 default_ddl_collation,
5090 storage_serialization_policy,
5091 comment,
5092 default_charset,
5093 default_collation,
5094 catalog_sync,
5095 catalog_sync_namespace_mode,
5096 catalog_sync_namespace_flatten_delimiter,
5097 with_tags,
5098 with_contacts,
5099 } => {
5100 f.write_fmt(format_args!("CREATE {0}{1}DATABASE {2}{3}",
if *or_replace { "OR REPLACE " } else { "" },
if *transient { "TRANSIENT " } else { "" },
if *if_not_exists { "IF NOT EXISTS " } else { "" }, db_name))write!(
5101 f,
5102 "CREATE {or_replace}{transient}DATABASE {if_not_exists}{name}",
5103 or_replace = if *or_replace { "OR REPLACE " } else { "" },
5104 transient = if *transient { "TRANSIENT " } else { "" },
5105 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
5106 name = db_name,
5107 )?;
5108
5109 if let Some(l) = location {
5110 f.write_fmt(format_args!(" LOCATION \'{0}\'", l))write!(f, " LOCATION '{l}'")?;
5111 }
5112 if let Some(ml) = managed_location {
5113 f.write_fmt(format_args!(" MANAGEDLOCATION \'{0}\'", ml))write!(f, " MANAGEDLOCATION '{ml}'")?;
5114 }
5115 if let Some(clone) = clone {
5116 f.write_fmt(format_args!(" CLONE {0}", clone))write!(f, " CLONE {clone}")?;
5117 }
5118
5119 if let Some(value) = data_retention_time_in_days {
5120 f.write_fmt(format_args!(" DATA_RETENTION_TIME_IN_DAYS = {0}", value))write!(f, " DATA_RETENTION_TIME_IN_DAYS = {value}")?;
5121 }
5122
5123 if let Some(value) = max_data_extension_time_in_days {
5124 f.write_fmt(format_args!(" MAX_DATA_EXTENSION_TIME_IN_DAYS = {0}", value))write!(f, " MAX_DATA_EXTENSION_TIME_IN_DAYS = {value}")?;
5125 }
5126
5127 if let Some(vol) = external_volume {
5128 f.write_fmt(format_args!(" EXTERNAL_VOLUME = \'{0}\'", vol))write!(f, " EXTERNAL_VOLUME = '{vol}'")?;
5129 }
5130
5131 if let Some(cat) = catalog {
5132 f.write_fmt(format_args!(" CATALOG = \'{0}\'", cat))write!(f, " CATALOG = '{cat}'")?;
5133 }
5134
5135 if let Some(true) = replace_invalid_characters {
5136 f.write_fmt(format_args!(" REPLACE_INVALID_CHARACTERS = TRUE"))write!(f, " REPLACE_INVALID_CHARACTERS = TRUE")?;
5137 } else if let Some(false) = replace_invalid_characters {
5138 f.write_fmt(format_args!(" REPLACE_INVALID_CHARACTERS = FALSE"))write!(f, " REPLACE_INVALID_CHARACTERS = FALSE")?;
5139 }
5140
5141 if let Some(collation) = default_ddl_collation {
5142 f.write_fmt(format_args!(" DEFAULT_DDL_COLLATION = \'{0}\'", collation))write!(f, " DEFAULT_DDL_COLLATION = '{collation}'")?;
5143 }
5144
5145 if let Some(policy) = storage_serialization_policy {
5146 f.write_fmt(format_args!(" STORAGE_SERIALIZATION_POLICY = {0}", policy))write!(f, " STORAGE_SERIALIZATION_POLICY = {policy}")?;
5147 }
5148
5149 if let Some(comment) = comment {
5150 f.write_fmt(format_args!(" COMMENT = \'{0}\'", comment))write!(f, " COMMENT = '{comment}'")?;
5151 }
5152
5153 if let Some(charset) = default_charset {
5154 f.write_fmt(format_args!(" DEFAULT CHARACTER SET {0}", charset))write!(f, " DEFAULT CHARACTER SET {charset}")?;
5155 }
5156
5157 if let Some(collation) = default_collation {
5158 f.write_fmt(format_args!(" DEFAULT COLLATE {0}", collation))write!(f, " DEFAULT COLLATE {collation}")?;
5159 }
5160
5161 if let Some(sync) = catalog_sync {
5162 f.write_fmt(format_args!(" CATALOG_SYNC = \'{0}\'", sync))write!(f, " CATALOG_SYNC = '{sync}'")?;
5163 }
5164
5165 if let Some(mode) = catalog_sync_namespace_mode {
5166 f.write_fmt(format_args!(" CATALOG_SYNC_NAMESPACE_MODE = {0}", mode))write!(f, " CATALOG_SYNC_NAMESPACE_MODE = {mode}")?;
5167 }
5168
5169 if let Some(delim) = catalog_sync_namespace_flatten_delimiter {
5170 f.write_fmt(format_args!(" CATALOG_SYNC_NAMESPACE_FLATTEN_DELIMITER = \'{0}\'",
delim))write!(f, " CATALOG_SYNC_NAMESPACE_FLATTEN_DELIMITER = '{delim}'")?;
5171 }
5172
5173 if let Some(tags) = with_tags {
5174 f.write_fmt(format_args!(" WITH TAG ({0})", display_comma_separated(tags)))write!(f, " WITH TAG ({})", display_comma_separated(tags))?;
5175 }
5176
5177 if let Some(contacts) = with_contacts {
5178 f.write_fmt(format_args!(" WITH CONTACT ({0})",
display_comma_separated(contacts)))write!(f, " WITH CONTACT ({})", display_comma_separated(contacts))?;
5179 }
5180 Ok(())
5181 }
5182 Statement::CreateFunction(create_function) => create_function.fmt(f),
5183 Statement::CreateDomain(create_domain) => create_domain.fmt(f),
5184 Statement::CreateTrigger(create_trigger) => create_trigger.fmt(f),
5185 Statement::DropTrigger(drop_trigger) => drop_trigger.fmt(f),
5186 Statement::CreateProcedure {
5187 name,
5188 or_alter,
5189 params,
5190 language,
5191 body,
5192 } => {
5193 f.write_fmt(format_args!("CREATE {0}PROCEDURE {1}",
if *or_alter { "OR ALTER " } else { "" }, name))write!(
5194 f,
5195 "CREATE {or_alter}PROCEDURE {name}",
5196 or_alter = if *or_alter { "OR ALTER " } else { "" },
5197 name = name
5198 )?;
5199
5200 if let Some(p) = params {
5201 if !p.is_empty() {
5202 f.write_fmt(format_args!(" ({0})", display_comma_separated(p)))write!(f, " ({})", display_comma_separated(p))?;
5203 }
5204 }
5205
5206 if let Some(language) = language {
5207 f.write_fmt(format_args!(" LANGUAGE {0}", language))write!(f, " LANGUAGE {language}")?;
5208 }
5209
5210 f.write_fmt(format_args!(" AS {0}", body))write!(f, " AS {body}")
5211 }
5212 Statement::CreateMacro {
5213 or_replace,
5214 temporary,
5215 name,
5216 args,
5217 definition,
5218 } => {
5219 f.write_fmt(format_args!("CREATE {1}{0}MACRO {2}",
if *temporary { "TEMPORARY " } else { "" },
if *or_replace { "OR REPLACE " } else { "" }, name))write!(
5220 f,
5221 "CREATE {or_replace}{temp}MACRO {name}",
5222 temp = if *temporary { "TEMPORARY " } else { "" },
5223 or_replace = if *or_replace { "OR REPLACE " } else { "" },
5224 )?;
5225 if let Some(args) = args {
5226 f.write_fmt(format_args!("({0})", display_comma_separated(args)))write!(f, "({})", display_comma_separated(args))?;
5227 }
5228 match definition {
5229 MacroDefinition::Expr(expr) => f.write_fmt(format_args!(" AS {0}", expr))write!(f, " AS {expr}")?,
5230 MacroDefinition::Table(query) => f.write_fmt(format_args!(" AS TABLE {0}", query))write!(f, " AS TABLE {query}")?,
5231 }
5232 Ok(())
5233 }
5234 Statement::CreateView(create_view) => create_view.fmt(f),
5235 Statement::CreateTable(create_table) => create_table.fmt(f),
5236 Statement::LoadData {
5237 local,
5238 inpath,
5239 overwrite,
5240 table_name,
5241 partitioned,
5242 table_format,
5243 } => {
5244 f.write_fmt(format_args!("LOAD DATA {0}INPATH \'{1}\' {2}INTO TABLE {3}",
if *local { "LOCAL " } else { "" }, inpath,
if *overwrite { "OVERWRITE " } else { "" }, table_name))write!(
5245 f,
5246 "LOAD DATA {local}INPATH '{inpath}' {overwrite}INTO TABLE {table_name}",
5247 local = if *local { "LOCAL " } else { "" },
5248 inpath = inpath,
5249 overwrite = if *overwrite { "OVERWRITE " } else { "" },
5250 table_name = table_name,
5251 )?;
5252 if let Some(ref parts) = &partitioned {
5253 if !parts.is_empty() {
5254 f.write_fmt(format_args!(" PARTITION ({0})", display_comma_separated(parts)))write!(f, " PARTITION ({})", display_comma_separated(parts))?;
5255 }
5256 }
5257 if let Some(HiveLoadDataFormat {
5258 serde,
5259 input_format,
5260 }) = &table_format
5261 {
5262 f.write_fmt(format_args!(" INPUTFORMAT {0} SERDE {1}", input_format, serde))write!(f, " INPUTFORMAT {input_format} SERDE {serde}")?;
5263 }
5264 Ok(())
5265 }
5266 Statement::CreateVirtualTable {
5267 name,
5268 if_not_exists,
5269 module_name,
5270 module_args,
5271 } => {
5272 f.write_fmt(format_args!("CREATE VIRTUAL TABLE {0}{1} USING {2}",
if *if_not_exists { "IF NOT EXISTS " } else { "" }, name,
module_name))write!(
5273 f,
5274 "CREATE VIRTUAL TABLE {if_not_exists}{name} USING {module_name}",
5275 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
5276 name = name,
5277 module_name = module_name
5278 )?;
5279 if !module_args.is_empty() {
5280 f.write_fmt(format_args!(" ({0})", display_comma_separated(module_args)))write!(f, " ({})", display_comma_separated(module_args))?;
5281 }
5282 Ok(())
5283 }
5284 Statement::CreateIndex(create_index) => create_index.fmt(f),
5285 Statement::CreateExtension(create_extension) => f.write_fmt(format_args!("{0}", create_extension))write!(f, "{create_extension}"),
5286 Statement::DropExtension(drop_extension) => f.write_fmt(format_args!("{0}", drop_extension))write!(f, "{drop_extension}"),
5287 Statement::DropOperator(drop_operator) => f.write_fmt(format_args!("{0}", drop_operator))write!(f, "{drop_operator}"),
5288 Statement::DropOperatorFamily(drop_operator_family) => {
5289 f.write_fmt(format_args!("{0}", drop_operator_family))write!(f, "{drop_operator_family}")
5290 }
5291 Statement::DropOperatorClass(drop_operator_class) => {
5292 f.write_fmt(format_args!("{0}", drop_operator_class))write!(f, "{drop_operator_class}")
5293 }
5294 Statement::CreateRole(create_role) => f.write_fmt(format_args!("{0}", create_role))write!(f, "{create_role}"),
5295 Statement::CreateSecret {
5296 or_replace,
5297 temporary,
5298 if_not_exists,
5299 name,
5300 storage_specifier,
5301 secret_type,
5302 options,
5303 } => {
5304 f.write_fmt(format_args!("CREATE {0}",
if *or_replace { "OR REPLACE " } else { "" }))write!(
5305 f,
5306 "CREATE {or_replace}",
5307 or_replace = if *or_replace { "OR REPLACE " } else { "" },
5308 )?;
5309 if let Some(t) = temporary {
5310 f.write_fmt(format_args!("{0}",
if *t { "TEMPORARY " } else { "PERSISTENT " }))write!(f, "{}", if *t { "TEMPORARY " } else { "PERSISTENT " })?;
5311 }
5312 f.write_fmt(format_args!("SECRET {0}",
if *if_not_exists { "IF NOT EXISTS " } else { "" }))write!(
5313 f,
5314 "SECRET {if_not_exists}",
5315 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
5316 )?;
5317 if let Some(n) = name {
5318 f.write_fmt(format_args!("{0} ", n))write!(f, "{n} ")?;
5319 };
5320 if let Some(s) = storage_specifier {
5321 f.write_fmt(format_args!("IN {0} ", s))write!(f, "IN {s} ")?;
5322 }
5323 f.write_fmt(format_args!("( TYPE {0}", secret_type))write!(f, "( TYPE {secret_type}",)?;
5324 if !options.is_empty() {
5325 f.write_fmt(format_args!(", {0}", display_comma_separated(options)))write!(f, ", {o}", o = display_comma_separated(options))?;
5326 }
5327 f.write_fmt(format_args!(" )"))write!(f, " )")?;
5328 Ok(())
5329 }
5330 Statement::CreateServer(stmt) => {
5331 f.write_fmt(format_args!("{0}", stmt))write!(f, "{stmt}")
5332 }
5333 Statement::CreatePolicy(policy) => f.write_fmt(format_args!("{0}", policy))write!(f, "{policy}"),
5334 Statement::CreateConnector(create_connector) => create_connector.fmt(f),
5335 Statement::CreateOperator(create_operator) => create_operator.fmt(f),
5336 Statement::CreateOperatorFamily(create_operator_family) => {
5337 create_operator_family.fmt(f)
5338 }
5339 Statement::CreateOperatorClass(create_operator_class) => create_operator_class.fmt(f),
5340 Statement::AlterTable(alter_table) => f.write_fmt(format_args!("{0}", alter_table))write!(f, "{alter_table}"),
5341 Statement::AlterIndex { name, operation } => {
5342 f.write_fmt(format_args!("ALTER INDEX {0} {1}", name, operation))write!(f, "ALTER INDEX {name} {operation}")
5343 }
5344 Statement::AlterView {
5345 name,
5346 columns,
5347 query,
5348 with_options,
5349 } => {
5350 f.write_fmt(format_args!("ALTER VIEW {0}", name))write!(f, "ALTER VIEW {name}")?;
5351 if !with_options.is_empty() {
5352 f.write_fmt(format_args!(" WITH ({0})",
display_comma_separated(with_options)))write!(f, " WITH ({})", display_comma_separated(with_options))?;
5353 }
5354 if !columns.is_empty() {
5355 f.write_fmt(format_args!(" ({0})", display_comma_separated(columns)))write!(f, " ({})", display_comma_separated(columns))?;
5356 }
5357 f.write_fmt(format_args!(" AS {0}", query))write!(f, " AS {query}")
5358 }
5359 Statement::AlterType(AlterType { name, operation }) => {
5360 f.write_fmt(format_args!("ALTER TYPE {0} {1}", name, operation))write!(f, "ALTER TYPE {name} {operation}")
5361 }
5362 Statement::AlterOperator(alter_operator) => f.write_fmt(format_args!("{0}", alter_operator))write!(f, "{alter_operator}"),
5363 Statement::AlterOperatorFamily(alter_operator_family) => {
5364 f.write_fmt(format_args!("{0}", alter_operator_family))write!(f, "{alter_operator_family}")
5365 }
5366 Statement::AlterOperatorClass(alter_operator_class) => {
5367 f.write_fmt(format_args!("{0}", alter_operator_class))write!(f, "{alter_operator_class}")
5368 }
5369 Statement::AlterRole { name, operation } => {
5370 f.write_fmt(format_args!("ALTER ROLE {0} {1}", name, operation))write!(f, "ALTER ROLE {name} {operation}")
5371 }
5372 Statement::AlterPolicy(alter_policy) => f.write_fmt(format_args!("{0}", alter_policy))write!(f, "{alter_policy}"),
5373 Statement::AlterConnector {
5374 name,
5375 properties,
5376 url,
5377 owner,
5378 } => {
5379 f.write_fmt(format_args!("ALTER CONNECTOR {0}", name))write!(f, "ALTER CONNECTOR {name}")?;
5380 if let Some(properties) = properties {
5381 f.write_fmt(format_args!(" SET DCPROPERTIES({0})",
display_comma_separated(properties)))write!(
5382 f,
5383 " SET DCPROPERTIES({})",
5384 display_comma_separated(properties)
5385 )?;
5386 }
5387 if let Some(url) = url {
5388 f.write_fmt(format_args!(" SET URL \'{0}\'", url))write!(f, " SET URL '{url}'")?;
5389 }
5390 if let Some(owner) = owner {
5391 f.write_fmt(format_args!(" SET OWNER {0}", owner))write!(f, " SET OWNER {owner}")?;
5392 }
5393 Ok(())
5394 }
5395 Statement::AlterSession {
5396 set,
5397 session_params,
5398 } => {
5399 f.write_fmt(format_args!("ALTER SESSION {0}",
if *set { "SET" } else { "UNSET" }))write!(
5400 f,
5401 "ALTER SESSION {set}",
5402 set = if *set { "SET" } else { "UNSET" }
5403 )?;
5404 if !session_params.options.is_empty() {
5405 if *set {
5406 f.write_fmt(format_args!(" {0}", session_params))write!(f, " {session_params}")?;
5407 } else {
5408 let options = session_params
5409 .options
5410 .iter()
5411 .map(|p| p.option_name.clone())
5412 .collect::<Vec<_>>();
5413 f.write_fmt(format_args!(" {0}", display_separated(&options, ", ")))write!(f, " {}", display_separated(&options, ", "))?;
5414 }
5415 }
5416 Ok(())
5417 }
5418 Statement::Drop {
5419 object_type,
5420 if_exists,
5421 names,
5422 cascade,
5423 restrict,
5424 purge,
5425 temporary,
5426 table,
5427 } => {
5428 f.write_fmt(format_args!("DROP {0}{1}{2} {3}{4}{5}{6}",
if *temporary { "TEMPORARY " } else { "" }, object_type,
if *if_exists { " IF EXISTS" } else { "" },
display_comma_separated(names),
if *cascade { " CASCADE" } else { "" },
if *restrict { " RESTRICT" } else { "" },
if *purge { " PURGE" } else { "" }))write!(
5429 f,
5430 "DROP {}{}{} {}{}{}{}",
5431 if *temporary { "TEMPORARY " } else { "" },
5432 object_type,
5433 if *if_exists { " IF EXISTS" } else { "" },
5434 display_comma_separated(names),
5435 if *cascade { " CASCADE" } else { "" },
5436 if *restrict { " RESTRICT" } else { "" },
5437 if *purge { " PURGE" } else { "" },
5438 )?;
5439 if let Some(table_name) = table.as_ref() {
5440 f.write_fmt(format_args!(" ON {0}", table_name))write!(f, " ON {table_name}")?;
5441 };
5442 Ok(())
5443 }
5444 Statement::DropFunction(drop_function) => f.write_fmt(format_args!("{0}", drop_function))write!(f, "{drop_function}"),
5445 Statement::DropDomain(DropDomain {
5446 if_exists,
5447 name,
5448 drop_behavior,
5449 }) => {
5450 f.write_fmt(format_args!("DROP DOMAIN{0} {1}",
if *if_exists { " IF EXISTS" } else { "" }, name))write!(
5451 f,
5452 "DROP DOMAIN{} {name}",
5453 if *if_exists { " IF EXISTS" } else { "" },
5454 )?;
5455 if let Some(op) = drop_behavior {
5456 f.write_fmt(format_args!(" {0}", op))write!(f, " {op}")?;
5457 }
5458 Ok(())
5459 }
5460 Statement::DropProcedure {
5461 if_exists,
5462 proc_desc,
5463 drop_behavior,
5464 } => {
5465 f.write_fmt(format_args!("DROP PROCEDURE{0} {1}",
if *if_exists { " IF EXISTS" } else { "" },
display_comma_separated(proc_desc)))write!(
5466 f,
5467 "DROP PROCEDURE{} {}",
5468 if *if_exists { " IF EXISTS" } else { "" },
5469 display_comma_separated(proc_desc),
5470 )?;
5471 if let Some(op) = drop_behavior {
5472 f.write_fmt(format_args!(" {0}", op))write!(f, " {op}")?;
5473 }
5474 Ok(())
5475 }
5476 Statement::DropSecret {
5477 if_exists,
5478 temporary,
5479 name,
5480 storage_specifier,
5481 } => {
5482 f.write_fmt(format_args!("DROP "))write!(f, "DROP ")?;
5483 if let Some(t) = temporary {
5484 f.write_fmt(format_args!("{0}",
if *t { "TEMPORARY " } else { "PERSISTENT " }))write!(f, "{}", if *t { "TEMPORARY " } else { "PERSISTENT " })?;
5485 }
5486 f.write_fmt(format_args!("SECRET {0}{1}",
if *if_exists { "IF EXISTS " } else { "" }, name))write!(
5487 f,
5488 "SECRET {if_exists}{name}",
5489 if_exists = if *if_exists { "IF EXISTS " } else { "" },
5490 )?;
5491 if let Some(s) = storage_specifier {
5492 f.write_fmt(format_args!(" FROM {0}", s))write!(f, " FROM {s}")?;
5493 }
5494 Ok(())
5495 }
5496 Statement::DropPolicy(policy) => f.write_fmt(format_args!("{0}", policy))write!(f, "{policy}"),
5497 Statement::DropConnector { if_exists, name } => {
5498 f.write_fmt(format_args!("DROP CONNECTOR {0}{1}",
if *if_exists { "IF EXISTS " } else { "" }, name))write!(
5499 f,
5500 "DROP CONNECTOR {if_exists}{name}",
5501 if_exists = if *if_exists { "IF EXISTS " } else { "" }
5502 )?;
5503 Ok(())
5504 }
5505 Statement::Discard { object_type } => {
5506 f.write_fmt(format_args!("DISCARD {0}", object_type))write!(f, "DISCARD {object_type}")?;
5507 Ok(())
5508 }
5509 Self::Set(set) => f.write_fmt(format_args!("{0}", set))write!(f, "{set}"),
5510 Statement::ShowVariable { variable } => {
5511 f.write_fmt(format_args!("SHOW"))write!(f, "SHOW")?;
5512 if !variable.is_empty() {
5513 f.write_fmt(format_args!(" {0}", display_separated(variable, " ")))write!(f, " {}", display_separated(variable, " "))?;
5514 }
5515 Ok(())
5516 }
5517 Statement::ShowStatus {
5518 filter,
5519 global,
5520 session,
5521 } => {
5522 f.write_fmt(format_args!("SHOW"))write!(f, "SHOW")?;
5523 if *global {
5524 f.write_fmt(format_args!(" GLOBAL"))write!(f, " GLOBAL")?;
5525 }
5526 if *session {
5527 f.write_fmt(format_args!(" SESSION"))write!(f, " SESSION")?;
5528 }
5529 f.write_fmt(format_args!(" STATUS"))write!(f, " STATUS")?;
5530 if filter.is_some() {
5531 f.write_fmt(format_args!(" {0}", filter.as_ref().unwrap()))write!(f, " {}", filter.as_ref().unwrap())?;
5532 }
5533 Ok(())
5534 }
5535 Statement::ShowVariables {
5536 filter,
5537 global,
5538 session,
5539 } => {
5540 f.write_fmt(format_args!("SHOW"))write!(f, "SHOW")?;
5541 if *global {
5542 f.write_fmt(format_args!(" GLOBAL"))write!(f, " GLOBAL")?;
5543 }
5544 if *session {
5545 f.write_fmt(format_args!(" SESSION"))write!(f, " SESSION")?;
5546 }
5547 f.write_fmt(format_args!(" VARIABLES"))write!(f, " VARIABLES")?;
5548 if filter.is_some() {
5549 f.write_fmt(format_args!(" {0}", filter.as_ref().unwrap()))write!(f, " {}", filter.as_ref().unwrap())?;
5550 }
5551 Ok(())
5552 }
5553 Statement::ShowCreate { obj_type, obj_name } => {
5554 f.write_fmt(format_args!("SHOW CREATE {0} {1}", obj_type, obj_name))write!(f, "SHOW CREATE {obj_type} {obj_name}",)?;
5555 Ok(())
5556 }
5557 Statement::ShowColumns {
5558 extended,
5559 full,
5560 show_options,
5561 } => {
5562 f.write_fmt(format_args!("SHOW {0}{1}COLUMNS{2}",
if *extended { "EXTENDED " } else { "" },
if *full { "FULL " } else { "" }, show_options))write!(
5563 f,
5564 "SHOW {extended}{full}COLUMNS{show_options}",
5565 extended = if *extended { "EXTENDED " } else { "" },
5566 full = if *full { "FULL " } else { "" },
5567 )?;
5568 Ok(())
5569 }
5570 Statement::ShowDatabases {
5571 terse,
5572 history,
5573 show_options,
5574 } => {
5575 f.write_fmt(format_args!("SHOW {0}DATABASES{1}{2}",
if *terse { "TERSE " } else { "" },
if *history { " HISTORY" } else { "" }, show_options))write!(
5576 f,
5577 "SHOW {terse}DATABASES{history}{show_options}",
5578 terse = if *terse { "TERSE " } else { "" },
5579 history = if *history { " HISTORY" } else { "" },
5580 )?;
5581 Ok(())
5582 }
5583 Statement::ShowSchemas {
5584 terse,
5585 history,
5586 show_options,
5587 } => {
5588 f.write_fmt(format_args!("SHOW {0}SCHEMAS{1}{2}",
if *terse { "TERSE " } else { "" },
if *history { " HISTORY" } else { "" }, show_options))write!(
5589 f,
5590 "SHOW {terse}SCHEMAS{history}{show_options}",
5591 terse = if *terse { "TERSE " } else { "" },
5592 history = if *history { " HISTORY" } else { "" },
5593 )?;
5594 Ok(())
5595 }
5596 Statement::ShowObjects(ShowObjects {
5597 terse,
5598 show_options,
5599 }) => {
5600 f.write_fmt(format_args!("SHOW {0}OBJECTS{1}",
if *terse { "TERSE " } else { "" }, show_options))write!(
5601 f,
5602 "SHOW {terse}OBJECTS{show_options}",
5603 terse = if *terse { "TERSE " } else { "" },
5604 )?;
5605 Ok(())
5606 }
5607 Statement::ShowTables {
5608 terse,
5609 history,
5610 extended,
5611 full,
5612 external,
5613 show_options,
5614 } => {
5615 f.write_fmt(format_args!("SHOW {0}{1}{2}{3}TABLES{4}{5}",
if *terse { "TERSE " } else { "" },
if *extended { "EXTENDED " } else { "" },
if *full { "FULL " } else { "" },
if *external { "EXTERNAL " } else { "" },
if *history { " HISTORY" } else { "" }, show_options))write!(
5616 f,
5617 "SHOW {terse}{extended}{full}{external}TABLES{history}{show_options}",
5618 terse = if *terse { "TERSE " } else { "" },
5619 extended = if *extended { "EXTENDED " } else { "" },
5620 full = if *full { "FULL " } else { "" },
5621 external = if *external { "EXTERNAL " } else { "" },
5622 history = if *history { " HISTORY" } else { "" },
5623 )?;
5624 Ok(())
5625 }
5626 Statement::ShowViews {
5627 terse,
5628 materialized,
5629 show_options,
5630 } => {
5631 f.write_fmt(format_args!("SHOW {0}{1}VIEWS{2}",
if *terse { "TERSE " } else { "" },
if *materialized { "MATERIALIZED " } else { "" }, show_options))write!(
5632 f,
5633 "SHOW {terse}{materialized}VIEWS{show_options}",
5634 terse = if *terse { "TERSE " } else { "" },
5635 materialized = if *materialized { "MATERIALIZED " } else { "" }
5636 )?;
5637 Ok(())
5638 }
5639 Statement::ShowFunctions { filter } => {
5640 f.write_fmt(format_args!("SHOW FUNCTIONS"))write!(f, "SHOW FUNCTIONS")?;
5641 if let Some(filter) = filter {
5642 f.write_fmt(format_args!(" {0}", filter))write!(f, " {filter}")?;
5643 }
5644 Ok(())
5645 }
5646 Statement::Use(use_expr) => use_expr.fmt(f),
5647 Statement::ShowCollation { filter } => {
5648 f.write_fmt(format_args!("SHOW COLLATION"))write!(f, "SHOW COLLATION")?;
5649 if let Some(filter) = filter {
5650 f.write_fmt(format_args!(" {0}", filter))write!(f, " {filter}")?;
5651 }
5652 Ok(())
5653 }
5654 Statement::ShowCharset(show_stm) => show_stm.fmt(f),
5655 Statement::StartTransaction {
5656 modes,
5657 begin: syntax_begin,
5658 transaction,
5659 modifier,
5660 statements,
5661 exception,
5662 has_end_keyword,
5663 } => {
5664 if *syntax_begin {
5665 if let Some(modifier) = *modifier {
5666 f.write_fmt(format_args!("BEGIN {0}", modifier))write!(f, "BEGIN {modifier}")?;
5667 } else {
5668 f.write_fmt(format_args!("BEGIN"))write!(f, "BEGIN")?;
5669 }
5670 } else {
5671 f.write_fmt(format_args!("START"))write!(f, "START")?;
5672 }
5673 if let Some(transaction) = transaction {
5674 f.write_fmt(format_args!(" {0}", transaction))write!(f, " {transaction}")?;
5675 }
5676 if !modes.is_empty() {
5677 f.write_fmt(format_args!(" {0}", display_comma_separated(modes)))write!(f, " {}", display_comma_separated(modes))?;
5678 }
5679 if !statements.is_empty() {
5680 f.write_fmt(format_args!(" "))write!(f, " ")?;
5681 format_statement_list(f, statements)?;
5682 }
5683 if let Some(exception_when) = exception {
5684 f.write_fmt(format_args!(" EXCEPTION"))write!(f, " EXCEPTION")?;
5685 for when in exception_when {
5686 f.write_fmt(format_args!(" {0}", when))write!(f, " {when}")?;
5687 }
5688 }
5689 if *has_end_keyword {
5690 f.write_fmt(format_args!(" END"))write!(f, " END")?;
5691 }
5692 Ok(())
5693 }
5694 Statement::Commit {
5695 chain,
5696 end: end_syntax,
5697 modifier,
5698 } => {
5699 if *end_syntax {
5700 f.write_fmt(format_args!("END"))write!(f, "END")?;
5701 if let Some(modifier) = *modifier {
5702 f.write_fmt(format_args!(" {0}", modifier))write!(f, " {modifier}")?;
5703 }
5704 if *chain {
5705 f.write_fmt(format_args!(" AND CHAIN"))write!(f, " AND CHAIN")?;
5706 }
5707 } else {
5708 f.write_fmt(format_args!("COMMIT{0}", if *chain { " AND CHAIN" } else { "" }))write!(f, "COMMIT{}", if *chain { " AND CHAIN" } else { "" })?;
5709 }
5710 Ok(())
5711 }
5712 Statement::Rollback { chain, savepoint } => {
5713 f.write_fmt(format_args!("ROLLBACK"))write!(f, "ROLLBACK")?;
5714
5715 if *chain {
5716 f.write_fmt(format_args!(" AND CHAIN"))write!(f, " AND CHAIN")?;
5717 }
5718
5719 if let Some(savepoint) = savepoint {
5720 f.write_fmt(format_args!(" TO SAVEPOINT {0}", savepoint))write!(f, " TO SAVEPOINT {savepoint}")?;
5721 }
5722
5723 Ok(())
5724 }
5725 Statement::CreateSchema {
5726 schema_name,
5727 if_not_exists,
5728 with,
5729 options,
5730 default_collate_spec,
5731 clone,
5732 } => {
5733 f.write_fmt(format_args!("CREATE SCHEMA {0}{1}",
if *if_not_exists { "IF NOT EXISTS " } else { "" }, schema_name))write!(
5734 f,
5735 "CREATE SCHEMA {if_not_exists}{name}",
5736 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
5737 name = schema_name
5738 )?;
5739
5740 if let Some(collate) = default_collate_spec {
5741 f.write_fmt(format_args!(" DEFAULT COLLATE {0}", collate))write!(f, " DEFAULT COLLATE {collate}")?;
5742 }
5743
5744 if let Some(with) = with {
5745 f.write_fmt(format_args!(" WITH ({0})", display_comma_separated(with)))write!(f, " WITH ({})", display_comma_separated(with))?;
5746 }
5747
5748 if let Some(options) = options {
5749 f.write_fmt(format_args!(" OPTIONS({0})", display_comma_separated(options)))write!(f, " OPTIONS({})", display_comma_separated(options))?;
5750 }
5751
5752 if let Some(clone) = clone {
5753 f.write_fmt(format_args!(" CLONE {0}", clone))write!(f, " CLONE {clone}")?;
5754 }
5755 Ok(())
5756 }
5757 Statement::Assert { condition, message } => {
5758 f.write_fmt(format_args!("ASSERT {0}", condition))write!(f, "ASSERT {condition}")?;
5759 if let Some(m) = message {
5760 f.write_fmt(format_args!(" AS {0}", m))write!(f, " AS {m}")?;
5761 }
5762 Ok(())
5763 }
5764 Statement::Grant(grant) => f.write_fmt(format_args!("{0}", grant))write!(f, "{grant}"),
5765 Statement::Deny(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
5766 Statement::Revoke(revoke) => f.write_fmt(format_args!("{0}", revoke))write!(f, "{revoke}"),
5767 Statement::Deallocate { name, prepare } => f.write_fmt(format_args!("DEALLOCATE {0}{1}",
if *prepare { "PREPARE " } else { "" }, name))write!(
5768 f,
5769 "DEALLOCATE {prepare}{name}",
5770 prepare = if *prepare { "PREPARE " } else { "" },
5771 name = name,
5772 ),
5773 Statement::Execute {
5774 name,
5775 parameters,
5776 has_parentheses,
5777 immediate,
5778 into,
5779 using,
5780 output,
5781 default,
5782 } => {
5783 let (open, close) = if *has_parentheses {
5784 ("(", ")")
5785 } else {
5786 (if parameters.is_empty() { "" } else { " " }, "")
5787 };
5788 f.write_fmt(format_args!("EXECUTE"))write!(f, "EXECUTE")?;
5789 if *immediate {
5790 f.write_fmt(format_args!(" IMMEDIATE"))write!(f, " IMMEDIATE")?;
5791 }
5792 if let Some(name) = name {
5793 f.write_fmt(format_args!(" {0}", name))write!(f, " {name}")?;
5794 }
5795 f.write_fmt(format_args!("{1}{0}{2}", display_comma_separated(parameters),
open, close))write!(f, "{open}{}{close}", display_comma_separated(parameters),)?;
5796 if !into.is_empty() {
5797 f.write_fmt(format_args!(" INTO {0}", display_comma_separated(into)))write!(f, " INTO {}", display_comma_separated(into))?;
5798 }
5799 if !using.is_empty() {
5800 f.write_fmt(format_args!(" USING {0}", display_comma_separated(using)))write!(f, " USING {}", display_comma_separated(using))?;
5801 };
5802 if *output {
5803 f.write_fmt(format_args!(" OUTPUT"))write!(f, " OUTPUT")?;
5804 }
5805 if *default {
5806 f.write_fmt(format_args!(" DEFAULT"))write!(f, " DEFAULT")?;
5807 }
5808 Ok(())
5809 }
5810 Statement::Prepare {
5811 name,
5812 data_types,
5813 statement,
5814 } => {
5815 f.write_fmt(format_args!("PREPARE {0} ", name))write!(f, "PREPARE {name} ")?;
5816 if !data_types.is_empty() {
5817 f.write_fmt(format_args!("({0}) ", display_comma_separated(data_types)))write!(f, "({}) ", display_comma_separated(data_types))?;
5818 }
5819 f.write_fmt(format_args!("AS {0}", statement))write!(f, "AS {statement}")
5820 }
5821 Statement::Comment {
5822 object_type,
5823 object_name,
5824 comment,
5825 if_exists,
5826 } => {
5827 f.write_fmt(format_args!("COMMENT "))write!(f, "COMMENT ")?;
5828 if *if_exists {
5829 f.write_fmt(format_args!("IF EXISTS "))write!(f, "IF EXISTS ")?
5830 };
5831 f.write_fmt(format_args!("ON {0} {1} IS ", object_type, object_name))write!(f, "ON {object_type} {object_name} IS ")?;
5832 if let Some(c) = comment {
5833 f.write_fmt(format_args!("\'{0}\'", c))write!(f, "'{c}'")
5834 } else {
5835 f.write_fmt(format_args!("NULL"))write!(f, "NULL")
5836 }
5837 }
5838 Statement::Savepoint { name } => {
5839 f.write_fmt(format_args!("SAVEPOINT "))write!(f, "SAVEPOINT ")?;
5840 f.write_fmt(format_args!("{0}", name))write!(f, "{name}")
5841 }
5842 Statement::ReleaseSavepoint { name } => {
5843 f.write_fmt(format_args!("RELEASE SAVEPOINT {0}", name))write!(f, "RELEASE SAVEPOINT {name}")
5844 }
5845 Statement::Merge(merge) => merge.fmt(f),
5846 Statement::Cache {
5847 table_name,
5848 table_flag,
5849 has_as,
5850 options,
5851 query,
5852 } => {
5853 if let Some(table_flag) = table_flag {
5854 f.write_fmt(format_args!("CACHE {0} TABLE {1}", table_flag, table_name))write!(f, "CACHE {table_flag} TABLE {table_name}")?;
5855 } else {
5856 f.write_fmt(format_args!("CACHE TABLE {0}", table_name))write!(f, "CACHE TABLE {table_name}")?;
5857 }
5858
5859 if !options.is_empty() {
5860 f.write_fmt(format_args!(" OPTIONS({0})", display_comma_separated(options)))write!(f, " OPTIONS({})", display_comma_separated(options))?;
5861 }
5862
5863 match (*has_as, query) {
5864 (true, Some(query)) => f.write_fmt(format_args!(" AS {0}", query))write!(f, " AS {query}"),
5865 (true, None) => f.write_str(" AS"),
5866 (false, Some(query)) => f.write_fmt(format_args!(" {0}", query))write!(f, " {query}"),
5867 (false, None) => Ok(()),
5868 }
5869 }
5870 Statement::UNCache {
5871 table_name,
5872 if_exists,
5873 } => {
5874 if *if_exists {
5875 f.write_fmt(format_args!("UNCACHE TABLE IF EXISTS {0}", table_name))write!(f, "UNCACHE TABLE IF EXISTS {table_name}")
5876 } else {
5877 f.write_fmt(format_args!("UNCACHE TABLE {0}", table_name))write!(f, "UNCACHE TABLE {table_name}")
5878 }
5879 }
5880 Statement::CreateSequence {
5881 temporary,
5882 if_not_exists,
5883 name,
5884 data_type,
5885 sequence_options,
5886 owned_by,
5887 } => {
5888 let as_type: String = if let Some(dt) = data_type.as_ref() {
5889 [" AS ", &dt.to_string()].concat()
5892 } else {
5893 "".to_string()
5894 };
5895 f.write_fmt(format_args!("CREATE {1}SEQUENCE {0}{2}{3}",
if *if_not_exists { "IF NOT EXISTS " } else { "" },
if *temporary { "TEMPORARY " } else { "" }, name, as_type))write!(
5896 f,
5897 "CREATE {temporary}SEQUENCE {if_not_exists}{name}{as_type}",
5898 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
5899 temporary = if *temporary { "TEMPORARY " } else { "" },
5900 name = name,
5901 as_type = as_type
5902 )?;
5903 for sequence_option in sequence_options {
5904 f.write_fmt(format_args!("{0}", sequence_option))write!(f, "{sequence_option}")?;
5905 }
5906 if let Some(ob) = owned_by.as_ref() {
5907 f.write_fmt(format_args!(" OWNED BY {0}", ob))write!(f, " OWNED BY {ob}")?;
5908 }
5909 f.write_fmt(format_args!(""))write!(f, "")
5910 }
5911 Statement::CreateStage {
5912 or_replace,
5913 temporary,
5914 if_not_exists,
5915 name,
5916 stage_params,
5917 directory_table_params,
5918 file_format,
5919 copy_options,
5920 comment,
5921 ..
5922 } => {
5923 f.write_fmt(format_args!("CREATE {1}{0}STAGE {2}{3}{4}",
if *temporary { "TEMPORARY " } else { "" },
if *or_replace { "OR REPLACE " } else { "" },
if *if_not_exists { "IF NOT EXISTS " } else { "" }, name,
stage_params))write!(
5924 f,
5925 "CREATE {or_replace}{temp}STAGE {if_not_exists}{name}{stage_params}",
5926 temp = if *temporary { "TEMPORARY " } else { "" },
5927 or_replace = if *or_replace { "OR REPLACE " } else { "" },
5928 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
5929 )?;
5930 if !directory_table_params.options.is_empty() {
5931 f.write_fmt(format_args!(" DIRECTORY=({0})", directory_table_params))write!(f, " DIRECTORY=({directory_table_params})")?;
5932 }
5933 if !file_format.options.is_empty() {
5934 f.write_fmt(format_args!(" FILE_FORMAT=({0})", file_format))write!(f, " FILE_FORMAT=({file_format})")?;
5935 }
5936 if !copy_options.options.is_empty() {
5937 f.write_fmt(format_args!(" COPY_OPTIONS=({0})", copy_options))write!(f, " COPY_OPTIONS=({copy_options})")?;
5938 }
5939 if comment.is_some() {
5940 f.write_fmt(format_args!(" COMMENT=\'{0}\'", comment.as_ref().unwrap()))write!(f, " COMMENT='{}'", comment.as_ref().unwrap())?;
5941 }
5942 Ok(())
5943 }
5944 Statement::CopyIntoSnowflake {
5945 kind,
5946 into,
5947 into_columns,
5948 from_obj,
5949 from_obj_alias,
5950 stage_params,
5951 from_transformations,
5952 from_query,
5953 files,
5954 pattern,
5955 file_format,
5956 copy_options,
5957 validation_mode,
5958 partition,
5959 } => {
5960 f.write_fmt(format_args!("COPY INTO {0}", into))write!(f, "COPY INTO {into}")?;
5961 if let Some(into_columns) = into_columns {
5962 f.write_fmt(format_args!(" ({0})", display_comma_separated(into_columns)))write!(f, " ({})", display_comma_separated(into_columns))?;
5963 }
5964 if let Some(from_transformations) = from_transformations {
5965 if let Some(from_stage) = from_obj {
5967 f.write_fmt(format_args!(" FROM (SELECT {0} FROM {1}{2}",
display_separated(from_transformations, ", "), from_stage,
stage_params))write!(
5968 f,
5969 " FROM (SELECT {} FROM {}{}",
5970 display_separated(from_transformations, ", "),
5971 from_stage,
5972 stage_params
5973 )?;
5974 }
5975 if let Some(from_obj_alias) = from_obj_alias {
5976 f.write_fmt(format_args!(" AS {0}", from_obj_alias))write!(f, " AS {from_obj_alias}")?;
5977 }
5978 f.write_fmt(format_args!(")"))write!(f, ")")?;
5979 } else if let Some(from_obj) = from_obj {
5980 f.write_fmt(format_args!(" FROM {0}{1}", from_obj, stage_params))write!(f, " FROM {from_obj}{stage_params}")?;
5982 if let Some(from_obj_alias) = from_obj_alias {
5983 f.write_fmt(format_args!(" AS {0}", from_obj_alias))write!(f, " AS {from_obj_alias}")?;
5984 }
5985 } else if let Some(from_query) = from_query {
5986 f.write_fmt(format_args!(" FROM ({0})", from_query))write!(f, " FROM ({from_query})")?;
5988 }
5989
5990 if let Some(files) = files {
5991 f.write_fmt(format_args!(" FILES = (\'{0}\')",
display_separated(files, "', '")))write!(f, " FILES = ('{}')", display_separated(files, "', '"))?;
5992 }
5993 if let Some(pattern) = pattern {
5994 f.write_fmt(format_args!(" PATTERN = \'{0}\'", pattern))write!(f, " PATTERN = '{pattern}'")?;
5995 }
5996 if let Some(partition) = partition {
5997 f.write_fmt(format_args!(" PARTITION BY {0}", partition))write!(f, " PARTITION BY {partition}")?;
5998 }
5999 if !file_format.options.is_empty() {
6000 f.write_fmt(format_args!(" FILE_FORMAT=({0})", file_format))write!(f, " FILE_FORMAT=({file_format})")?;
6001 }
6002 if !copy_options.options.is_empty() {
6003 match kind {
6004 CopyIntoSnowflakeKind::Table => {
6005 f.write_fmt(format_args!(" COPY_OPTIONS=({0})", copy_options))write!(f, " COPY_OPTIONS=({copy_options})")?
6006 }
6007 CopyIntoSnowflakeKind::Location => f.write_fmt(format_args!(" {0}", copy_options))write!(f, " {copy_options}")?,
6008 }
6009 }
6010 if let Some(validation_mode) = validation_mode {
6011 f.write_fmt(format_args!(" VALIDATION_MODE = {0}", validation_mode))write!(f, " VALIDATION_MODE = {validation_mode}")?;
6012 }
6013 Ok(())
6014 }
6015 Statement::CreateType {
6016 name,
6017 representation,
6018 } => {
6019 f.write_fmt(format_args!("CREATE TYPE {0}", name))write!(f, "CREATE TYPE {name}")?;
6020 if let Some(repr) = representation {
6021 f.write_fmt(format_args!(" {0}", repr))write!(f, " {repr}")?;
6022 }
6023 Ok(())
6024 }
6025 Statement::Pragma { name, value, is_eq } => {
6026 f.write_fmt(format_args!("PRAGMA {0}", name))write!(f, "PRAGMA {name}")?;
6027 if value.is_some() {
6028 let val = value.as_ref().unwrap();
6029 if *is_eq {
6030 f.write_fmt(format_args!(" = {0}", val))write!(f, " = {val}")?;
6031 } else {
6032 f.write_fmt(format_args!("({0})", val))write!(f, "({val})")?;
6033 }
6034 }
6035 Ok(())
6036 }
6037 Statement::LockTables { tables } => {
6038 f.write_fmt(format_args!("LOCK TABLES {0}", display_comma_separated(tables)))write!(f, "LOCK TABLES {}", display_comma_separated(tables))
6039 }
6040 Statement::UnlockTables => {
6041 f.write_fmt(format_args!("UNLOCK TABLES"))write!(f, "UNLOCK TABLES")
6042 }
6043 Statement::Unload {
6044 query,
6045 query_text,
6046 to,
6047 auth,
6048 with,
6049 options,
6050 } => {
6051 f.write_fmt(format_args!("UNLOAD("))write!(f, "UNLOAD(")?;
6052 if let Some(query) = query {
6053 f.write_fmt(format_args!("{0}", query))write!(f, "{query}")?;
6054 }
6055 if let Some(query_text) = query_text {
6056 f.write_fmt(format_args!("\'{0}\'", query_text))write!(f, "'{query_text}'")?;
6057 }
6058 f.write_fmt(format_args!(") TO {0}", to))write!(f, ") TO {to}")?;
6059 if let Some(auth) = auth {
6060 f.write_fmt(format_args!(" IAM_ROLE {0}", auth))write!(f, " IAM_ROLE {auth}")?;
6061 }
6062 if !with.is_empty() {
6063 f.write_fmt(format_args!(" WITH ({0})", display_comma_separated(with)))write!(f, " WITH ({})", display_comma_separated(with))?;
6064 }
6065 if !options.is_empty() {
6066 f.write_fmt(format_args!(" {0}", display_separated(options, " ")))write!(f, " {}", display_separated(options, " "))?;
6067 }
6068 Ok(())
6069 }
6070 Statement::OptimizeTable {
6071 name,
6072 on_cluster,
6073 partition,
6074 include_final,
6075 deduplicate,
6076 } => {
6077 f.write_fmt(format_args!("OPTIMIZE TABLE {0}", name))write!(f, "OPTIMIZE TABLE {name}")?;
6078 if let Some(on_cluster) = on_cluster {
6079 f.write_fmt(format_args!(" ON CLUSTER {0}", on_cluster))write!(f, " ON CLUSTER {on_cluster}")?;
6080 }
6081 if let Some(partition) = partition {
6082 f.write_fmt(format_args!(" {0}", partition))write!(f, " {partition}")?;
6083 }
6084 if *include_final {
6085 f.write_fmt(format_args!(" FINAL"))write!(f, " FINAL")?;
6086 }
6087 if let Some(deduplicate) = deduplicate {
6088 f.write_fmt(format_args!(" {0}", deduplicate))write!(f, " {deduplicate}")?;
6089 }
6090 Ok(())
6091 }
6092 Statement::LISTEN { channel } => {
6093 f.write_fmt(format_args!("LISTEN {0}", channel))write!(f, "LISTEN {channel}")?;
6094 Ok(())
6095 }
6096 Statement::UNLISTEN { channel } => {
6097 f.write_fmt(format_args!("UNLISTEN {0}", channel))write!(f, "UNLISTEN {channel}")?;
6098 Ok(())
6099 }
6100 Statement::NOTIFY { channel, payload } => {
6101 f.write_fmt(format_args!("NOTIFY {0}", channel))write!(f, "NOTIFY {channel}")?;
6102 if let Some(payload) = payload {
6103 f.write_fmt(format_args!(", \'{0}\'", payload))write!(f, ", '{payload}'")?;
6104 }
6105 Ok(())
6106 }
6107 Statement::RenameTable(rename_tables) => {
6108 f.write_fmt(format_args!("RENAME TABLE {0}",
display_comma_separated(rename_tables)))write!(f, "RENAME TABLE {}", display_comma_separated(rename_tables))
6109 }
6110 Statement::RaisError {
6111 message,
6112 severity,
6113 state,
6114 arguments,
6115 options,
6116 } => {
6117 f.write_fmt(format_args!("RAISERROR({0}, {1}, {2}", message, severity, state))write!(f, "RAISERROR({message}, {severity}, {state}")?;
6118 if !arguments.is_empty() {
6119 f.write_fmt(format_args!(", {0}", display_comma_separated(arguments)))write!(f, ", {}", display_comma_separated(arguments))?;
6120 }
6121 f.write_fmt(format_args!(")"))write!(f, ")")?;
6122 if !options.is_empty() {
6123 f.write_fmt(format_args!(" WITH {0}", display_comma_separated(options)))write!(f, " WITH {}", display_comma_separated(options))?;
6124 }
6125 Ok(())
6126 }
6127 Statement::Print(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
6128 Statement::Return(r) => f.write_fmt(format_args!("{0}", r))write!(f, "{r}"),
6129 Statement::List(command) => f.write_fmt(format_args!("LIST {0}", command))write!(f, "LIST {command}"),
6130 Statement::Remove(command) => f.write_fmt(format_args!("REMOVE {0}", command))write!(f, "REMOVE {command}"),
6131 Statement::ExportData(e) => f.write_fmt(format_args!("{0}", e))write!(f, "{e}"),
6132 Statement::CreateUser(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
6133 Statement::AlterSchema(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
6134 Statement::Vacuum(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
6135 Statement::AlterUser(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
6136 Statement::Reset(s) => f.write_fmt(format_args!("{0}", s))write!(f, "{s}"),
6137 }
6138 }
6139}
6140
6141#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SequenceOptions {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
SequenceOptions::IncrementBy(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"IncrementBy", __self_0, &__self_1),
SequenceOptions::MinValue(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"MinValue", &__self_0),
SequenceOptions::MaxValue(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"MaxValue", &__self_0),
SequenceOptions::StartWith(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"StartWith", __self_0, &__self_1),
SequenceOptions::Cache(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Cache",
&__self_0),
SequenceOptions::Cycle(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Cycle",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SequenceOptions {
#[inline]
fn clone(&self) -> SequenceOptions {
match self {
SequenceOptions::IncrementBy(__self_0, __self_1) =>
SequenceOptions::IncrementBy(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
SequenceOptions::MinValue(__self_0) =>
SequenceOptions::MinValue(::core::clone::Clone::clone(__self_0)),
SequenceOptions::MaxValue(__self_0) =>
SequenceOptions::MaxValue(::core::clone::Clone::clone(__self_0)),
SequenceOptions::StartWith(__self_0, __self_1) =>
SequenceOptions::StartWith(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
SequenceOptions::Cache(__self_0) =>
SequenceOptions::Cache(::core::clone::Clone::clone(__self_0)),
SequenceOptions::Cycle(__self_0) =>
SequenceOptions::Cycle(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SequenceOptions {
#[inline]
fn eq(&self, other: &SequenceOptions) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(SequenceOptions::IncrementBy(__self_0, __self_1),
SequenceOptions::IncrementBy(__arg1_0, __arg1_1)) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
(SequenceOptions::MinValue(__self_0),
SequenceOptions::MinValue(__arg1_0)) =>
__self_0 == __arg1_0,
(SequenceOptions::MaxValue(__self_0),
SequenceOptions::MaxValue(__arg1_0)) =>
__self_0 == __arg1_0,
(SequenceOptions::StartWith(__self_0, __self_1),
SequenceOptions::StartWith(__arg1_0, __arg1_1)) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
(SequenceOptions::Cache(__self_0),
SequenceOptions::Cache(__arg1_0)) => __self_0 == __arg1_0,
(SequenceOptions::Cycle(__self_0),
SequenceOptions::Cycle(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SequenceOptions {
#[inline]
fn partial_cmp(&self, other: &SequenceOptions)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SequenceOptions {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SequenceOptions {
#[inline]
fn cmp(&self, other: &SequenceOptions) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(SequenceOptions::IncrementBy(__self_0, __self_1),
SequenceOptions::IncrementBy(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(SequenceOptions::MinValue(__self_0),
SequenceOptions::MinValue(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SequenceOptions::MaxValue(__self_0),
SequenceOptions::MaxValue(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SequenceOptions::StartWith(__self_0, __self_1),
SequenceOptions::StartWith(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(SequenceOptions::Cache(__self_0),
SequenceOptions::Cache(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SequenceOptions::Cycle(__self_0),
SequenceOptions::Cycle(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SequenceOptions {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
SequenceOptions::IncrementBy(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
SequenceOptions::MinValue(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SequenceOptions::MaxValue(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SequenceOptions::StartWith(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
SequenceOptions::Cache(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SequenceOptions::Cycle(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
6148#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6149#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SequenceOptions {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IncrementBy(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
Self::MinValue(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::MaxValue(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::StartWith(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
Self::Cache(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Cycle(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SequenceOptions {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IncrementBy(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
Self::MinValue(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::MaxValue(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::StartWith(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
Self::Cache(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Cycle(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6150pub enum SequenceOptions {
6151 IncrementBy(Expr, bool),
6153 MinValue(Option<Expr>),
6155 MaxValue(Option<Expr>),
6157 StartWith(Expr, bool),
6159 Cache(Expr),
6161 Cycle(bool),
6163}
6164
6165impl fmt::Display for SequenceOptions {
6166 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6167 match self {
6168 SequenceOptions::IncrementBy(increment, by) => {
6169 f.write_fmt(format_args!(" INCREMENT{0} {1}", if *by { " BY" } else { "" },
increment))write!(
6170 f,
6171 " INCREMENT{by} {increment}",
6172 by = if *by { " BY" } else { "" },
6173 increment = increment
6174 )
6175 }
6176 SequenceOptions::MinValue(Some(expr)) => {
6177 f.write_fmt(format_args!(" MINVALUE {0}", expr))write!(f, " MINVALUE {expr}")
6178 }
6179 SequenceOptions::MinValue(None) => {
6180 f.write_fmt(format_args!(" NO MINVALUE"))write!(f, " NO MINVALUE")
6181 }
6182 SequenceOptions::MaxValue(Some(expr)) => {
6183 f.write_fmt(format_args!(" MAXVALUE {0}", expr))write!(f, " MAXVALUE {expr}")
6184 }
6185 SequenceOptions::MaxValue(None) => {
6186 f.write_fmt(format_args!(" NO MAXVALUE"))write!(f, " NO MAXVALUE")
6187 }
6188 SequenceOptions::StartWith(start, with) => {
6189 f.write_fmt(format_args!(" START{0} {1}", if *with { " WITH" } else { "" },
start))write!(
6190 f,
6191 " START{with} {start}",
6192 with = if *with { " WITH" } else { "" },
6193 start = start
6194 )
6195 }
6196 SequenceOptions::Cache(cache) => {
6197 f.write_fmt(format_args!(" CACHE {0}", *cache))write!(f, " CACHE {}", *cache)
6198 }
6199 SequenceOptions::Cycle(no) => {
6200 f.write_fmt(format_args!(" {0}CYCLE", if *no { "NO " } else { "" }))write!(f, " {}CYCLE", if *no { "NO " } else { "" })
6201 }
6202 }
6203 }
6204}
6205
6206#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetAssignment {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "SetAssignment",
"scope", &self.scope, "name", &self.name, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetAssignment {
#[inline]
fn clone(&self) -> SetAssignment {
SetAssignment {
scope: ::core::clone::Clone::clone(&self.scope),
name: ::core::clone::Clone::clone(&self.name),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetAssignment {
#[inline]
fn eq(&self, other: &SetAssignment) -> bool {
self.scope == other.scope && self.name == other.name &&
self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetAssignment {
#[inline]
fn partial_cmp(&self, other: &SetAssignment)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetAssignment {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ContextModifier>>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetAssignment {
#[inline]
fn cmp(&self, other: &SetAssignment) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.scope, &other.scope) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetAssignment {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.scope, state);
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
6208#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6209#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetAssignment {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.scope, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetAssignment {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.scope, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6210pub struct SetAssignment {
6211 pub scope: Option<ContextModifier>,
6213 pub name: ObjectName,
6215 pub value: Expr,
6217}
6218
6219impl fmt::Display for SetAssignment {
6220 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6221 f.write_fmt(format_args!("{0}{1} = {2}",
self.scope.map(|s|
::alloc::__export::must_use({
::alloc::fmt::format(format_args!("{0}", s))
})).unwrap_or_default(), self.name, self.value))write!(
6222 f,
6223 "{}{} = {}",
6224 self.scope.map(|s| format!("{s}")).unwrap_or_default(),
6225 self.name,
6226 self.value
6227 )
6228 }
6229}
6230
6231#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TruncateTableTarget {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"TruncateTableTarget", "name", &self.name, "only", &self.only,
"has_asterisk", &&self.has_asterisk)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TruncateTableTarget {
#[inline]
fn clone(&self) -> TruncateTableTarget {
TruncateTableTarget {
name: ::core::clone::Clone::clone(&self.name),
only: ::core::clone::Clone::clone(&self.only),
has_asterisk: ::core::clone::Clone::clone(&self.has_asterisk),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TruncateTableTarget {
#[inline]
fn eq(&self, other: &TruncateTableTarget) -> bool {
self.only == other.only && self.has_asterisk == other.has_asterisk &&
self.name == other.name
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TruncateTableTarget {
#[inline]
fn partial_cmp(&self, other: &TruncateTableTarget)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TruncateTableTarget {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TruncateTableTarget {
#[inline]
fn cmp(&self, other: &TruncateTableTarget) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.only, &other.only) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.has_asterisk,
&other.has_asterisk),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TruncateTableTarget {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.only, state);
::core::hash::Hash::hash(&self.has_asterisk, state)
}
}Hash)]
6235#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TruncateTableTarget {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
visitor.pre_visit_relation(&self.name)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
visitor.post_visit_relation(&self.name)?;
sqlparser::ast::Visit::visit(&self.only, visitor)?;
sqlparser::ast::Visit::visit(&self.has_asterisk, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TruncateTableTarget {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
visitor.pre_visit_relation(&mut self.name)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
visitor.post_visit_relation(&mut self.name)?;
sqlparser::ast::VisitMut::visit(&mut self.only, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.has_asterisk,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6236#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6237pub struct TruncateTableTarget {
6238 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
6240 pub name: ObjectName,
6241 pub only: bool,
6247 pub has_asterisk: bool,
6253}
6254
6255impl fmt::Display for TruncateTableTarget {
6256 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6257 if self.only {
6258 f.write_fmt(format_args!("ONLY "))write!(f, "ONLY ")?;
6259 };
6260 f.write_fmt(format_args!("{0}", self.name))write!(f, "{}", self.name)?;
6261 if self.has_asterisk {
6262 f.write_fmt(format_args!(" *"))write!(f, " *")?;
6263 };
6264 Ok(())
6265 }
6266}
6267
6268#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TruncateIdentityOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
TruncateIdentityOption::Restart => "Restart",
TruncateIdentityOption::Continue => "Continue",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TruncateIdentityOption {
#[inline]
fn clone(&self) -> TruncateIdentityOption {
match self {
TruncateIdentityOption::Restart =>
TruncateIdentityOption::Restart,
TruncateIdentityOption::Continue =>
TruncateIdentityOption::Continue,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TruncateIdentityOption {
#[inline]
fn eq(&self, other: &TruncateIdentityOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TruncateIdentityOption {
#[inline]
fn partial_cmp(&self, other: &TruncateIdentityOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TruncateIdentityOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TruncateIdentityOption {
#[inline]
fn cmp(&self, other: &TruncateIdentityOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TruncateIdentityOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6271#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6272#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TruncateIdentityOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Restart => {} Self::Continue => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TruncateIdentityOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Restart => {} Self::Continue => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6273pub enum TruncateIdentityOption {
6274 Restart,
6276 Continue,
6278}
6279
6280#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CascadeOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CascadeOption::Cascade => "Cascade",
CascadeOption::Restrict => "Restrict",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CascadeOption {
#[inline]
fn clone(&self) -> CascadeOption {
match self {
CascadeOption::Cascade => CascadeOption::Cascade,
CascadeOption::Restrict => CascadeOption::Restrict,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CascadeOption {
#[inline]
fn eq(&self, other: &CascadeOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CascadeOption {
#[inline]
fn partial_cmp(&self, other: &CascadeOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CascadeOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CascadeOption {
#[inline]
fn cmp(&self, other: &CascadeOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CascadeOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6283#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6284#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CascadeOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Cascade => {} Self::Restrict => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CascadeOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Cascade => {} Self::Restrict => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6285pub enum CascadeOption {
6286 Cascade,
6288 Restrict,
6290}
6291
6292impl Display for CascadeOption {
6293 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6294 match self {
6295 CascadeOption::Cascade => f.write_fmt(format_args!("CASCADE"))write!(f, "CASCADE"),
6296 CascadeOption::Restrict => f.write_fmt(format_args!("RESTRICT"))write!(f, "RESTRICT"),
6297 }
6298 }
6299}
6300
6301#[derive(#[automatically_derived]
impl ::core::fmt::Debug for BeginTransactionKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
BeginTransactionKind::Transaction => "Transaction",
BeginTransactionKind::Work => "Work",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for BeginTransactionKind {
#[inline]
fn clone(&self) -> BeginTransactionKind {
match self {
BeginTransactionKind::Transaction =>
BeginTransactionKind::Transaction,
BeginTransactionKind::Work => BeginTransactionKind::Work,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for BeginTransactionKind {
#[inline]
fn eq(&self, other: &BeginTransactionKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for BeginTransactionKind {
#[inline]
fn partial_cmp(&self, other: &BeginTransactionKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for BeginTransactionKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for BeginTransactionKind {
#[inline]
fn cmp(&self, other: &BeginTransactionKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for BeginTransactionKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6303#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6304#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for BeginTransactionKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Transaction => {} Self::Work => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for BeginTransactionKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Transaction => {} Self::Work => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6305pub enum BeginTransactionKind {
6306 Transaction,
6308 Work,
6310}
6311
6312impl Display for BeginTransactionKind {
6313 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6314 match self {
6315 BeginTransactionKind::Transaction => f.write_fmt(format_args!("TRANSACTION"))write!(f, "TRANSACTION"),
6316 BeginTransactionKind::Work => f.write_fmt(format_args!("WORK"))write!(f, "WORK"),
6317 }
6318 }
6319}
6320
6321#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MinMaxValue {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
MinMaxValue::Empty =>
::core::fmt::Formatter::write_str(f, "Empty"),
MinMaxValue::None => ::core::fmt::Formatter::write_str(f, "None"),
MinMaxValue::Some(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Some",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for MinMaxValue {
#[inline]
fn clone(&self) -> MinMaxValue {
match self {
MinMaxValue::Empty => MinMaxValue::Empty,
MinMaxValue::None => MinMaxValue::None,
MinMaxValue::Some(__self_0) =>
MinMaxValue::Some(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MinMaxValue {
#[inline]
fn eq(&self, other: &MinMaxValue) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(MinMaxValue::Some(__self_0), MinMaxValue::Some(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MinMaxValue {
#[inline]
fn partial_cmp(&self, other: &MinMaxValue)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MinMaxValue {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MinMaxValue {
#[inline]
fn cmp(&self, other: &MinMaxValue) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(MinMaxValue::Some(__self_0), MinMaxValue::Some(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MinMaxValue {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
MinMaxValue::Some(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
6324#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6325#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MinMaxValue {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Empty => {}
Self::None => {}
Self::Some(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MinMaxValue {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Empty => {}
Self::None => {}
Self::Some(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6326pub enum MinMaxValue {
6327 Empty,
6329 None,
6331 Some(Expr),
6333}
6334
6335#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OnInsert {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
OnInsert::DuplicateKeyUpdate(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DuplicateKeyUpdate", &__self_0),
OnInsert::OnConflict(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"OnConflict", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OnInsert {
#[inline]
fn clone(&self) -> OnInsert {
match self {
OnInsert::DuplicateKeyUpdate(__self_0) =>
OnInsert::DuplicateKeyUpdate(::core::clone::Clone::clone(__self_0)),
OnInsert::OnConflict(__self_0) =>
OnInsert::OnConflict(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OnInsert {
#[inline]
fn eq(&self, other: &OnInsert) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(OnInsert::DuplicateKeyUpdate(__self_0),
OnInsert::DuplicateKeyUpdate(__arg1_0)) =>
__self_0 == __arg1_0,
(OnInsert::OnConflict(__self_0),
OnInsert::OnConflict(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OnInsert {
#[inline]
fn partial_cmp(&self, other: &OnInsert)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OnInsert {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Assignment>>;
let _: ::core::cmp::AssertParamIsEq<OnConflict>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OnInsert {
#[inline]
fn cmp(&self, other: &OnInsert) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(OnInsert::DuplicateKeyUpdate(__self_0),
OnInsert::DuplicateKeyUpdate(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(OnInsert::OnConflict(__self_0),
OnInsert::OnConflict(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OnInsert {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
OnInsert::DuplicateKeyUpdate(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
OnInsert::OnConflict(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
6336#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6337#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OnInsert {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DuplicateKeyUpdate(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::OnConflict(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OnInsert {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DuplicateKeyUpdate(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::OnConflict(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6338#[non_exhaustive]
6339pub enum OnInsert {
6341 DuplicateKeyUpdate(Vec<Assignment>),
6343 OnConflict(OnConflict),
6345}
6346
6347#[derive(#[automatically_derived]
impl ::core::fmt::Debug for InsertAliases {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "InsertAliases",
"row_alias", &self.row_alias, "col_aliases", &&self.col_aliases)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for InsertAliases {
#[inline]
fn clone(&self) -> InsertAliases {
InsertAliases {
row_alias: ::core::clone::Clone::clone(&self.row_alias),
col_aliases: ::core::clone::Clone::clone(&self.col_aliases),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for InsertAliases {
#[inline]
fn eq(&self, other: &InsertAliases) -> bool {
self.row_alias == other.row_alias &&
self.col_aliases == other.col_aliases
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for InsertAliases {
#[inline]
fn partial_cmp(&self, other: &InsertAliases)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for InsertAliases {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Ident>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for InsertAliases {
#[inline]
fn cmp(&self, other: &InsertAliases) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.row_alias, &other.row_alias) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.col_aliases, &other.col_aliases),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for InsertAliases {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.row_alias, state);
::core::hash::Hash::hash(&self.col_aliases, state)
}
}Hash)]
6348#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6349#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for InsertAliases {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.row_alias, visitor)?;
sqlparser::ast::Visit::visit(&self.col_aliases, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for InsertAliases {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.row_alias,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.col_aliases,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6350pub struct InsertAliases {
6352 pub row_alias: ObjectName,
6354 pub col_aliases: Option<Vec<Ident>>,
6356}
6357
6358#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OnConflict {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "OnConflict",
"conflict_target", &self.conflict_target, "action", &&self.action)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OnConflict {
#[inline]
fn clone(&self) -> OnConflict {
OnConflict {
conflict_target: ::core::clone::Clone::clone(&self.conflict_target),
action: ::core::clone::Clone::clone(&self.action),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OnConflict {
#[inline]
fn eq(&self, other: &OnConflict) -> bool {
self.conflict_target == other.conflict_target &&
self.action == other.action
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OnConflict {
#[inline]
fn partial_cmp(&self, other: &OnConflict)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OnConflict {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ConflictTarget>>;
let _: ::core::cmp::AssertParamIsEq<OnConflictAction>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OnConflict {
#[inline]
fn cmp(&self, other: &OnConflict) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.conflict_target,
&other.conflict_target) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.action, &other.action),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OnConflict {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.conflict_target, state);
::core::hash::Hash::hash(&self.action, state)
}
}Hash)]
6359#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6360#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OnConflict {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.conflict_target,
visitor)?;
sqlparser::ast::Visit::visit(&self.action, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OnConflict {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.conflict_target,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.action, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6361pub struct OnConflict {
6363 pub conflict_target: Option<ConflictTarget>,
6365 pub action: OnConflictAction,
6367}
6368#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ConflictTarget {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ConflictTarget::Columns(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Columns", &__self_0),
ConflictTarget::OnConstraint(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"OnConstraint", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ConflictTarget {
#[inline]
fn clone(&self) -> ConflictTarget {
match self {
ConflictTarget::Columns(__self_0) =>
ConflictTarget::Columns(::core::clone::Clone::clone(__self_0)),
ConflictTarget::OnConstraint(__self_0) =>
ConflictTarget::OnConstraint(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ConflictTarget {
#[inline]
fn eq(&self, other: &ConflictTarget) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(ConflictTarget::Columns(__self_0),
ConflictTarget::Columns(__arg1_0)) => __self_0 == __arg1_0,
(ConflictTarget::OnConstraint(__self_0),
ConflictTarget::OnConstraint(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ConflictTarget {
#[inline]
fn partial_cmp(&self, other: &ConflictTarget)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ConflictTarget {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ConflictTarget {
#[inline]
fn cmp(&self, other: &ConflictTarget) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(ConflictTarget::Columns(__self_0),
ConflictTarget::Columns(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ConflictTarget::OnConstraint(__self_0),
ConflictTarget::OnConstraint(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ConflictTarget {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
ConflictTarget::Columns(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
ConflictTarget::OnConstraint(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
6369#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6370#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ConflictTarget {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Columns(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::OnConstraint(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ConflictTarget {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Columns(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::OnConstraint(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6371pub enum ConflictTarget {
6373 Columns(Vec<Ident>),
6375 OnConstraint(ObjectName),
6377}
6378#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OnConflictAction {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
OnConflictAction::DoNothing =>
::core::fmt::Formatter::write_str(f, "DoNothing"),
OnConflictAction::DoUpdate(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DoUpdate", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OnConflictAction {
#[inline]
fn clone(&self) -> OnConflictAction {
match self {
OnConflictAction::DoNothing => OnConflictAction::DoNothing,
OnConflictAction::DoUpdate(__self_0) =>
OnConflictAction::DoUpdate(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OnConflictAction {
#[inline]
fn eq(&self, other: &OnConflictAction) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(OnConflictAction::DoUpdate(__self_0),
OnConflictAction::DoUpdate(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OnConflictAction {
#[inline]
fn partial_cmp(&self, other: &OnConflictAction)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OnConflictAction {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<DoUpdate>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OnConflictAction {
#[inline]
fn cmp(&self, other: &OnConflictAction) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(OnConflictAction::DoUpdate(__self_0),
OnConflictAction::DoUpdate(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OnConflictAction {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
OnConflictAction::DoUpdate(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
6379#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6380#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OnConflictAction {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DoNothing => {}
Self::DoUpdate(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OnConflictAction {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DoNothing => {}
Self::DoUpdate(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6381pub enum OnConflictAction {
6383 DoNothing,
6385 DoUpdate(DoUpdate),
6387}
6388
6389#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DoUpdate {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "DoUpdate",
"assignments", &self.assignments, "selection", &&self.selection)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DoUpdate {
#[inline]
fn clone(&self) -> DoUpdate {
DoUpdate {
assignments: ::core::clone::Clone::clone(&self.assignments),
selection: ::core::clone::Clone::clone(&self.selection),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DoUpdate {
#[inline]
fn eq(&self, other: &DoUpdate) -> bool {
self.assignments == other.assignments &&
self.selection == other.selection
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DoUpdate {
#[inline]
fn partial_cmp(&self, other: &DoUpdate)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DoUpdate {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Assignment>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DoUpdate {
#[inline]
fn cmp(&self, other: &DoUpdate) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.assignments, &other.assignments) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.selection, &other.selection),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DoUpdate {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.assignments, state);
::core::hash::Hash::hash(&self.selection, state)
}
}Hash)]
6390#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6391#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DoUpdate {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.assignments, visitor)?;
sqlparser::ast::Visit::visit(&self.selection, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DoUpdate {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.assignments,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.selection,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6392pub struct DoUpdate {
6394 pub assignments: Vec<Assignment>,
6396 pub selection: Option<Expr>,
6398}
6399
6400impl fmt::Display for OnInsert {
6401 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6402 match self {
6403 Self::DuplicateKeyUpdate(expr) => f.write_fmt(format_args!(" ON DUPLICATE KEY UPDATE {0}",
display_comma_separated(expr)))write!(
6404 f,
6405 " ON DUPLICATE KEY UPDATE {}",
6406 display_comma_separated(expr)
6407 ),
6408 Self::OnConflict(o) => f.write_fmt(format_args!("{0}", o))write!(f, "{o}"),
6409 }
6410 }
6411}
6412impl fmt::Display for OnConflict {
6413 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6414 f.write_fmt(format_args!(" ON CONFLICT"))write!(f, " ON CONFLICT")?;
6415 if let Some(target) = &self.conflict_target {
6416 f.write_fmt(format_args!("{0}", target))write!(f, "{target}")?;
6417 }
6418 f.write_fmt(format_args!(" {0}", self.action))write!(f, " {}", self.action)
6419 }
6420}
6421impl fmt::Display for ConflictTarget {
6422 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6423 match self {
6424 ConflictTarget::Columns(cols) => f.write_fmt(format_args!("({0})", display_comma_separated(cols)))write!(f, "({})", display_comma_separated(cols)),
6425 ConflictTarget::OnConstraint(name) => f.write_fmt(format_args!(" ON CONSTRAINT {0}", name))write!(f, " ON CONSTRAINT {name}"),
6426 }
6427 }
6428}
6429impl fmt::Display for OnConflictAction {
6430 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6431 match self {
6432 Self::DoNothing => f.write_fmt(format_args!("DO NOTHING"))write!(f, "DO NOTHING"),
6433 Self::DoUpdate(do_update) => {
6434 f.write_fmt(format_args!("DO UPDATE"))write!(f, "DO UPDATE")?;
6435 if !do_update.assignments.is_empty() {
6436 f.write_fmt(format_args!(" SET {0}",
display_comma_separated(&do_update.assignments)))write!(
6437 f,
6438 " SET {}",
6439 display_comma_separated(&do_update.assignments)
6440 )?;
6441 }
6442 if let Some(selection) = &do_update.selection {
6443 f.write_fmt(format_args!(" WHERE {0}", selection))write!(f, " WHERE {selection}")?;
6444 }
6445 Ok(())
6446 }
6447 }
6448 }
6449}
6450
6451#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Privileges {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Privileges::All { with_privileges_keyword: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "All",
"with_privileges_keyword", &__self_0),
Privileges::Actions(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Actions", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Privileges {
#[inline]
fn clone(&self) -> Privileges {
match self {
Privileges::All { with_privileges_keyword: __self_0 } =>
Privileges::All {
with_privileges_keyword: ::core::clone::Clone::clone(__self_0),
},
Privileges::Actions(__self_0) =>
Privileges::Actions(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Privileges {
#[inline]
fn eq(&self, other: &Privileges) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Privileges::All { with_privileges_keyword: __self_0 },
Privileges::All { with_privileges_keyword: __arg1_0 }) =>
__self_0 == __arg1_0,
(Privileges::Actions(__self_0), Privileges::Actions(__arg1_0))
=> __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Privileges {
#[inline]
fn partial_cmp(&self, other: &Privileges)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Privileges {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Vec<Action>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Privileges {
#[inline]
fn cmp(&self, other: &Privileges) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Privileges::All { with_privileges_keyword: __self_0 },
Privileges::All { with_privileges_keyword: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Privileges::Actions(__self_0),
Privileges::Actions(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Privileges {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Privileges::All { with_privileges_keyword: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Privileges::Actions(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
6453#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6454#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Privileges {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::All { with_privileges_keyword } => {
sqlparser::ast::Visit::visit(with_privileges_keyword,
visitor)?;
}
Self::Actions(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Privileges {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::All { with_privileges_keyword } => {
sqlparser::ast::VisitMut::visit(with_privileges_keyword,
visitor)?;
}
Self::Actions(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6455pub enum Privileges {
6456 All {
6458 with_privileges_keyword: bool,
6460 },
6461 Actions(Vec<Action>),
6463}
6464
6465impl fmt::Display for Privileges {
6466 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6467 match self {
6468 Privileges::All {
6469 with_privileges_keyword,
6470 } => {
6471 f.write_fmt(format_args!("ALL{0}",
if *with_privileges_keyword { " PRIVILEGES" } else { "" }))write!(
6472 f,
6473 "ALL{}",
6474 if *with_privileges_keyword {
6475 " PRIVILEGES"
6476 } else {
6477 ""
6478 }
6479 )
6480 }
6481 Privileges::Actions(actions) => {
6482 f.write_fmt(format_args!("{0}", display_comma_separated(actions)))write!(f, "{}", display_comma_separated(actions))
6483 }
6484 }
6485 }
6486}
6487
6488#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FetchDirection {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FetchDirection::Count { limit: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Count",
"limit", &__self_0),
FetchDirection::Next =>
::core::fmt::Formatter::write_str(f, "Next"),
FetchDirection::Prior =>
::core::fmt::Formatter::write_str(f, "Prior"),
FetchDirection::First =>
::core::fmt::Formatter::write_str(f, "First"),
FetchDirection::Last =>
::core::fmt::Formatter::write_str(f, "Last"),
FetchDirection::Absolute { limit: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Absolute", "limit", &__self_0),
FetchDirection::Relative { limit: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Relative", "limit", &__self_0),
FetchDirection::All =>
::core::fmt::Formatter::write_str(f, "All"),
FetchDirection::Forward { limit: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Forward", "limit", &__self_0),
FetchDirection::ForwardAll =>
::core::fmt::Formatter::write_str(f, "ForwardAll"),
FetchDirection::Backward { limit: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Backward", "limit", &__self_0),
FetchDirection::BackwardAll =>
::core::fmt::Formatter::write_str(f, "BackwardAll"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FetchDirection {
#[inline]
fn clone(&self) -> FetchDirection {
match self {
FetchDirection::Count { limit: __self_0 } =>
FetchDirection::Count {
limit: ::core::clone::Clone::clone(__self_0),
},
FetchDirection::Next => FetchDirection::Next,
FetchDirection::Prior => FetchDirection::Prior,
FetchDirection::First => FetchDirection::First,
FetchDirection::Last => FetchDirection::Last,
FetchDirection::Absolute { limit: __self_0 } =>
FetchDirection::Absolute {
limit: ::core::clone::Clone::clone(__self_0),
},
FetchDirection::Relative { limit: __self_0 } =>
FetchDirection::Relative {
limit: ::core::clone::Clone::clone(__self_0),
},
FetchDirection::All => FetchDirection::All,
FetchDirection::Forward { limit: __self_0 } =>
FetchDirection::Forward {
limit: ::core::clone::Clone::clone(__self_0),
},
FetchDirection::ForwardAll => FetchDirection::ForwardAll,
FetchDirection::Backward { limit: __self_0 } =>
FetchDirection::Backward {
limit: ::core::clone::Clone::clone(__self_0),
},
FetchDirection::BackwardAll => FetchDirection::BackwardAll,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FetchDirection {
#[inline]
fn eq(&self, other: &FetchDirection) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FetchDirection::Count { limit: __self_0 },
FetchDirection::Count { limit: __arg1_0 }) =>
__self_0 == __arg1_0,
(FetchDirection::Absolute { limit: __self_0 },
FetchDirection::Absolute { limit: __arg1_0 }) =>
__self_0 == __arg1_0,
(FetchDirection::Relative { limit: __self_0 },
FetchDirection::Relative { limit: __arg1_0 }) =>
__self_0 == __arg1_0,
(FetchDirection::Forward { limit: __self_0 },
FetchDirection::Forward { limit: __arg1_0 }) =>
__self_0 == __arg1_0,
(FetchDirection::Backward { limit: __self_0 },
FetchDirection::Backward { limit: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FetchDirection {
#[inline]
fn partial_cmp(&self, other: &FetchDirection)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FetchDirection {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Value>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FetchDirection {
#[inline]
fn cmp(&self, other: &FetchDirection) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FetchDirection::Count { limit: __self_0 },
FetchDirection::Count { limit: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FetchDirection::Absolute { limit: __self_0 },
FetchDirection::Absolute { limit: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FetchDirection::Relative { limit: __self_0 },
FetchDirection::Relative { limit: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FetchDirection::Forward { limit: __self_0 },
FetchDirection::Forward { limit: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FetchDirection::Backward { limit: __self_0 },
FetchDirection::Backward { limit: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FetchDirection {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FetchDirection::Count { limit: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
FetchDirection::Absolute { limit: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
FetchDirection::Relative { limit: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
FetchDirection::Forward { limit: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
FetchDirection::Backward { limit: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
6490#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6491#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FetchDirection {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Count { limit } => {
sqlparser::ast::Visit::visit(limit, visitor)?;
}
Self::Next => {}
Self::Prior => {}
Self::First => {}
Self::Last => {}
Self::Absolute { limit } => {
sqlparser::ast::Visit::visit(limit, visitor)?;
}
Self::Relative { limit } => {
sqlparser::ast::Visit::visit(limit, visitor)?;
}
Self::All => {}
Self::Forward { limit } => {
sqlparser::ast::Visit::visit(limit, visitor)?;
}
Self::ForwardAll => {}
Self::Backward { limit } => {
sqlparser::ast::Visit::visit(limit, visitor)?;
}
Self::BackwardAll => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FetchDirection {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Count { limit } => {
sqlparser::ast::VisitMut::visit(limit, visitor)?;
}
Self::Next => {}
Self::Prior => {}
Self::First => {}
Self::Last => {}
Self::Absolute { limit } => {
sqlparser::ast::VisitMut::visit(limit, visitor)?;
}
Self::Relative { limit } => {
sqlparser::ast::VisitMut::visit(limit, visitor)?;
}
Self::All => {}
Self::Forward { limit } => {
sqlparser::ast::VisitMut::visit(limit, visitor)?;
}
Self::ForwardAll => {}
Self::Backward { limit } => {
sqlparser::ast::VisitMut::visit(limit, visitor)?;
}
Self::BackwardAll => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6492pub enum FetchDirection {
6493 Count {
6495 limit: Value,
6497 },
6498 Next,
6500 Prior,
6502 First,
6504 Last,
6506 Absolute {
6508 limit: Value,
6510 },
6511 Relative {
6513 limit: Value,
6515 },
6516 All,
6518 Forward {
6522 limit: Option<Value>,
6524 },
6525 ForwardAll,
6527 Backward {
6531 limit: Option<Value>,
6533 },
6534 BackwardAll,
6536}
6537
6538impl fmt::Display for FetchDirection {
6539 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6540 match self {
6541 FetchDirection::Count { limit } => f.write_str(&limit.to_string())?,
6542 FetchDirection::Next => f.write_str("NEXT")?,
6543 FetchDirection::Prior => f.write_str("PRIOR")?,
6544 FetchDirection::First => f.write_str("FIRST")?,
6545 FetchDirection::Last => f.write_str("LAST")?,
6546 FetchDirection::Absolute { limit } => {
6547 f.write_str("ABSOLUTE ")?;
6548 f.write_str(&limit.to_string())?;
6549 }
6550 FetchDirection::Relative { limit } => {
6551 f.write_str("RELATIVE ")?;
6552 f.write_str(&limit.to_string())?;
6553 }
6554 FetchDirection::All => f.write_str("ALL")?,
6555 FetchDirection::Forward { limit } => {
6556 f.write_str("FORWARD")?;
6557
6558 if let Some(l) = limit {
6559 f.write_str(" ")?;
6560 f.write_str(&l.to_string())?;
6561 }
6562 }
6563 FetchDirection::ForwardAll => f.write_str("FORWARD ALL")?,
6564 FetchDirection::Backward { limit } => {
6565 f.write_str("BACKWARD")?;
6566
6567 if let Some(l) = limit {
6568 f.write_str(" ")?;
6569 f.write_str(&l.to_string())?;
6570 }
6571 }
6572 FetchDirection::BackwardAll => f.write_str("BACKWARD ALL")?,
6573 };
6574
6575 Ok(())
6576 }
6577}
6578
6579#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FetchPosition {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FetchPosition::From => "From",
FetchPosition::In => "In",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FetchPosition {
#[inline]
fn clone(&self) -> FetchPosition {
match self {
FetchPosition::From => FetchPosition::From,
FetchPosition::In => FetchPosition::In,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FetchPosition {
#[inline]
fn eq(&self, other: &FetchPosition) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FetchPosition {
#[inline]
fn partial_cmp(&self, other: &FetchPosition)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FetchPosition {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FetchPosition {
#[inline]
fn cmp(&self, other: &FetchPosition) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FetchPosition {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6583#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6584#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FetchPosition {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::From => {} Self::In => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FetchPosition {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::From => {} Self::In => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6585pub enum FetchPosition {
6586 From,
6588 In,
6590}
6591
6592impl fmt::Display for FetchPosition {
6593 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6594 match self {
6595 FetchPosition::From => f.write_str("FROM")?,
6596 FetchPosition::In => f.write_str("IN")?,
6597 };
6598
6599 Ok(())
6600 }
6601}
6602
6603#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Action {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Action::AddSearchOptimization =>
::core::fmt::Formatter::write_str(f, "AddSearchOptimization"),
Action::Apply { apply_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Apply",
"apply_type", &__self_0),
Action::ApplyBudget =>
::core::fmt::Formatter::write_str(f, "ApplyBudget"),
Action::AttachListing =>
::core::fmt::Formatter::write_str(f, "AttachListing"),
Action::AttachPolicy =>
::core::fmt::Formatter::write_str(f, "AttachPolicy"),
Action::Audit => ::core::fmt::Formatter::write_str(f, "Audit"),
Action::BindServiceEndpoint =>
::core::fmt::Formatter::write_str(f, "BindServiceEndpoint"),
Action::Connect =>
::core::fmt::Formatter::write_str(f, "Connect"),
Action::Create { obj_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Create", "obj_type", &__self_0),
Action::DatabaseRole { role: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"DatabaseRole", "role", &__self_0),
Action::Delete => ::core::fmt::Formatter::write_str(f, "Delete"),
Action::Drop => ::core::fmt::Formatter::write_str(f, "Drop"),
Action::EvolveSchema =>
::core::fmt::Formatter::write_str(f, "EvolveSchema"),
Action::Exec { obj_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Exec",
"obj_type", &__self_0),
Action::Execute { obj_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Execute", "obj_type", &__self_0),
Action::Failover =>
::core::fmt::Formatter::write_str(f, "Failover"),
Action::ImportedPrivileges =>
::core::fmt::Formatter::write_str(f, "ImportedPrivileges"),
Action::ImportShare =>
::core::fmt::Formatter::write_str(f, "ImportShare"),
Action::Insert { columns: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Insert", "columns", &__self_0),
Action::Manage { manage_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Manage", "manage_type", &__self_0),
Action::ManageReleases =>
::core::fmt::Formatter::write_str(f, "ManageReleases"),
Action::ManageVersions =>
::core::fmt::Formatter::write_str(f, "ManageVersions"),
Action::Modify { modify_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Modify", "modify_type", &__self_0),
Action::Monitor { monitor_type: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Monitor", "monitor_type", &__self_0),
Action::Operate =>
::core::fmt::Formatter::write_str(f, "Operate"),
Action::OverrideShareRestrictions =>
::core::fmt::Formatter::write_str(f,
"OverrideShareRestrictions"),
Action::Ownership =>
::core::fmt::Formatter::write_str(f, "Ownership"),
Action::PurchaseDataExchangeListing =>
::core::fmt::Formatter::write_str(f,
"PurchaseDataExchangeListing"),
Action::Read => ::core::fmt::Formatter::write_str(f, "Read"),
Action::ReadSession =>
::core::fmt::Formatter::write_str(f, "ReadSession"),
Action::References { columns: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"References", "columns", &__self_0),
Action::Replicate =>
::core::fmt::Formatter::write_str(f, "Replicate"),
Action::ResolveAll =>
::core::fmt::Formatter::write_str(f, "ResolveAll"),
Action::Role { role: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Role",
"role", &__self_0),
Action::Select { columns: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Select", "columns", &__self_0),
Action::Temporary =>
::core::fmt::Formatter::write_str(f, "Temporary"),
Action::Trigger =>
::core::fmt::Formatter::write_str(f, "Trigger"),
Action::Truncate =>
::core::fmt::Formatter::write_str(f, "Truncate"),
Action::Update { columns: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Update", "columns", &__self_0),
Action::Usage => ::core::fmt::Formatter::write_str(f, "Usage"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Action {
#[inline]
fn clone(&self) -> Action {
match self {
Action::AddSearchOptimization => Action::AddSearchOptimization,
Action::Apply { apply_type: __self_0 } =>
Action::Apply {
apply_type: ::core::clone::Clone::clone(__self_0),
},
Action::ApplyBudget => Action::ApplyBudget,
Action::AttachListing => Action::AttachListing,
Action::AttachPolicy => Action::AttachPolicy,
Action::Audit => Action::Audit,
Action::BindServiceEndpoint => Action::BindServiceEndpoint,
Action::Connect => Action::Connect,
Action::Create { obj_type: __self_0 } =>
Action::Create {
obj_type: ::core::clone::Clone::clone(__self_0),
},
Action::DatabaseRole { role: __self_0 } =>
Action::DatabaseRole {
role: ::core::clone::Clone::clone(__self_0),
},
Action::Delete => Action::Delete,
Action::Drop => Action::Drop,
Action::EvolveSchema => Action::EvolveSchema,
Action::Exec { obj_type: __self_0 } =>
Action::Exec {
obj_type: ::core::clone::Clone::clone(__self_0),
},
Action::Execute { obj_type: __self_0 } =>
Action::Execute {
obj_type: ::core::clone::Clone::clone(__self_0),
},
Action::Failover => Action::Failover,
Action::ImportedPrivileges => Action::ImportedPrivileges,
Action::ImportShare => Action::ImportShare,
Action::Insert { columns: __self_0 } =>
Action::Insert {
columns: ::core::clone::Clone::clone(__self_0),
},
Action::Manage { manage_type: __self_0 } =>
Action::Manage {
manage_type: ::core::clone::Clone::clone(__self_0),
},
Action::ManageReleases => Action::ManageReleases,
Action::ManageVersions => Action::ManageVersions,
Action::Modify { modify_type: __self_0 } =>
Action::Modify {
modify_type: ::core::clone::Clone::clone(__self_0),
},
Action::Monitor { monitor_type: __self_0 } =>
Action::Monitor {
monitor_type: ::core::clone::Clone::clone(__self_0),
},
Action::Operate => Action::Operate,
Action::OverrideShareRestrictions =>
Action::OverrideShareRestrictions,
Action::Ownership => Action::Ownership,
Action::PurchaseDataExchangeListing =>
Action::PurchaseDataExchangeListing,
Action::Read => Action::Read,
Action::ReadSession => Action::ReadSession,
Action::References { columns: __self_0 } =>
Action::References {
columns: ::core::clone::Clone::clone(__self_0),
},
Action::Replicate => Action::Replicate,
Action::ResolveAll => Action::ResolveAll,
Action::Role { role: __self_0 } =>
Action::Role { role: ::core::clone::Clone::clone(__self_0) },
Action::Select { columns: __self_0 } =>
Action::Select {
columns: ::core::clone::Clone::clone(__self_0),
},
Action::Temporary => Action::Temporary,
Action::Trigger => Action::Trigger,
Action::Truncate => Action::Truncate,
Action::Update { columns: __self_0 } =>
Action::Update {
columns: ::core::clone::Clone::clone(__self_0),
},
Action::Usage => Action::Usage,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Action {
#[inline]
fn eq(&self, other: &Action) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Action::Apply { apply_type: __self_0 }, Action::Apply {
apply_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Create { obj_type: __self_0 }, Action::Create {
obj_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::DatabaseRole { role: __self_0 },
Action::DatabaseRole { role: __arg1_0 }) =>
__self_0 == __arg1_0,
(Action::Exec { obj_type: __self_0 }, Action::Exec {
obj_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Execute { obj_type: __self_0 }, Action::Execute {
obj_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Insert { columns: __self_0 }, Action::Insert {
columns: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Manage { manage_type: __self_0 }, Action::Manage {
manage_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Modify { modify_type: __self_0 }, Action::Modify {
modify_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Monitor { monitor_type: __self_0 }, Action::Monitor {
monitor_type: __arg1_0 }) => __self_0 == __arg1_0,
(Action::References { columns: __self_0 },
Action::References { columns: __arg1_0 }) =>
__self_0 == __arg1_0,
(Action::Role { role: __self_0 }, Action::Role {
role: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Select { columns: __self_0 }, Action::Select {
columns: __arg1_0 }) => __self_0 == __arg1_0,
(Action::Update { columns: __self_0 }, Action::Update {
columns: __arg1_0 }) => __self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Action {
#[inline]
fn partial_cmp(&self, other: &Action)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Action {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ActionApplyType>;
let _: ::core::cmp::AssertParamIsEq<Option<ActionCreateObjectType>>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Option<ActionExecuteObjectType>>;
let _: ::core::cmp::AssertParamIsEq<Option<ActionExecuteObjectType>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Ident>>>;
let _: ::core::cmp::AssertParamIsEq<ActionManageType>;
let _: ::core::cmp::AssertParamIsEq<Option<ActionModifyType>>;
let _: ::core::cmp::AssertParamIsEq<Option<ActionMonitorType>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Ident>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Ident>>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<Ident>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Action {
#[inline]
fn cmp(&self, other: &Action) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Action::Apply { apply_type: __self_0 }, Action::Apply {
apply_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Create { obj_type: __self_0 }, Action::Create {
obj_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::DatabaseRole { role: __self_0 },
Action::DatabaseRole { role: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Exec { obj_type: __self_0 }, Action::Exec {
obj_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Execute { obj_type: __self_0 }, Action::Execute {
obj_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Insert { columns: __self_0 }, Action::Insert {
columns: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Manage { manage_type: __self_0 }, Action::Manage {
manage_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Modify { modify_type: __self_0 }, Action::Modify {
modify_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Monitor { monitor_type: __self_0 },
Action::Monitor { monitor_type: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::References { columns: __self_0 },
Action::References { columns: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Role { role: __self_0 }, Action::Role {
role: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Select { columns: __self_0 }, Action::Select {
columns: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(Action::Update { columns: __self_0 }, Action::Update {
columns: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Action {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Action::Apply { apply_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Create { obj_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::DatabaseRole { role: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Exec { obj_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Execute { obj_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Insert { columns: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Manage { manage_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Modify { modify_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Monitor { monitor_type: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::References { columns: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Role { role: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Select { columns: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
Action::Update { columns: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
6605#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6606#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Action {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AddSearchOptimization => {}
Self::Apply { apply_type } => {
sqlparser::ast::Visit::visit(apply_type, visitor)?;
}
Self::ApplyBudget => {}
Self::AttachListing => {}
Self::AttachPolicy => {}
Self::Audit => {}
Self::BindServiceEndpoint => {}
Self::Connect => {}
Self::Create { obj_type } => {
sqlparser::ast::Visit::visit(obj_type, visitor)?;
}
Self::DatabaseRole { role } => {
sqlparser::ast::Visit::visit(role, visitor)?;
}
Self::Delete => {}
Self::Drop => {}
Self::EvolveSchema => {}
Self::Exec { obj_type } => {
sqlparser::ast::Visit::visit(obj_type, visitor)?;
}
Self::Execute { obj_type } => {
sqlparser::ast::Visit::visit(obj_type, visitor)?;
}
Self::Failover => {}
Self::ImportedPrivileges => {}
Self::ImportShare => {}
Self::Insert { columns } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
}
Self::Manage { manage_type } => {
sqlparser::ast::Visit::visit(manage_type, visitor)?;
}
Self::ManageReleases => {}
Self::ManageVersions => {}
Self::Modify { modify_type } => {
sqlparser::ast::Visit::visit(modify_type, visitor)?;
}
Self::Monitor { monitor_type } => {
sqlparser::ast::Visit::visit(monitor_type, visitor)?;
}
Self::Operate => {}
Self::OverrideShareRestrictions => {}
Self::Ownership => {}
Self::PurchaseDataExchangeListing => {}
Self::Read => {}
Self::ReadSession => {}
Self::References { columns } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
}
Self::Replicate => {}
Self::ResolveAll => {}
Self::Role { role } => {
sqlparser::ast::Visit::visit(role, visitor)?;
}
Self::Select { columns } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
}
Self::Temporary => {}
Self::Trigger => {}
Self::Truncate => {}
Self::Update { columns } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
}
Self::Usage => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Action {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AddSearchOptimization => {}
Self::Apply { apply_type } => {
sqlparser::ast::VisitMut::visit(apply_type, visitor)?;
}
Self::ApplyBudget => {}
Self::AttachListing => {}
Self::AttachPolicy => {}
Self::Audit => {}
Self::BindServiceEndpoint => {}
Self::Connect => {}
Self::Create { obj_type } => {
sqlparser::ast::VisitMut::visit(obj_type, visitor)?;
}
Self::DatabaseRole { role } => {
sqlparser::ast::VisitMut::visit(role, visitor)?;
}
Self::Delete => {}
Self::Drop => {}
Self::EvolveSchema => {}
Self::Exec { obj_type } => {
sqlparser::ast::VisitMut::visit(obj_type, visitor)?;
}
Self::Execute { obj_type } => {
sqlparser::ast::VisitMut::visit(obj_type, visitor)?;
}
Self::Failover => {}
Self::ImportedPrivileges => {}
Self::ImportShare => {}
Self::Insert { columns } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
}
Self::Manage { manage_type } => {
sqlparser::ast::VisitMut::visit(manage_type, visitor)?;
}
Self::ManageReleases => {}
Self::ManageVersions => {}
Self::Modify { modify_type } => {
sqlparser::ast::VisitMut::visit(modify_type, visitor)?;
}
Self::Monitor { monitor_type } => {
sqlparser::ast::VisitMut::visit(monitor_type, visitor)?;
}
Self::Operate => {}
Self::OverrideShareRestrictions => {}
Self::Ownership => {}
Self::PurchaseDataExchangeListing => {}
Self::Read => {}
Self::ReadSession => {}
Self::References { columns } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
}
Self::Replicate => {}
Self::ResolveAll => {}
Self::Role { role } => {
sqlparser::ast::VisitMut::visit(role, visitor)?;
}
Self::Select { columns } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
}
Self::Temporary => {}
Self::Trigger => {}
Self::Truncate => {}
Self::Update { columns } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
}
Self::Usage => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6607pub enum Action {
6608 AddSearchOptimization,
6610 Apply {
6612 apply_type: ActionApplyType,
6614 },
6615 ApplyBudget,
6617 AttachListing,
6619 AttachPolicy,
6621 Audit,
6623 BindServiceEndpoint,
6625 Connect,
6627 Create {
6629 obj_type: Option<ActionCreateObjectType>,
6631 },
6632 DatabaseRole {
6634 role: ObjectName,
6636 },
6637 Delete,
6639 Drop,
6641 EvolveSchema,
6643 Exec {
6645 obj_type: Option<ActionExecuteObjectType>,
6647 },
6648 Execute {
6650 obj_type: Option<ActionExecuteObjectType>,
6652 },
6653 Failover,
6655 ImportedPrivileges,
6657 ImportShare,
6659 Insert {
6661 columns: Option<Vec<Ident>>,
6663 },
6664 Manage {
6666 manage_type: ActionManageType,
6668 },
6669 ManageReleases,
6671 ManageVersions,
6673 Modify {
6675 modify_type: Option<ActionModifyType>,
6677 },
6678 Monitor {
6680 monitor_type: Option<ActionMonitorType>,
6682 },
6683 Operate,
6685 OverrideShareRestrictions,
6687 Ownership,
6689 PurchaseDataExchangeListing,
6691
6692 Read,
6694 ReadSession,
6696 References {
6698 columns: Option<Vec<Ident>>,
6700 },
6701 Replicate,
6703 ResolveAll,
6705 Role {
6707 role: ObjectName,
6709 },
6710 Select {
6712 columns: Option<Vec<Ident>>,
6714 },
6715 Temporary,
6717 Trigger,
6719 Truncate,
6721 Update {
6723 columns: Option<Vec<Ident>>,
6725 },
6726 Usage,
6728}
6729
6730impl fmt::Display for Action {
6731 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6732 match self {
6733 Action::AddSearchOptimization => f.write_str("ADD SEARCH OPTIMIZATION")?,
6734 Action::Apply { apply_type } => f.write_fmt(format_args!("APPLY {0}", apply_type))write!(f, "APPLY {apply_type}")?,
6735 Action::ApplyBudget => f.write_str("APPLYBUDGET")?,
6736 Action::AttachListing => f.write_str("ATTACH LISTING")?,
6737 Action::AttachPolicy => f.write_str("ATTACH POLICY")?,
6738 Action::Audit => f.write_str("AUDIT")?,
6739 Action::BindServiceEndpoint => f.write_str("BIND SERVICE ENDPOINT")?,
6740 Action::Connect => f.write_str("CONNECT")?,
6741 Action::Create { obj_type } => {
6742 f.write_str("CREATE")?;
6743 if let Some(obj_type) = obj_type {
6744 f.write_fmt(format_args!(" {0}", obj_type))write!(f, " {obj_type}")?
6745 }
6746 }
6747 Action::DatabaseRole { role } => f.write_fmt(format_args!("DATABASE ROLE {0}", role))write!(f, "DATABASE ROLE {role}")?,
6748 Action::Delete => f.write_str("DELETE")?,
6749 Action::Drop => f.write_str("DROP")?,
6750 Action::EvolveSchema => f.write_str("EVOLVE SCHEMA")?,
6751 Action::Exec { obj_type } => {
6752 f.write_str("EXEC")?;
6753 if let Some(obj_type) = obj_type {
6754 f.write_fmt(format_args!(" {0}", obj_type))write!(f, " {obj_type}")?
6755 }
6756 }
6757 Action::Execute { obj_type } => {
6758 f.write_str("EXECUTE")?;
6759 if let Some(obj_type) = obj_type {
6760 f.write_fmt(format_args!(" {0}", obj_type))write!(f, " {obj_type}")?
6761 }
6762 }
6763 Action::Failover => f.write_str("FAILOVER")?,
6764 Action::ImportedPrivileges => f.write_str("IMPORTED PRIVILEGES")?,
6765 Action::ImportShare => f.write_str("IMPORT SHARE")?,
6766 Action::Insert { .. } => f.write_str("INSERT")?,
6767 Action::Manage { manage_type } => f.write_fmt(format_args!("MANAGE {0}", manage_type))write!(f, "MANAGE {manage_type}")?,
6768 Action::ManageReleases => f.write_str("MANAGE RELEASES")?,
6769 Action::ManageVersions => f.write_str("MANAGE VERSIONS")?,
6770 Action::Modify { modify_type } => {
6771 f.write_fmt(format_args!("MODIFY"))write!(f, "MODIFY")?;
6772 if let Some(modify_type) = modify_type {
6773 f.write_fmt(format_args!(" {0}", modify_type))write!(f, " {modify_type}")?;
6774 }
6775 }
6776 Action::Monitor { monitor_type } => {
6777 f.write_fmt(format_args!("MONITOR"))write!(f, "MONITOR")?;
6778 if let Some(monitor_type) = monitor_type {
6779 f.write_fmt(format_args!(" {0}", monitor_type))write!(f, " {monitor_type}")?
6780 }
6781 }
6782 Action::Operate => f.write_str("OPERATE")?,
6783 Action::OverrideShareRestrictions => f.write_str("OVERRIDE SHARE RESTRICTIONS")?,
6784 Action::Ownership => f.write_str("OWNERSHIP")?,
6785 Action::PurchaseDataExchangeListing => f.write_str("PURCHASE DATA EXCHANGE LISTING")?,
6786 Action::Read => f.write_str("READ")?,
6787 Action::ReadSession => f.write_str("READ SESSION")?,
6788 Action::References { .. } => f.write_str("REFERENCES")?,
6789 Action::Replicate => f.write_str("REPLICATE")?,
6790 Action::ResolveAll => f.write_str("RESOLVE ALL")?,
6791 Action::Role { role } => f.write_fmt(format_args!("ROLE {0}", role))write!(f, "ROLE {role}")?,
6792 Action::Select { .. } => f.write_str("SELECT")?,
6793 Action::Temporary => f.write_str("TEMPORARY")?,
6794 Action::Trigger => f.write_str("TRIGGER")?,
6795 Action::Truncate => f.write_str("TRUNCATE")?,
6796 Action::Update { .. } => f.write_str("UPDATE")?,
6797 Action::Usage => f.write_str("USAGE")?,
6798 };
6799 match self {
6800 Action::Insert { columns }
6801 | Action::References { columns }
6802 | Action::Select { columns }
6803 | Action::Update { columns } => {
6804 if let Some(columns) = columns {
6805 f.write_fmt(format_args!(" ({0})", display_comma_separated(columns)))write!(f, " ({})", display_comma_separated(columns))?;
6806 }
6807 }
6808 _ => (),
6809 };
6810 Ok(())
6811 }
6812}
6813
6814#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ActionCreateObjectType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ActionCreateObjectType::Account => "Account",
ActionCreateObjectType::Application => "Application",
ActionCreateObjectType::ApplicationPackage =>
"ApplicationPackage",
ActionCreateObjectType::ComputePool => "ComputePool",
ActionCreateObjectType::DataExchangeListing =>
"DataExchangeListing",
ActionCreateObjectType::Database => "Database",
ActionCreateObjectType::ExternalVolume => "ExternalVolume",
ActionCreateObjectType::FailoverGroup => "FailoverGroup",
ActionCreateObjectType::Integration => "Integration",
ActionCreateObjectType::NetworkPolicy => "NetworkPolicy",
ActionCreateObjectType::OrganiationListing =>
"OrganiationListing",
ActionCreateObjectType::ReplicationGroup =>
"ReplicationGroup",
ActionCreateObjectType::Role => "Role",
ActionCreateObjectType::Schema => "Schema",
ActionCreateObjectType::Share => "Share",
ActionCreateObjectType::User => "User",
ActionCreateObjectType::Warehouse => "Warehouse",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ActionCreateObjectType {
#[inline]
fn clone(&self) -> ActionCreateObjectType {
match self {
ActionCreateObjectType::Account =>
ActionCreateObjectType::Account,
ActionCreateObjectType::Application =>
ActionCreateObjectType::Application,
ActionCreateObjectType::ApplicationPackage =>
ActionCreateObjectType::ApplicationPackage,
ActionCreateObjectType::ComputePool =>
ActionCreateObjectType::ComputePool,
ActionCreateObjectType::DataExchangeListing =>
ActionCreateObjectType::DataExchangeListing,
ActionCreateObjectType::Database =>
ActionCreateObjectType::Database,
ActionCreateObjectType::ExternalVolume =>
ActionCreateObjectType::ExternalVolume,
ActionCreateObjectType::FailoverGroup =>
ActionCreateObjectType::FailoverGroup,
ActionCreateObjectType::Integration =>
ActionCreateObjectType::Integration,
ActionCreateObjectType::NetworkPolicy =>
ActionCreateObjectType::NetworkPolicy,
ActionCreateObjectType::OrganiationListing =>
ActionCreateObjectType::OrganiationListing,
ActionCreateObjectType::ReplicationGroup =>
ActionCreateObjectType::ReplicationGroup,
ActionCreateObjectType::Role => ActionCreateObjectType::Role,
ActionCreateObjectType::Schema => ActionCreateObjectType::Schema,
ActionCreateObjectType::Share => ActionCreateObjectType::Share,
ActionCreateObjectType::User => ActionCreateObjectType::User,
ActionCreateObjectType::Warehouse =>
ActionCreateObjectType::Warehouse,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ActionCreateObjectType {
#[inline]
fn eq(&self, other: &ActionCreateObjectType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ActionCreateObjectType {
#[inline]
fn partial_cmp(&self, other: &ActionCreateObjectType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ActionCreateObjectType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ActionCreateObjectType {
#[inline]
fn cmp(&self, other: &ActionCreateObjectType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ActionCreateObjectType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6815#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6816#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ActionCreateObjectType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Account => {}
Self::Application => {}
Self::ApplicationPackage => {}
Self::ComputePool => {}
Self::DataExchangeListing => {}
Self::Database => {}
Self::ExternalVolume => {}
Self::FailoverGroup => {}
Self::Integration => {}
Self::NetworkPolicy => {}
Self::OrganiationListing => {}
Self::ReplicationGroup => {}
Self::Role => {}
Self::Schema => {}
Self::Share => {}
Self::User => {}
Self::Warehouse => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ActionCreateObjectType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Account => {}
Self::Application => {}
Self::ApplicationPackage => {}
Self::ComputePool => {}
Self::DataExchangeListing => {}
Self::Database => {}
Self::ExternalVolume => {}
Self::FailoverGroup => {}
Self::Integration => {}
Self::NetworkPolicy => {}
Self::OrganiationListing => {}
Self::ReplicationGroup => {}
Self::Role => {}
Self::Schema => {}
Self::Share => {}
Self::User => {}
Self::Warehouse => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6817pub enum ActionCreateObjectType {
6820 Account,
6822 Application,
6824 ApplicationPackage,
6826 ComputePool,
6828 DataExchangeListing,
6830 Database,
6832 ExternalVolume,
6834 FailoverGroup,
6836 Integration,
6838 NetworkPolicy,
6840 OrganiationListing,
6842 ReplicationGroup,
6844 Role,
6846 Schema,
6848 Share,
6850 User,
6852 Warehouse,
6854}
6855
6856impl fmt::Display for ActionCreateObjectType {
6857 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6858 match self {
6859 ActionCreateObjectType::Account => f.write_fmt(format_args!("ACCOUNT"))write!(f, "ACCOUNT"),
6860 ActionCreateObjectType::Application => f.write_fmt(format_args!("APPLICATION"))write!(f, "APPLICATION"),
6861 ActionCreateObjectType::ApplicationPackage => f.write_fmt(format_args!("APPLICATION PACKAGE"))write!(f, "APPLICATION PACKAGE"),
6862 ActionCreateObjectType::ComputePool => f.write_fmt(format_args!("COMPUTE POOL"))write!(f, "COMPUTE POOL"),
6863 ActionCreateObjectType::DataExchangeListing => f.write_fmt(format_args!("DATA EXCHANGE LISTING"))write!(f, "DATA EXCHANGE LISTING"),
6864 ActionCreateObjectType::Database => f.write_fmt(format_args!("DATABASE"))write!(f, "DATABASE"),
6865 ActionCreateObjectType::ExternalVolume => f.write_fmt(format_args!("EXTERNAL VOLUME"))write!(f, "EXTERNAL VOLUME"),
6866 ActionCreateObjectType::FailoverGroup => f.write_fmt(format_args!("FAILOVER GROUP"))write!(f, "FAILOVER GROUP"),
6867 ActionCreateObjectType::Integration => f.write_fmt(format_args!("INTEGRATION"))write!(f, "INTEGRATION"),
6868 ActionCreateObjectType::NetworkPolicy => f.write_fmt(format_args!("NETWORK POLICY"))write!(f, "NETWORK POLICY"),
6869 ActionCreateObjectType::OrganiationListing => f.write_fmt(format_args!("ORGANIZATION LISTING"))write!(f, "ORGANIZATION LISTING"),
6870 ActionCreateObjectType::ReplicationGroup => f.write_fmt(format_args!("REPLICATION GROUP"))write!(f, "REPLICATION GROUP"),
6871 ActionCreateObjectType::Role => f.write_fmt(format_args!("ROLE"))write!(f, "ROLE"),
6872 ActionCreateObjectType::Schema => f.write_fmt(format_args!("SCHEMA"))write!(f, "SCHEMA"),
6873 ActionCreateObjectType::Share => f.write_fmt(format_args!("SHARE"))write!(f, "SHARE"),
6874 ActionCreateObjectType::User => f.write_fmt(format_args!("USER"))write!(f, "USER"),
6875 ActionCreateObjectType::Warehouse => f.write_fmt(format_args!("WAREHOUSE"))write!(f, "WAREHOUSE"),
6876 }
6877 }
6878}
6879
6880#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ActionApplyType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ActionApplyType::AggregationPolicy => "AggregationPolicy",
ActionApplyType::AuthenticationPolicy =>
"AuthenticationPolicy",
ActionApplyType::JoinPolicy => "JoinPolicy",
ActionApplyType::MaskingPolicy => "MaskingPolicy",
ActionApplyType::PackagesPolicy => "PackagesPolicy",
ActionApplyType::PasswordPolicy => "PasswordPolicy",
ActionApplyType::ProjectionPolicy => "ProjectionPolicy",
ActionApplyType::RowAccessPolicy => "RowAccessPolicy",
ActionApplyType::SessionPolicy => "SessionPolicy",
ActionApplyType::Tag => "Tag",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ActionApplyType {
#[inline]
fn clone(&self) -> ActionApplyType {
match self {
ActionApplyType::AggregationPolicy =>
ActionApplyType::AggregationPolicy,
ActionApplyType::AuthenticationPolicy =>
ActionApplyType::AuthenticationPolicy,
ActionApplyType::JoinPolicy => ActionApplyType::JoinPolicy,
ActionApplyType::MaskingPolicy => ActionApplyType::MaskingPolicy,
ActionApplyType::PackagesPolicy =>
ActionApplyType::PackagesPolicy,
ActionApplyType::PasswordPolicy =>
ActionApplyType::PasswordPolicy,
ActionApplyType::ProjectionPolicy =>
ActionApplyType::ProjectionPolicy,
ActionApplyType::RowAccessPolicy =>
ActionApplyType::RowAccessPolicy,
ActionApplyType::SessionPolicy => ActionApplyType::SessionPolicy,
ActionApplyType::Tag => ActionApplyType::Tag,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ActionApplyType {
#[inline]
fn eq(&self, other: &ActionApplyType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ActionApplyType {
#[inline]
fn partial_cmp(&self, other: &ActionApplyType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ActionApplyType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ActionApplyType {
#[inline]
fn cmp(&self, other: &ActionApplyType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ActionApplyType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6881#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6882#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ActionApplyType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AggregationPolicy => {}
Self::AuthenticationPolicy => {}
Self::JoinPolicy => {}
Self::MaskingPolicy => {}
Self::PackagesPolicy => {}
Self::PasswordPolicy => {}
Self::ProjectionPolicy => {}
Self::RowAccessPolicy => {}
Self::SessionPolicy => {}
Self::Tag => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ActionApplyType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AggregationPolicy => {}
Self::AuthenticationPolicy => {}
Self::JoinPolicy => {}
Self::MaskingPolicy => {}
Self::PackagesPolicy => {}
Self::PasswordPolicy => {}
Self::ProjectionPolicy => {}
Self::RowAccessPolicy => {}
Self::SessionPolicy => {}
Self::Tag => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6883pub enum ActionApplyType {
6886 AggregationPolicy,
6888 AuthenticationPolicy,
6890 JoinPolicy,
6892 MaskingPolicy,
6894 PackagesPolicy,
6896 PasswordPolicy,
6898 ProjectionPolicy,
6900 RowAccessPolicy,
6902 SessionPolicy,
6904 Tag,
6906}
6907
6908impl fmt::Display for ActionApplyType {
6909 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6910 match self {
6911 ActionApplyType::AggregationPolicy => f.write_fmt(format_args!("AGGREGATION POLICY"))write!(f, "AGGREGATION POLICY"),
6912 ActionApplyType::AuthenticationPolicy => f.write_fmt(format_args!("AUTHENTICATION POLICY"))write!(f, "AUTHENTICATION POLICY"),
6913 ActionApplyType::JoinPolicy => f.write_fmt(format_args!("JOIN POLICY"))write!(f, "JOIN POLICY"),
6914 ActionApplyType::MaskingPolicy => f.write_fmt(format_args!("MASKING POLICY"))write!(f, "MASKING POLICY"),
6915 ActionApplyType::PackagesPolicy => f.write_fmt(format_args!("PACKAGES POLICY"))write!(f, "PACKAGES POLICY"),
6916 ActionApplyType::PasswordPolicy => f.write_fmt(format_args!("PASSWORD POLICY"))write!(f, "PASSWORD POLICY"),
6917 ActionApplyType::ProjectionPolicy => f.write_fmt(format_args!("PROJECTION POLICY"))write!(f, "PROJECTION POLICY"),
6918 ActionApplyType::RowAccessPolicy => f.write_fmt(format_args!("ROW ACCESS POLICY"))write!(f, "ROW ACCESS POLICY"),
6919 ActionApplyType::SessionPolicy => f.write_fmt(format_args!("SESSION POLICY"))write!(f, "SESSION POLICY"),
6920 ActionApplyType::Tag => f.write_fmt(format_args!("TAG"))write!(f, "TAG"),
6921 }
6922 }
6923}
6924
6925#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ActionExecuteObjectType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ActionExecuteObjectType::Alert => "Alert",
ActionExecuteObjectType::DataMetricFunction =>
"DataMetricFunction",
ActionExecuteObjectType::ManagedAlert => "ManagedAlert",
ActionExecuteObjectType::ManagedTask => "ManagedTask",
ActionExecuteObjectType::Task => "Task",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ActionExecuteObjectType {
#[inline]
fn clone(&self) -> ActionExecuteObjectType {
match self {
ActionExecuteObjectType::Alert => ActionExecuteObjectType::Alert,
ActionExecuteObjectType::DataMetricFunction =>
ActionExecuteObjectType::DataMetricFunction,
ActionExecuteObjectType::ManagedAlert =>
ActionExecuteObjectType::ManagedAlert,
ActionExecuteObjectType::ManagedTask =>
ActionExecuteObjectType::ManagedTask,
ActionExecuteObjectType::Task => ActionExecuteObjectType::Task,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ActionExecuteObjectType {
#[inline]
fn eq(&self, other: &ActionExecuteObjectType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ActionExecuteObjectType {
#[inline]
fn partial_cmp(&self, other: &ActionExecuteObjectType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ActionExecuteObjectType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ActionExecuteObjectType {
#[inline]
fn cmp(&self, other: &ActionExecuteObjectType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ActionExecuteObjectType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6926#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6927#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ActionExecuteObjectType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Alert => {}
Self::DataMetricFunction => {}
Self::ManagedAlert => {}
Self::ManagedTask => {}
Self::Task => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ActionExecuteObjectType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Alert => {}
Self::DataMetricFunction => {}
Self::ManagedAlert => {}
Self::ManagedTask => {}
Self::Task => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6928pub enum ActionExecuteObjectType {
6931 Alert,
6933 DataMetricFunction,
6935 ManagedAlert,
6937 ManagedTask,
6939 Task,
6941}
6942
6943impl fmt::Display for ActionExecuteObjectType {
6944 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6945 match self {
6946 ActionExecuteObjectType::Alert => f.write_fmt(format_args!("ALERT"))write!(f, "ALERT"),
6947 ActionExecuteObjectType::DataMetricFunction => f.write_fmt(format_args!("DATA METRIC FUNCTION"))write!(f, "DATA METRIC FUNCTION"),
6948 ActionExecuteObjectType::ManagedAlert => f.write_fmt(format_args!("MANAGED ALERT"))write!(f, "MANAGED ALERT"),
6949 ActionExecuteObjectType::ManagedTask => f.write_fmt(format_args!("MANAGED TASK"))write!(f, "MANAGED TASK"),
6950 ActionExecuteObjectType::Task => f.write_fmt(format_args!("TASK"))write!(f, "TASK"),
6951 }
6952 }
6953}
6954
6955#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ActionManageType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ActionManageType::AccountSupportCases =>
"AccountSupportCases",
ActionManageType::EventSharing => "EventSharing",
ActionManageType::Grants => "Grants",
ActionManageType::ListingAutoFulfillment =>
"ListingAutoFulfillment",
ActionManageType::OrganizationSupportCases =>
"OrganizationSupportCases",
ActionManageType::UserSupportCases => "UserSupportCases",
ActionManageType::Warehouses => "Warehouses",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ActionManageType {
#[inline]
fn clone(&self) -> ActionManageType {
match self {
ActionManageType::AccountSupportCases =>
ActionManageType::AccountSupportCases,
ActionManageType::EventSharing => ActionManageType::EventSharing,
ActionManageType::Grants => ActionManageType::Grants,
ActionManageType::ListingAutoFulfillment =>
ActionManageType::ListingAutoFulfillment,
ActionManageType::OrganizationSupportCases =>
ActionManageType::OrganizationSupportCases,
ActionManageType::UserSupportCases =>
ActionManageType::UserSupportCases,
ActionManageType::Warehouses => ActionManageType::Warehouses,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ActionManageType {
#[inline]
fn eq(&self, other: &ActionManageType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ActionManageType {
#[inline]
fn partial_cmp(&self, other: &ActionManageType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ActionManageType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ActionManageType {
#[inline]
fn cmp(&self, other: &ActionManageType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ActionManageType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6956#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6957#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ActionManageType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AccountSupportCases => {}
Self::EventSharing => {}
Self::Grants => {}
Self::ListingAutoFulfillment => {}
Self::OrganizationSupportCases => {}
Self::UserSupportCases => {}
Self::Warehouses => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ActionManageType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AccountSupportCases => {}
Self::EventSharing => {}
Self::Grants => {}
Self::ListingAutoFulfillment => {}
Self::OrganizationSupportCases => {}
Self::UserSupportCases => {}
Self::Warehouses => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6958pub enum ActionManageType {
6961 AccountSupportCases,
6963 EventSharing,
6965 Grants,
6967 ListingAutoFulfillment,
6969 OrganizationSupportCases,
6971 UserSupportCases,
6973 Warehouses,
6975}
6976
6977impl fmt::Display for ActionManageType {
6978 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
6979 match self {
6980 ActionManageType::AccountSupportCases => f.write_fmt(format_args!("ACCOUNT SUPPORT CASES"))write!(f, "ACCOUNT SUPPORT CASES"),
6981 ActionManageType::EventSharing => f.write_fmt(format_args!("EVENT SHARING"))write!(f, "EVENT SHARING"),
6982 ActionManageType::Grants => f.write_fmt(format_args!("GRANTS"))write!(f, "GRANTS"),
6983 ActionManageType::ListingAutoFulfillment => f.write_fmt(format_args!("LISTING AUTO FULFILLMENT"))write!(f, "LISTING AUTO FULFILLMENT"),
6984 ActionManageType::OrganizationSupportCases => f.write_fmt(format_args!("ORGANIZATION SUPPORT CASES"))write!(f, "ORGANIZATION SUPPORT CASES"),
6985 ActionManageType::UserSupportCases => f.write_fmt(format_args!("USER SUPPORT CASES"))write!(f, "USER SUPPORT CASES"),
6986 ActionManageType::Warehouses => f.write_fmt(format_args!("WAREHOUSES"))write!(f, "WAREHOUSES"),
6987 }
6988 }
6989}
6990
6991#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ActionModifyType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ActionModifyType::LogLevel => "LogLevel",
ActionModifyType::TraceLevel => "TraceLevel",
ActionModifyType::SessionLogLevel => "SessionLogLevel",
ActionModifyType::SessionTraceLevel => "SessionTraceLevel",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ActionModifyType {
#[inline]
fn clone(&self) -> ActionModifyType {
match self {
ActionModifyType::LogLevel => ActionModifyType::LogLevel,
ActionModifyType::TraceLevel => ActionModifyType::TraceLevel,
ActionModifyType::SessionLogLevel =>
ActionModifyType::SessionLogLevel,
ActionModifyType::SessionTraceLevel =>
ActionModifyType::SessionTraceLevel,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ActionModifyType {
#[inline]
fn eq(&self, other: &ActionModifyType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ActionModifyType {
#[inline]
fn partial_cmp(&self, other: &ActionModifyType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ActionModifyType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ActionModifyType {
#[inline]
fn cmp(&self, other: &ActionModifyType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ActionModifyType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
6992#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
6993#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ActionModifyType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::LogLevel => {}
Self::TraceLevel => {}
Self::SessionLogLevel => {}
Self::SessionTraceLevel => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ActionModifyType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::LogLevel => {}
Self::TraceLevel => {}
Self::SessionLogLevel => {}
Self::SessionTraceLevel => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
6994pub enum ActionModifyType {
6997 LogLevel,
6999 TraceLevel,
7001 SessionLogLevel,
7003 SessionTraceLevel,
7005}
7006
7007impl fmt::Display for ActionModifyType {
7008 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7009 match self {
7010 ActionModifyType::LogLevel => f.write_fmt(format_args!("LOG LEVEL"))write!(f, "LOG LEVEL"),
7011 ActionModifyType::TraceLevel => f.write_fmt(format_args!("TRACE LEVEL"))write!(f, "TRACE LEVEL"),
7012 ActionModifyType::SessionLogLevel => f.write_fmt(format_args!("SESSION LOG LEVEL"))write!(f, "SESSION LOG LEVEL"),
7013 ActionModifyType::SessionTraceLevel => f.write_fmt(format_args!("SESSION TRACE LEVEL"))write!(f, "SESSION TRACE LEVEL"),
7014 }
7015 }
7016}
7017
7018#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ActionMonitorType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ActionMonitorType::Execution => "Execution",
ActionMonitorType::Security => "Security",
ActionMonitorType::Usage => "Usage",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ActionMonitorType {
#[inline]
fn clone(&self) -> ActionMonitorType {
match self {
ActionMonitorType::Execution => ActionMonitorType::Execution,
ActionMonitorType::Security => ActionMonitorType::Security,
ActionMonitorType::Usage => ActionMonitorType::Usage,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ActionMonitorType {
#[inline]
fn eq(&self, other: &ActionMonitorType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ActionMonitorType {
#[inline]
fn partial_cmp(&self, other: &ActionMonitorType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ActionMonitorType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ActionMonitorType {
#[inline]
fn cmp(&self, other: &ActionMonitorType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ActionMonitorType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
7019#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7020#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ActionMonitorType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Execution => {}
Self::Security => {}
Self::Usage => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ActionMonitorType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Execution => {}
Self::Security => {}
Self::Usage => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7021pub enum ActionMonitorType {
7024 Execution,
7026 Security,
7028 Usage,
7030}
7031
7032impl fmt::Display for ActionMonitorType {
7033 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7034 match self {
7035 ActionMonitorType::Execution => f.write_fmt(format_args!("EXECUTION"))write!(f, "EXECUTION"),
7036 ActionMonitorType::Security => f.write_fmt(format_args!("SECURITY"))write!(f, "SECURITY"),
7037 ActionMonitorType::Usage => f.write_fmt(format_args!("USAGE"))write!(f, "USAGE"),
7038 }
7039 }
7040}
7041
7042#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Grantee {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "Grantee",
"grantee_type", &self.grantee_type, "name", &&self.name)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Grantee {
#[inline]
fn clone(&self) -> Grantee {
Grantee {
grantee_type: ::core::clone::Clone::clone(&self.grantee_type),
name: ::core::clone::Clone::clone(&self.name),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Grantee {
#[inline]
fn eq(&self, other: &Grantee) -> bool {
self.grantee_type == other.grantee_type && self.name == other.name
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Grantee {
#[inline]
fn partial_cmp(&self, other: &Grantee)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Grantee {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<GranteesType>;
let _: ::core::cmp::AssertParamIsEq<Option<GranteeName>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Grantee {
#[inline]
fn cmp(&self, other: &Grantee) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.grantee_type, &other.grantee_type) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.name, &other.name),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Grantee {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.grantee_type, state);
::core::hash::Hash::hash(&self.name, state)
}
}Hash)]
7044#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7045#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Grantee {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.grantee_type, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Grantee {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.grantee_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7046pub struct Grantee {
7047 pub grantee_type: GranteesType,
7049 pub name: Option<GranteeName>,
7051}
7052
7053impl fmt::Display for Grantee {
7054 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7055 match self.grantee_type {
7056 GranteesType::Role => {
7057 f.write_fmt(format_args!("ROLE "))write!(f, "ROLE ")?;
7058 }
7059 GranteesType::Share => {
7060 f.write_fmt(format_args!("SHARE "))write!(f, "SHARE ")?;
7061 }
7062 GranteesType::User => {
7063 f.write_fmt(format_args!("USER "))write!(f, "USER ")?;
7064 }
7065 GranteesType::Group => {
7066 f.write_fmt(format_args!("GROUP "))write!(f, "GROUP ")?;
7067 }
7068 GranteesType::Public => {
7069 f.write_fmt(format_args!("PUBLIC "))write!(f, "PUBLIC ")?;
7070 }
7071 GranteesType::DatabaseRole => {
7072 f.write_fmt(format_args!("DATABASE ROLE "))write!(f, "DATABASE ROLE ")?;
7073 }
7074 GranteesType::Application => {
7075 f.write_fmt(format_args!("APPLICATION "))write!(f, "APPLICATION ")?;
7076 }
7077 GranteesType::ApplicationRole => {
7078 f.write_fmt(format_args!("APPLICATION ROLE "))write!(f, "APPLICATION ROLE ")?;
7079 }
7080 GranteesType::None => (),
7081 }
7082 if let Some(ref name) = self.name {
7083 name.fmt(f)?;
7084 }
7085 Ok(())
7086 }
7087}
7088
7089#[derive(#[automatically_derived]
impl ::core::fmt::Debug for GranteesType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
GranteesType::Role => "Role",
GranteesType::Share => "Share",
GranteesType::User => "User",
GranteesType::Group => "Group",
GranteesType::Public => "Public",
GranteesType::DatabaseRole => "DatabaseRole",
GranteesType::Application => "Application",
GranteesType::ApplicationRole => "ApplicationRole",
GranteesType::None => "None",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for GranteesType {
#[inline]
fn clone(&self) -> GranteesType {
match self {
GranteesType::Role => GranteesType::Role,
GranteesType::Share => GranteesType::Share,
GranteesType::User => GranteesType::User,
GranteesType::Group => GranteesType::Group,
GranteesType::Public => GranteesType::Public,
GranteesType::DatabaseRole => GranteesType::DatabaseRole,
GranteesType::Application => GranteesType::Application,
GranteesType::ApplicationRole => GranteesType::ApplicationRole,
GranteesType::None => GranteesType::None,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for GranteesType {
#[inline]
fn eq(&self, other: &GranteesType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for GranteesType {
#[inline]
fn partial_cmp(&self, other: &GranteesType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for GranteesType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for GranteesType {
#[inline]
fn cmp(&self, other: &GranteesType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for GranteesType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
7090#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7091#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for GranteesType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Role => {}
Self::Share => {}
Self::User => {}
Self::Group => {}
Self::Public => {}
Self::DatabaseRole => {}
Self::Application => {}
Self::ApplicationRole => {}
Self::None => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for GranteesType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Role => {}
Self::Share => {}
Self::User => {}
Self::Group => {}
Self::Public => {}
Self::DatabaseRole => {}
Self::Application => {}
Self::ApplicationRole => {}
Self::None => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7092pub enum GranteesType {
7094 Role,
7096 Share,
7098 User,
7100 Group,
7102 Public,
7104 DatabaseRole,
7106 Application,
7108 ApplicationRole,
7110 None,
7112}
7113
7114#[derive(#[automatically_derived]
impl ::core::fmt::Debug for GranteeName {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
GranteeName::ObjectName(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ObjectName", &__self_0),
GranteeName::UserHost { user: __self_0, host: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"UserHost", "user", __self_0, "host", &__self_1),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for GranteeName {
#[inline]
fn clone(&self) -> GranteeName {
match self {
GranteeName::ObjectName(__self_0) =>
GranteeName::ObjectName(::core::clone::Clone::clone(__self_0)),
GranteeName::UserHost { user: __self_0, host: __self_1 } =>
GranteeName::UserHost {
user: ::core::clone::Clone::clone(__self_0),
host: ::core::clone::Clone::clone(__self_1),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for GranteeName {
#[inline]
fn eq(&self, other: &GranteeName) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(GranteeName::ObjectName(__self_0),
GranteeName::ObjectName(__arg1_0)) => __self_0 == __arg1_0,
(GranteeName::UserHost { user: __self_0, host: __self_1 },
GranteeName::UserHost { user: __arg1_0, host: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for GranteeName {
#[inline]
fn partial_cmp(&self, other: &GranteeName)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for GranteeName {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for GranteeName {
#[inline]
fn cmp(&self, other: &GranteeName) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(GranteeName::ObjectName(__self_0),
GranteeName::ObjectName(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GranteeName::UserHost { user: __self_0, host: __self_1 },
GranteeName::UserHost { user: __arg1_0, host: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for GranteeName {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
GranteeName::ObjectName(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GranteeName::UserHost { user: __self_0, host: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
}
}
}Hash)]
7116#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7117#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for GranteeName {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ObjectName(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::UserHost { user, host } => {
sqlparser::ast::Visit::visit(user, visitor)?;
sqlparser::ast::Visit::visit(host, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for GranteeName {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ObjectName(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::UserHost { user, host } => {
sqlparser::ast::VisitMut::visit(user, visitor)?;
sqlparser::ast::VisitMut::visit(host, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7118pub enum GranteeName {
7119 ObjectName(ObjectName),
7121 UserHost {
7123 user: Ident,
7125 host: Ident,
7127 },
7128}
7129
7130impl fmt::Display for GranteeName {
7131 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7132 match self {
7133 GranteeName::ObjectName(name) => name.fmt(f),
7134 GranteeName::UserHost { user, host } => {
7135 f.write_fmt(format_args!("{0}@{1}", user, host))write!(f, "{user}@{host}")
7136 }
7137 }
7138 }
7139}
7140
7141#[derive(#[automatically_derived]
impl ::core::fmt::Debug for GrantObjects {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
GrantObjects::AllSequencesInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AllSequencesInSchema", "schemas", &__self_0),
GrantObjects::AllTablesInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AllTablesInSchema", "schemas", &__self_0),
GrantObjects::AllViewsInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AllViewsInSchema", "schemas", &__self_0),
GrantObjects::AllMaterializedViewsInSchema { schemas: __self_0 }
=>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AllMaterializedViewsInSchema", "schemas", &__self_0),
GrantObjects::AllExternalTablesInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AllExternalTablesInSchema", "schemas", &__self_0),
GrantObjects::AllFunctionsInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AllFunctionsInSchema", "schemas", &__self_0),
GrantObjects::FutureSchemasInDatabase { databases: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FutureSchemasInDatabase", "databases", &__self_0),
GrantObjects::FutureTablesInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FutureTablesInSchema", "schemas", &__self_0),
GrantObjects::FutureViewsInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FutureViewsInSchema", "schemas", &__self_0),
GrantObjects::FutureExternalTablesInSchema { schemas: __self_0 }
=>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FutureExternalTablesInSchema", "schemas", &__self_0),
GrantObjects::FutureMaterializedViewsInSchema { schemas: __self_0
} =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FutureMaterializedViewsInSchema", "schemas", &__self_0),
GrantObjects::FutureSequencesInSchema { schemas: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FutureSequencesInSchema", "schemas", &__self_0),
GrantObjects::Databases(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Databases", &__self_0),
GrantObjects::Schemas(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Schemas", &__self_0),
GrantObjects::Sequences(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Sequences", &__self_0),
GrantObjects::Tables(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Tables",
&__self_0),
GrantObjects::Views(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Views",
&__self_0),
GrantObjects::Warehouses(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Warehouses", &__self_0),
GrantObjects::Integrations(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Integrations", &__self_0),
GrantObjects::ResourceMonitors(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ResourceMonitors", &__self_0),
GrantObjects::Users(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Users",
&__self_0),
GrantObjects::ComputePools(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ComputePools", &__self_0),
GrantObjects::Connections(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Connections", &__self_0),
GrantObjects::FailoverGroup(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"FailoverGroup", &__self_0),
GrantObjects::ReplicationGroup(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ReplicationGroup", &__self_0),
GrantObjects::ExternalVolumes(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ExternalVolumes", &__self_0),
GrantObjects::Procedure { name: __self_0, arg_types: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Procedure", "name", __self_0, "arg_types", &__self_1),
GrantObjects::Function { name: __self_0, arg_types: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Function", "name", __self_0, "arg_types", &__self_1),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for GrantObjects {
#[inline]
fn clone(&self) -> GrantObjects {
match self {
GrantObjects::AllSequencesInSchema { schemas: __self_0 } =>
GrantObjects::AllSequencesInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::AllTablesInSchema { schemas: __self_0 } =>
GrantObjects::AllTablesInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::AllViewsInSchema { schemas: __self_0 } =>
GrantObjects::AllViewsInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::AllMaterializedViewsInSchema { schemas: __self_0 }
=>
GrantObjects::AllMaterializedViewsInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::AllExternalTablesInSchema { schemas: __self_0 } =>
GrantObjects::AllExternalTablesInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::AllFunctionsInSchema { schemas: __self_0 } =>
GrantObjects::AllFunctionsInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::FutureSchemasInDatabase { databases: __self_0 } =>
GrantObjects::FutureSchemasInDatabase {
databases: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::FutureTablesInSchema { schemas: __self_0 } =>
GrantObjects::FutureTablesInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::FutureViewsInSchema { schemas: __self_0 } =>
GrantObjects::FutureViewsInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::FutureExternalTablesInSchema { schemas: __self_0 }
=>
GrantObjects::FutureExternalTablesInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::FutureMaterializedViewsInSchema { schemas: __self_0
} =>
GrantObjects::FutureMaterializedViewsInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::FutureSequencesInSchema { schemas: __self_0 } =>
GrantObjects::FutureSequencesInSchema {
schemas: ::core::clone::Clone::clone(__self_0),
},
GrantObjects::Databases(__self_0) =>
GrantObjects::Databases(::core::clone::Clone::clone(__self_0)),
GrantObjects::Schemas(__self_0) =>
GrantObjects::Schemas(::core::clone::Clone::clone(__self_0)),
GrantObjects::Sequences(__self_0) =>
GrantObjects::Sequences(::core::clone::Clone::clone(__self_0)),
GrantObjects::Tables(__self_0) =>
GrantObjects::Tables(::core::clone::Clone::clone(__self_0)),
GrantObjects::Views(__self_0) =>
GrantObjects::Views(::core::clone::Clone::clone(__self_0)),
GrantObjects::Warehouses(__self_0) =>
GrantObjects::Warehouses(::core::clone::Clone::clone(__self_0)),
GrantObjects::Integrations(__self_0) =>
GrantObjects::Integrations(::core::clone::Clone::clone(__self_0)),
GrantObjects::ResourceMonitors(__self_0) =>
GrantObjects::ResourceMonitors(::core::clone::Clone::clone(__self_0)),
GrantObjects::Users(__self_0) =>
GrantObjects::Users(::core::clone::Clone::clone(__self_0)),
GrantObjects::ComputePools(__self_0) =>
GrantObjects::ComputePools(::core::clone::Clone::clone(__self_0)),
GrantObjects::Connections(__self_0) =>
GrantObjects::Connections(::core::clone::Clone::clone(__self_0)),
GrantObjects::FailoverGroup(__self_0) =>
GrantObjects::FailoverGroup(::core::clone::Clone::clone(__self_0)),
GrantObjects::ReplicationGroup(__self_0) =>
GrantObjects::ReplicationGroup(::core::clone::Clone::clone(__self_0)),
GrantObjects::ExternalVolumes(__self_0) =>
GrantObjects::ExternalVolumes(::core::clone::Clone::clone(__self_0)),
GrantObjects::Procedure { name: __self_0, arg_types: __self_1 } =>
GrantObjects::Procedure {
name: ::core::clone::Clone::clone(__self_0),
arg_types: ::core::clone::Clone::clone(__self_1),
},
GrantObjects::Function { name: __self_0, arg_types: __self_1 } =>
GrantObjects::Function {
name: ::core::clone::Clone::clone(__self_0),
arg_types: ::core::clone::Clone::clone(__self_1),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for GrantObjects {
#[inline]
fn eq(&self, other: &GrantObjects) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(GrantObjects::AllSequencesInSchema { schemas: __self_0 },
GrantObjects::AllSequencesInSchema { schemas: __arg1_0 }) =>
__self_0 == __arg1_0,
(GrantObjects::AllTablesInSchema { schemas: __self_0 },
GrantObjects::AllTablesInSchema { schemas: __arg1_0 }) =>
__self_0 == __arg1_0,
(GrantObjects::AllViewsInSchema { schemas: __self_0 },
GrantObjects::AllViewsInSchema { schemas: __arg1_0 }) =>
__self_0 == __arg1_0,
(GrantObjects::AllMaterializedViewsInSchema {
schemas: __self_0 },
GrantObjects::AllMaterializedViewsInSchema {
schemas: __arg1_0 }) => __self_0 == __arg1_0,
(GrantObjects::AllExternalTablesInSchema { schemas: __self_0
}, GrantObjects::AllExternalTablesInSchema {
schemas: __arg1_0 }) => __self_0 == __arg1_0,
(GrantObjects::AllFunctionsInSchema { schemas: __self_0 },
GrantObjects::AllFunctionsInSchema { schemas: __arg1_0 }) =>
__self_0 == __arg1_0,
(GrantObjects::FutureSchemasInDatabase { databases: __self_0
}, GrantObjects::FutureSchemasInDatabase {
databases: __arg1_0 }) => __self_0 == __arg1_0,
(GrantObjects::FutureTablesInSchema { schemas: __self_0 },
GrantObjects::FutureTablesInSchema { schemas: __arg1_0 }) =>
__self_0 == __arg1_0,
(GrantObjects::FutureViewsInSchema { schemas: __self_0 },
GrantObjects::FutureViewsInSchema { schemas: __arg1_0 }) =>
__self_0 == __arg1_0,
(GrantObjects::FutureExternalTablesInSchema {
schemas: __self_0 },
GrantObjects::FutureExternalTablesInSchema {
schemas: __arg1_0 }) => __self_0 == __arg1_0,
(GrantObjects::FutureMaterializedViewsInSchema {
schemas: __self_0 },
GrantObjects::FutureMaterializedViewsInSchema {
schemas: __arg1_0 }) => __self_0 == __arg1_0,
(GrantObjects::FutureSequencesInSchema { schemas: __self_0 },
GrantObjects::FutureSequencesInSchema { schemas: __arg1_0 })
=> __self_0 == __arg1_0,
(GrantObjects::Databases(__self_0),
GrantObjects::Databases(__arg1_0)) => __self_0 == __arg1_0,
(GrantObjects::Schemas(__self_0),
GrantObjects::Schemas(__arg1_0)) => __self_0 == __arg1_0,
(GrantObjects::Sequences(__self_0),
GrantObjects::Sequences(__arg1_0)) => __self_0 == __arg1_0,
(GrantObjects::Tables(__self_0),
GrantObjects::Tables(__arg1_0)) => __self_0 == __arg1_0,
(GrantObjects::Views(__self_0), GrantObjects::Views(__arg1_0))
=> __self_0 == __arg1_0,
(GrantObjects::Warehouses(__self_0),
GrantObjects::Warehouses(__arg1_0)) => __self_0 == __arg1_0,
(GrantObjects::Integrations(__self_0),
GrantObjects::Integrations(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::ResourceMonitors(__self_0),
GrantObjects::ResourceMonitors(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::Users(__self_0), GrantObjects::Users(__arg1_0))
=> __self_0 == __arg1_0,
(GrantObjects::ComputePools(__self_0),
GrantObjects::ComputePools(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::Connections(__self_0),
GrantObjects::Connections(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::FailoverGroup(__self_0),
GrantObjects::FailoverGroup(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::ReplicationGroup(__self_0),
GrantObjects::ReplicationGroup(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::ExternalVolumes(__self_0),
GrantObjects::ExternalVolumes(__arg1_0)) =>
__self_0 == __arg1_0,
(GrantObjects::Procedure { name: __self_0, arg_types: __self_1
}, GrantObjects::Procedure {
name: __arg1_0, arg_types: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(GrantObjects::Function { name: __self_0, arg_types: __self_1
}, GrantObjects::Function {
name: __arg1_0, arg_types: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for GrantObjects {
#[inline]
fn partial_cmp(&self, other: &GrantObjects)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for GrantObjects {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Vec<DataType>>;
let _: ::core::cmp::AssertParamIsEq<Vec<DataType>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for GrantObjects {
#[inline]
fn cmp(&self, other: &GrantObjects) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(GrantObjects::AllSequencesInSchema { schemas: __self_0 },
GrantObjects::AllSequencesInSchema { schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::AllTablesInSchema { schemas: __self_0 },
GrantObjects::AllTablesInSchema { schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::AllViewsInSchema { schemas: __self_0 },
GrantObjects::AllViewsInSchema { schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::AllMaterializedViewsInSchema {
schemas: __self_0 },
GrantObjects::AllMaterializedViewsInSchema {
schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::AllExternalTablesInSchema { schemas: __self_0
}, GrantObjects::AllExternalTablesInSchema {
schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::AllFunctionsInSchema { schemas: __self_0 },
GrantObjects::AllFunctionsInSchema { schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FutureSchemasInDatabase { databases: __self_0
}, GrantObjects::FutureSchemasInDatabase {
databases: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FutureTablesInSchema { schemas: __self_0 },
GrantObjects::FutureTablesInSchema { schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FutureViewsInSchema { schemas: __self_0 },
GrantObjects::FutureViewsInSchema { schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FutureExternalTablesInSchema {
schemas: __self_0 },
GrantObjects::FutureExternalTablesInSchema {
schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FutureMaterializedViewsInSchema {
schemas: __self_0 },
GrantObjects::FutureMaterializedViewsInSchema {
schemas: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FutureSequencesInSchema { schemas: __self_0
}, GrantObjects::FutureSequencesInSchema { schemas: __arg1_0
}) => ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Databases(__self_0),
GrantObjects::Databases(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Schemas(__self_0),
GrantObjects::Schemas(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Sequences(__self_0),
GrantObjects::Sequences(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Tables(__self_0),
GrantObjects::Tables(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Views(__self_0),
GrantObjects::Views(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Warehouses(__self_0),
GrantObjects::Warehouses(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Integrations(__self_0),
GrantObjects::Integrations(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::ResourceMonitors(__self_0),
GrantObjects::ResourceMonitors(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Users(__self_0),
GrantObjects::Users(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::ComputePools(__self_0),
GrantObjects::ComputePools(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Connections(__self_0),
GrantObjects::Connections(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::FailoverGroup(__self_0),
GrantObjects::FailoverGroup(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::ReplicationGroup(__self_0),
GrantObjects::ReplicationGroup(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::ExternalVolumes(__self_0),
GrantObjects::ExternalVolumes(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(GrantObjects::Procedure {
name: __self_0, arg_types: __self_1 },
GrantObjects::Procedure {
name: __arg1_0, arg_types: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(GrantObjects::Function {
name: __self_0, arg_types: __self_1 },
GrantObjects::Function { name: __arg1_0, arg_types: __arg1_1
}) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for GrantObjects {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
GrantObjects::AllSequencesInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::AllTablesInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::AllViewsInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::AllMaterializedViewsInSchema { schemas: __self_0 }
=> ::core::hash::Hash::hash(__self_0, state),
GrantObjects::AllExternalTablesInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::AllFunctionsInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::FutureSchemasInDatabase { databases: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::FutureTablesInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::FutureViewsInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::FutureExternalTablesInSchema { schemas: __self_0 }
=> ::core::hash::Hash::hash(__self_0, state),
GrantObjects::FutureMaterializedViewsInSchema { schemas: __self_0
} => ::core::hash::Hash::hash(__self_0, state),
GrantObjects::FutureSequencesInSchema { schemas: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Databases(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Schemas(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Sequences(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Tables(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Views(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Warehouses(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Integrations(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::ResourceMonitors(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Users(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::ComputePools(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Connections(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::FailoverGroup(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::ReplicationGroup(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::ExternalVolumes(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
GrantObjects::Procedure { name: __self_0, arg_types: __self_1 } =>
{
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
GrantObjects::Function { name: __self_0, arg_types: __self_1 } =>
{
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
}
}
}Hash)]
7143#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7144#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for GrantObjects {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AllSequencesInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::AllTablesInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::AllViewsInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::AllMaterializedViewsInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::AllExternalTablesInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::AllFunctionsInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::FutureSchemasInDatabase { databases } => {
sqlparser::ast::Visit::visit(databases, visitor)?;
}
Self::FutureTablesInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::FutureViewsInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::FutureExternalTablesInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::FutureMaterializedViewsInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::FutureSequencesInSchema { schemas } => {
sqlparser::ast::Visit::visit(schemas, visitor)?;
}
Self::Databases(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Schemas(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Sequences(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Tables(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Views(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Warehouses(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Integrations(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ResourceMonitors(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Users(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ComputePools(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Connections(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::FailoverGroup(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ReplicationGroup(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ExternalVolumes(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Procedure { name, arg_types } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(arg_types, visitor)?;
}
Self::Function { name, arg_types } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(arg_types, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for GrantObjects {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AllSequencesInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::AllTablesInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::AllViewsInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::AllMaterializedViewsInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::AllExternalTablesInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::AllFunctionsInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::FutureSchemasInDatabase { databases } => {
sqlparser::ast::VisitMut::visit(databases, visitor)?;
}
Self::FutureTablesInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::FutureViewsInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::FutureExternalTablesInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::FutureMaterializedViewsInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::FutureSequencesInSchema { schemas } => {
sqlparser::ast::VisitMut::visit(schemas, visitor)?;
}
Self::Databases(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Schemas(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Sequences(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Tables(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Views(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Warehouses(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Integrations(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ResourceMonitors(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Users(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ComputePools(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Connections(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::FailoverGroup(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ReplicationGroup(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ExternalVolumes(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Procedure { name, arg_types } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(arg_types, visitor)?;
}
Self::Function { name, arg_types } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(arg_types, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7145pub enum GrantObjects {
7146 AllSequencesInSchema {
7148 schemas: Vec<ObjectName>,
7150 },
7151 AllTablesInSchema {
7153 schemas: Vec<ObjectName>,
7155 },
7156 AllViewsInSchema {
7158 schemas: Vec<ObjectName>,
7160 },
7161 AllMaterializedViewsInSchema {
7163 schemas: Vec<ObjectName>,
7165 },
7166 AllExternalTablesInSchema {
7168 schemas: Vec<ObjectName>,
7170 },
7171 AllFunctionsInSchema {
7173 schemas: Vec<ObjectName>,
7175 },
7176 FutureSchemasInDatabase {
7178 databases: Vec<ObjectName>,
7180 },
7181 FutureTablesInSchema {
7183 schemas: Vec<ObjectName>,
7185 },
7186 FutureViewsInSchema {
7188 schemas: Vec<ObjectName>,
7190 },
7191 FutureExternalTablesInSchema {
7193 schemas: Vec<ObjectName>,
7195 },
7196 FutureMaterializedViewsInSchema {
7198 schemas: Vec<ObjectName>,
7200 },
7201 FutureSequencesInSchema {
7203 schemas: Vec<ObjectName>,
7205 },
7206 Databases(Vec<ObjectName>),
7208 Schemas(Vec<ObjectName>),
7210 Sequences(Vec<ObjectName>),
7212 Tables(Vec<ObjectName>),
7214 Views(Vec<ObjectName>),
7216 Warehouses(Vec<ObjectName>),
7218 Integrations(Vec<ObjectName>),
7220 ResourceMonitors(Vec<ObjectName>),
7222 Users(Vec<ObjectName>),
7224 ComputePools(Vec<ObjectName>),
7226 Connections(Vec<ObjectName>),
7228 FailoverGroup(Vec<ObjectName>),
7230 ReplicationGroup(Vec<ObjectName>),
7232 ExternalVolumes(Vec<ObjectName>),
7234 Procedure {
7240 name: ObjectName,
7242 arg_types: Vec<DataType>,
7244 },
7245
7246 Function {
7252 name: ObjectName,
7254 arg_types: Vec<DataType>,
7256 },
7257}
7258
7259impl fmt::Display for GrantObjects {
7260 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7261 match self {
7262 GrantObjects::Sequences(sequences) => {
7263 f.write_fmt(format_args!("SEQUENCE {0}", display_comma_separated(sequences)))write!(f, "SEQUENCE {}", display_comma_separated(sequences))
7264 }
7265 GrantObjects::Databases(databases) => {
7266 f.write_fmt(format_args!("DATABASE {0}", display_comma_separated(databases)))write!(f, "DATABASE {}", display_comma_separated(databases))
7267 }
7268 GrantObjects::Schemas(schemas) => {
7269 f.write_fmt(format_args!("SCHEMA {0}", display_comma_separated(schemas)))write!(f, "SCHEMA {}", display_comma_separated(schemas))
7270 }
7271 GrantObjects::Tables(tables) => {
7272 f.write_fmt(format_args!("{0}", display_comma_separated(tables)))write!(f, "{}", display_comma_separated(tables))
7273 }
7274 GrantObjects::Views(views) => {
7275 f.write_fmt(format_args!("VIEW {0}", display_comma_separated(views)))write!(f, "VIEW {}", display_comma_separated(views))
7276 }
7277 GrantObjects::Warehouses(warehouses) => {
7278 f.write_fmt(format_args!("WAREHOUSE {0}",
display_comma_separated(warehouses)))write!(f, "WAREHOUSE {}", display_comma_separated(warehouses))
7279 }
7280 GrantObjects::Integrations(integrations) => {
7281 f.write_fmt(format_args!("INTEGRATION {0}",
display_comma_separated(integrations)))write!(f, "INTEGRATION {}", display_comma_separated(integrations))
7282 }
7283 GrantObjects::AllSequencesInSchema { schemas } => {
7284 f.write_fmt(format_args!("ALL SEQUENCES IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7285 f,
7286 "ALL SEQUENCES IN SCHEMA {}",
7287 display_comma_separated(schemas)
7288 )
7289 }
7290 GrantObjects::AllTablesInSchema { schemas } => {
7291 f.write_fmt(format_args!("ALL TABLES IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7292 f,
7293 "ALL TABLES IN SCHEMA {}",
7294 display_comma_separated(schemas)
7295 )
7296 }
7297 GrantObjects::AllExternalTablesInSchema { schemas } => {
7298 f.write_fmt(format_args!("ALL EXTERNAL TABLES IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7299 f,
7300 "ALL EXTERNAL TABLES IN SCHEMA {}",
7301 display_comma_separated(schemas)
7302 )
7303 }
7304 GrantObjects::AllViewsInSchema { schemas } => {
7305 f.write_fmt(format_args!("ALL VIEWS IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7306 f,
7307 "ALL VIEWS IN SCHEMA {}",
7308 display_comma_separated(schemas)
7309 )
7310 }
7311 GrantObjects::AllMaterializedViewsInSchema { schemas } => {
7312 f.write_fmt(format_args!("ALL MATERIALIZED VIEWS IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7313 f,
7314 "ALL MATERIALIZED VIEWS IN SCHEMA {}",
7315 display_comma_separated(schemas)
7316 )
7317 }
7318 GrantObjects::AllFunctionsInSchema { schemas } => {
7319 f.write_fmt(format_args!("ALL FUNCTIONS IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7320 f,
7321 "ALL FUNCTIONS IN SCHEMA {}",
7322 display_comma_separated(schemas)
7323 )
7324 }
7325 GrantObjects::FutureSchemasInDatabase { databases } => {
7326 f.write_fmt(format_args!("FUTURE SCHEMAS IN DATABASE {0}",
display_comma_separated(databases)))write!(
7327 f,
7328 "FUTURE SCHEMAS IN DATABASE {}",
7329 display_comma_separated(databases)
7330 )
7331 }
7332 GrantObjects::FutureTablesInSchema { schemas } => {
7333 f.write_fmt(format_args!("FUTURE TABLES IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7334 f,
7335 "FUTURE TABLES IN SCHEMA {}",
7336 display_comma_separated(schemas)
7337 )
7338 }
7339 GrantObjects::FutureExternalTablesInSchema { schemas } => {
7340 f.write_fmt(format_args!("FUTURE EXTERNAL TABLES IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7341 f,
7342 "FUTURE EXTERNAL TABLES IN SCHEMA {}",
7343 display_comma_separated(schemas)
7344 )
7345 }
7346 GrantObjects::FutureViewsInSchema { schemas } => {
7347 f.write_fmt(format_args!("FUTURE VIEWS IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7348 f,
7349 "FUTURE VIEWS IN SCHEMA {}",
7350 display_comma_separated(schemas)
7351 )
7352 }
7353 GrantObjects::FutureMaterializedViewsInSchema { schemas } => {
7354 f.write_fmt(format_args!("FUTURE MATERIALIZED VIEWS IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7355 f,
7356 "FUTURE MATERIALIZED VIEWS IN SCHEMA {}",
7357 display_comma_separated(schemas)
7358 )
7359 }
7360 GrantObjects::FutureSequencesInSchema { schemas } => {
7361 f.write_fmt(format_args!("FUTURE SEQUENCES IN SCHEMA {0}",
display_comma_separated(schemas)))write!(
7362 f,
7363 "FUTURE SEQUENCES IN SCHEMA {}",
7364 display_comma_separated(schemas)
7365 )
7366 }
7367 GrantObjects::ResourceMonitors(objects) => {
7368 f.write_fmt(format_args!("RESOURCE MONITOR {0}",
display_comma_separated(objects)))write!(f, "RESOURCE MONITOR {}", display_comma_separated(objects))
7369 }
7370 GrantObjects::Users(objects) => {
7371 f.write_fmt(format_args!("USER {0}", display_comma_separated(objects)))write!(f, "USER {}", display_comma_separated(objects))
7372 }
7373 GrantObjects::ComputePools(objects) => {
7374 f.write_fmt(format_args!("COMPUTE POOL {0}",
display_comma_separated(objects)))write!(f, "COMPUTE POOL {}", display_comma_separated(objects))
7375 }
7376 GrantObjects::Connections(objects) => {
7377 f.write_fmt(format_args!("CONNECTION {0}", display_comma_separated(objects)))write!(f, "CONNECTION {}", display_comma_separated(objects))
7378 }
7379 GrantObjects::FailoverGroup(objects) => {
7380 f.write_fmt(format_args!("FAILOVER GROUP {0}",
display_comma_separated(objects)))write!(f, "FAILOVER GROUP {}", display_comma_separated(objects))
7381 }
7382 GrantObjects::ReplicationGroup(objects) => {
7383 f.write_fmt(format_args!("REPLICATION GROUP {0}",
display_comma_separated(objects)))write!(f, "REPLICATION GROUP {}", display_comma_separated(objects))
7384 }
7385 GrantObjects::ExternalVolumes(objects) => {
7386 f.write_fmt(format_args!("EXTERNAL VOLUME {0}",
display_comma_separated(objects)))write!(f, "EXTERNAL VOLUME {}", display_comma_separated(objects))
7387 }
7388 GrantObjects::Procedure { name, arg_types } => {
7389 f.write_fmt(format_args!("PROCEDURE {0}", name))write!(f, "PROCEDURE {name}")?;
7390 if !arg_types.is_empty() {
7391 f.write_fmt(format_args!("({0})", display_comma_separated(arg_types)))write!(f, "({})", display_comma_separated(arg_types))?;
7392 }
7393 Ok(())
7394 }
7395 GrantObjects::Function { name, arg_types } => {
7396 f.write_fmt(format_args!("FUNCTION {0}", name))write!(f, "FUNCTION {name}")?;
7397 if !arg_types.is_empty() {
7398 f.write_fmt(format_args!("({0})", display_comma_separated(arg_types)))write!(f, "({})", display_comma_separated(arg_types))?;
7399 }
7400 Ok(())
7401 }
7402 }
7403 }
7404}
7405
7406#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DenyStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field5_finish(f, "DenyStatement",
"privileges", &self.privileges, "objects", &self.objects,
"grantees", &self.grantees, "granted_by", &self.granted_by,
"cascade", &&self.cascade)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DenyStatement {
#[inline]
fn clone(&self) -> DenyStatement {
DenyStatement {
privileges: ::core::clone::Clone::clone(&self.privileges),
objects: ::core::clone::Clone::clone(&self.objects),
grantees: ::core::clone::Clone::clone(&self.grantees),
granted_by: ::core::clone::Clone::clone(&self.granted_by),
cascade: ::core::clone::Clone::clone(&self.cascade),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DenyStatement {
#[inline]
fn eq(&self, other: &DenyStatement) -> bool {
self.privileges == other.privileges && self.objects == other.objects
&& self.grantees == other.grantees &&
self.granted_by == other.granted_by &&
self.cascade == other.cascade
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DenyStatement {
#[inline]
fn partial_cmp(&self, other: &DenyStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DenyStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Privileges>;
let _: ::core::cmp::AssertParamIsEq<GrantObjects>;
let _: ::core::cmp::AssertParamIsEq<Vec<Grantee>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<CascadeOption>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DenyStatement {
#[inline]
fn cmp(&self, other: &DenyStatement) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.privileges, &other.privileges) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.objects, &other.objects) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.grantees, &other.grantees)
{
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.granted_by,
&other.granted_by) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.cascade, &other.cascade),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DenyStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.privileges, state);
::core::hash::Hash::hash(&self.objects, state);
::core::hash::Hash::hash(&self.grantees, state);
::core::hash::Hash::hash(&self.granted_by, state);
::core::hash::Hash::hash(&self.cascade, state)
}
}Hash)]
7410#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7411#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DenyStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.privileges, visitor)?;
sqlparser::ast::Visit::visit(&self.objects, visitor)?;
sqlparser::ast::Visit::visit(&self.grantees, visitor)?;
sqlparser::ast::Visit::visit(&self.granted_by, visitor)?;
sqlparser::ast::Visit::visit(&self.cascade, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DenyStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.privileges,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.objects,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.grantees,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.granted_by,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.cascade,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7412pub struct DenyStatement {
7413 pub privileges: Privileges,
7415 pub objects: GrantObjects,
7417 pub grantees: Vec<Grantee>,
7419 pub granted_by: Option<Ident>,
7421 pub cascade: Option<CascadeOption>,
7423}
7424
7425impl fmt::Display for DenyStatement {
7426 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7427 f.write_fmt(format_args!("DENY {0}", self.privileges))write!(f, "DENY {}", self.privileges)?;
7428 f.write_fmt(format_args!(" ON {0}", self.objects))write!(f, " ON {}", self.objects)?;
7429 if !self.grantees.is_empty() {
7430 f.write_fmt(format_args!(" TO {0}", display_comma_separated(&self.grantees)))write!(f, " TO {}", display_comma_separated(&self.grantees))?;
7431 }
7432 if let Some(cascade) = &self.cascade {
7433 f.write_fmt(format_args!(" {0}", cascade))write!(f, " {cascade}")?;
7434 }
7435 if let Some(granted_by) = &self.granted_by {
7436 f.write_fmt(format_args!(" AS {0}", granted_by))write!(f, " AS {granted_by}")?;
7437 }
7438 Ok(())
7439 }
7440}
7441
7442#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Assignment {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "Assignment",
"target", &self.target, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Assignment {
#[inline]
fn clone(&self) -> Assignment {
Assignment {
target: ::core::clone::Clone::clone(&self.target),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Assignment {
#[inline]
fn eq(&self, other: &Assignment) -> bool {
self.target == other.target && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Assignment {
#[inline]
fn partial_cmp(&self, other: &Assignment)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Assignment {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<AssignmentTarget>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Assignment {
#[inline]
fn cmp(&self, other: &Assignment) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.target, &other.target) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Assignment {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.target, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
7444#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7445#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Assignment {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.target, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Assignment {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.target, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7446pub struct Assignment {
7447 pub target: AssignmentTarget,
7449 pub value: Expr,
7451}
7452
7453impl fmt::Display for Assignment {
7454 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7455 f.write_fmt(format_args!("{0} = {1}", self.target, self.value))write!(f, "{} = {}", self.target, self.value)
7456 }
7457}
7458
7459#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AssignmentTarget {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
AssignmentTarget::ColumnName(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ColumnName", &__self_0),
AssignmentTarget::Tuple(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Tuple",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AssignmentTarget {
#[inline]
fn clone(&self) -> AssignmentTarget {
match self {
AssignmentTarget::ColumnName(__self_0) =>
AssignmentTarget::ColumnName(::core::clone::Clone::clone(__self_0)),
AssignmentTarget::Tuple(__self_0) =>
AssignmentTarget::Tuple(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AssignmentTarget {
#[inline]
fn eq(&self, other: &AssignmentTarget) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(AssignmentTarget::ColumnName(__self_0),
AssignmentTarget::ColumnName(__arg1_0)) =>
__self_0 == __arg1_0,
(AssignmentTarget::Tuple(__self_0),
AssignmentTarget::Tuple(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AssignmentTarget {
#[inline]
fn partial_cmp(&self, other: &AssignmentTarget)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AssignmentTarget {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Vec<ObjectName>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AssignmentTarget {
#[inline]
fn cmp(&self, other: &AssignmentTarget) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(AssignmentTarget::ColumnName(__self_0),
AssignmentTarget::ColumnName(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(AssignmentTarget::Tuple(__self_0),
AssignmentTarget::Tuple(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AssignmentTarget {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
AssignmentTarget::ColumnName(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
AssignmentTarget::Tuple(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
7463#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7464#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AssignmentTarget {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ColumnName(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Tuple(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AssignmentTarget {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ColumnName(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Tuple(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7465pub enum AssignmentTarget {
7466 ColumnName(ObjectName),
7468 Tuple(Vec<ObjectName>),
7470}
7471
7472impl fmt::Display for AssignmentTarget {
7473 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7474 match self {
7475 AssignmentTarget::ColumnName(column) => f.write_fmt(format_args!("{0}", column))write!(f, "{column}"),
7476 AssignmentTarget::Tuple(columns) => f.write_fmt(format_args!("({0})", display_comma_separated(columns)))write!(f, "({})", display_comma_separated(columns)),
7477 }
7478 }
7479}
7480
7481#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionArgExpr {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FunctionArgExpr::Expr(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Expr",
&__self_0),
FunctionArgExpr::QualifiedWildcard(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"QualifiedWildcard", &__self_0),
FunctionArgExpr::Wildcard =>
::core::fmt::Formatter::write_str(f, "Wildcard"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionArgExpr {
#[inline]
fn clone(&self) -> FunctionArgExpr {
match self {
FunctionArgExpr::Expr(__self_0) =>
FunctionArgExpr::Expr(::core::clone::Clone::clone(__self_0)),
FunctionArgExpr::QualifiedWildcard(__self_0) =>
FunctionArgExpr::QualifiedWildcard(::core::clone::Clone::clone(__self_0)),
FunctionArgExpr::Wildcard => FunctionArgExpr::Wildcard,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionArgExpr {
#[inline]
fn eq(&self, other: &FunctionArgExpr) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FunctionArgExpr::Expr(__self_0),
FunctionArgExpr::Expr(__arg1_0)) => __self_0 == __arg1_0,
(FunctionArgExpr::QualifiedWildcard(__self_0),
FunctionArgExpr::QualifiedWildcard(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionArgExpr {
#[inline]
fn partial_cmp(&self, other: &FunctionArgExpr)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionArgExpr {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionArgExpr {
#[inline]
fn cmp(&self, other: &FunctionArgExpr) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FunctionArgExpr::Expr(__self_0),
FunctionArgExpr::Expr(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgExpr::QualifiedWildcard(__self_0),
FunctionArgExpr::QualifiedWildcard(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionArgExpr {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FunctionArgExpr::Expr(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgExpr::QualifiedWildcard(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
7482#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7483#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionArgExpr {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::QualifiedWildcard(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Wildcard => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionArgExpr {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::QualifiedWildcard(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Wildcard => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7484pub enum FunctionArgExpr {
7486 Expr(Expr),
7488 QualifiedWildcard(ObjectName),
7490 Wildcard,
7492}
7493
7494impl From<Expr> for FunctionArgExpr {
7495 fn from(wildcard_expr: Expr) -> Self {
7496 match wildcard_expr {
7497 Expr::QualifiedWildcard(prefix, _) => Self::QualifiedWildcard(prefix),
7498 Expr::Wildcard(_) => Self::Wildcard,
7499 expr => Self::Expr(expr),
7500 }
7501 }
7502}
7503
7504impl fmt::Display for FunctionArgExpr {
7505 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7506 match self {
7507 FunctionArgExpr::Expr(expr) => f.write_fmt(format_args!("{0}", expr))write!(f, "{expr}"),
7508 FunctionArgExpr::QualifiedWildcard(prefix) => f.write_fmt(format_args!("{0}.*", prefix))write!(f, "{prefix}.*"),
7509 FunctionArgExpr::Wildcard => f.write_str("*"),
7510 }
7511 }
7512}
7513
7514#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionArgOperator {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FunctionArgOperator::Equals => "Equals",
FunctionArgOperator::RightArrow => "RightArrow",
FunctionArgOperator::Assignment => "Assignment",
FunctionArgOperator::Colon => "Colon",
FunctionArgOperator::Value => "Value",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionArgOperator {
#[inline]
fn clone(&self) -> FunctionArgOperator {
match self {
FunctionArgOperator::Equals => FunctionArgOperator::Equals,
FunctionArgOperator::RightArrow =>
FunctionArgOperator::RightArrow,
FunctionArgOperator::Assignment =>
FunctionArgOperator::Assignment,
FunctionArgOperator::Colon => FunctionArgOperator::Colon,
FunctionArgOperator::Value => FunctionArgOperator::Value,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionArgOperator {
#[inline]
fn eq(&self, other: &FunctionArgOperator) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionArgOperator {
#[inline]
fn partial_cmp(&self, other: &FunctionArgOperator)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionArgOperator {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionArgOperator {
#[inline]
fn cmp(&self, other: &FunctionArgOperator) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionArgOperator {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
7515#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7516#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionArgOperator {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Equals => {}
Self::RightArrow => {}
Self::Assignment => {}
Self::Colon => {}
Self::Value => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionArgOperator {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Equals => {}
Self::RightArrow => {}
Self::Assignment => {}
Self::Colon => {}
Self::Value => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7517pub enum FunctionArgOperator {
7519 Equals,
7521 RightArrow,
7523 Assignment,
7525 Colon,
7527 Value,
7529}
7530
7531impl fmt::Display for FunctionArgOperator {
7532 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7533 match self {
7534 FunctionArgOperator::Equals => f.write_str("="),
7535 FunctionArgOperator::RightArrow => f.write_str("=>"),
7536 FunctionArgOperator::Assignment => f.write_str(":="),
7537 FunctionArgOperator::Colon => f.write_str(":"),
7538 FunctionArgOperator::Value => f.write_str("VALUE"),
7539 }
7540 }
7541}
7542
7543#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionArg {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FunctionArg::Named {
name: __self_0, arg: __self_1, operator: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f, "Named",
"name", __self_0, "arg", __self_1, "operator", &__self_2),
FunctionArg::ExprNamed {
name: __self_0, arg: __self_1, operator: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ExprNamed", "name", __self_0, "arg", __self_1, "operator",
&__self_2),
FunctionArg::Unnamed(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Unnamed", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionArg {
#[inline]
fn clone(&self) -> FunctionArg {
match self {
FunctionArg::Named {
name: __self_0, arg: __self_1, operator: __self_2 } =>
FunctionArg::Named {
name: ::core::clone::Clone::clone(__self_0),
arg: ::core::clone::Clone::clone(__self_1),
operator: ::core::clone::Clone::clone(__self_2),
},
FunctionArg::ExprNamed {
name: __self_0, arg: __self_1, operator: __self_2 } =>
FunctionArg::ExprNamed {
name: ::core::clone::Clone::clone(__self_0),
arg: ::core::clone::Clone::clone(__self_1),
operator: ::core::clone::Clone::clone(__self_2),
},
FunctionArg::Unnamed(__self_0) =>
FunctionArg::Unnamed(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionArg {
#[inline]
fn eq(&self, other: &FunctionArg) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FunctionArg::Named {
name: __self_0, arg: __self_1, operator: __self_2 },
FunctionArg::Named {
name: __arg1_0, arg: __arg1_1, operator: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(FunctionArg::ExprNamed {
name: __self_0, arg: __self_1, operator: __self_2 },
FunctionArg::ExprNamed {
name: __arg1_0, arg: __arg1_1, operator: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(FunctionArg::Unnamed(__self_0),
FunctionArg::Unnamed(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionArg {
#[inline]
fn partial_cmp(&self, other: &FunctionArg)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionArg {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<FunctionArgExpr>;
let _: ::core::cmp::AssertParamIsEq<FunctionArgOperator>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionArg {
#[inline]
fn cmp(&self, other: &FunctionArg) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FunctionArg::Named {
name: __self_0, arg: __self_1, operator: __self_2 },
FunctionArg::Named {
name: __arg1_0, arg: __arg1_1, operator: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(FunctionArg::ExprNamed {
name: __self_0, arg: __self_1, operator: __self_2 },
FunctionArg::ExprNamed {
name: __arg1_0, arg: __arg1_1, operator: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(FunctionArg::Unnamed(__self_0),
FunctionArg::Unnamed(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionArg {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FunctionArg::Named {
name: __self_0, arg: __self_1, operator: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
FunctionArg::ExprNamed {
name: __self_0, arg: __self_1, operator: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
FunctionArg::Unnamed(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
7544#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7545#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionArg {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Named { name, arg, operator } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(arg, visitor)?;
sqlparser::ast::Visit::visit(operator, visitor)?;
}
Self::ExprNamed { name, arg, operator } => {
sqlparser::ast::Visit::visit(name, visitor)?;
sqlparser::ast::Visit::visit(arg, visitor)?;
sqlparser::ast::Visit::visit(operator, visitor)?;
}
Self::Unnamed(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionArg {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Named { name, arg, operator } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(arg, visitor)?;
sqlparser::ast::VisitMut::visit(operator, visitor)?;
}
Self::ExprNamed { name, arg, operator } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
sqlparser::ast::VisitMut::visit(arg, visitor)?;
sqlparser::ast::VisitMut::visit(operator, visitor)?;
}
Self::Unnamed(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7546pub enum FunctionArg {
7548 Named {
7552 name: Ident,
7554 arg: FunctionArgExpr,
7556 operator: FunctionArgOperator,
7558 },
7559 ExprNamed {
7563 name: Expr,
7565 arg: FunctionArgExpr,
7567 operator: FunctionArgOperator,
7569 },
7570 Unnamed(FunctionArgExpr),
7572}
7573
7574impl fmt::Display for FunctionArg {
7575 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7576 match self {
7577 FunctionArg::Named {
7578 name,
7579 arg,
7580 operator,
7581 } => f.write_fmt(format_args!("{0} {1} {2}", name, operator, arg))write!(f, "{name} {operator} {arg}"),
7582 FunctionArg::ExprNamed {
7583 name,
7584 arg,
7585 operator,
7586 } => f.write_fmt(format_args!("{0} {1} {2}", name, operator, arg))write!(f, "{name} {operator} {arg}"),
7587 FunctionArg::Unnamed(unnamed_arg) => f.write_fmt(format_args!("{0}", unnamed_arg))write!(f, "{unnamed_arg}"),
7588 }
7589 }
7590}
7591
7592#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CloseCursor {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CloseCursor::All => ::core::fmt::Formatter::write_str(f, "All"),
CloseCursor::Specific { name: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Specific", "name", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CloseCursor {
#[inline]
fn clone(&self) -> CloseCursor {
match self {
CloseCursor::All => CloseCursor::All,
CloseCursor::Specific { name: __self_0 } =>
CloseCursor::Specific {
name: ::core::clone::Clone::clone(__self_0),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CloseCursor {
#[inline]
fn eq(&self, other: &CloseCursor) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CloseCursor::Specific { name: __self_0 },
CloseCursor::Specific { name: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CloseCursor {
#[inline]
fn partial_cmp(&self, other: &CloseCursor)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CloseCursor {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CloseCursor {
#[inline]
fn cmp(&self, other: &CloseCursor) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CloseCursor::Specific { name: __self_0 },
CloseCursor::Specific { name: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CloseCursor {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CloseCursor::Specific { name: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
7593#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7594#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CloseCursor {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::All => {}
Self::Specific { name } => {
sqlparser::ast::Visit::visit(name, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CloseCursor {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::All => {}
Self::Specific { name } => {
sqlparser::ast::VisitMut::visit(name, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7595pub enum CloseCursor {
7597 All,
7599 Specific {
7601 name: Ident,
7603 },
7604}
7605
7606impl fmt::Display for CloseCursor {
7607 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7608 match self {
7609 CloseCursor::All => f.write_fmt(format_args!("ALL"))write!(f, "ALL"),
7610 CloseCursor::Specific { name } => f.write_fmt(format_args!("{0}", name))write!(f, "{name}"),
7611 }
7612 }
7613}
7614
7615#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DropDomain {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "DropDomain",
"if_exists", &self.if_exists, "name", &self.name, "drop_behavior",
&&self.drop_behavior)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DropDomain {
#[inline]
fn clone(&self) -> DropDomain {
DropDomain {
if_exists: ::core::clone::Clone::clone(&self.if_exists),
name: ::core::clone::Clone::clone(&self.name),
drop_behavior: ::core::clone::Clone::clone(&self.drop_behavior),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DropDomain {
#[inline]
fn eq(&self, other: &DropDomain) -> bool {
self.if_exists == other.if_exists && self.name == other.name &&
self.drop_behavior == other.drop_behavior
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DropDomain {
#[inline]
fn partial_cmp(&self, other: &DropDomain)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DropDomain {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Option<DropBehavior>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DropDomain {
#[inline]
fn cmp(&self, other: &DropDomain) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.if_exists, &other.if_exists) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.drop_behavior,
&other.drop_behavior),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DropDomain {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.if_exists, state);
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.drop_behavior, state)
}
}Hash)]
7617#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7618#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DropDomain {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.if_exists, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.drop_behavior, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DropDomain {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.if_exists,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.drop_behavior,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7619pub struct DropDomain {
7620 pub if_exists: bool,
7622 pub name: ObjectName,
7624 pub drop_behavior: Option<DropBehavior>,
7626}
7627
7628#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TypedString {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "TypedString",
"data_type", &self.data_type, "value", &self.value,
"uses_odbc_syntax", &&self.uses_odbc_syntax)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TypedString {
#[inline]
fn clone(&self) -> TypedString {
TypedString {
data_type: ::core::clone::Clone::clone(&self.data_type),
value: ::core::clone::Clone::clone(&self.value),
uses_odbc_syntax: ::core::clone::Clone::clone(&self.uses_odbc_syntax),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TypedString {
#[inline]
fn eq(&self, other: &TypedString) -> bool {
self.uses_odbc_syntax == other.uses_odbc_syntax &&
self.data_type == other.data_type && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TypedString {
#[inline]
fn partial_cmp(&self, other: &TypedString)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TypedString {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<DataType>;
let _: ::core::cmp::AssertParamIsEq<ValueWithSpan>;
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TypedString {
#[inline]
fn cmp(&self, other: &TypedString) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.data_type, &other.data_type) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.value, &other.value) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.uses_odbc_syntax,
&other.uses_odbc_syntax),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TypedString {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.data_type, state);
::core::hash::Hash::hash(&self.value, state);
::core::hash::Hash::hash(&self.uses_odbc_syntax, state)
}
}Hash)]
7632#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7633#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TypedString {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.data_type, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
sqlparser::ast::Visit::visit(&self.uses_odbc_syntax,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TypedString {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.data_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.uses_odbc_syntax,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7634pub struct TypedString {
7635 pub data_type: DataType,
7637 pub value: ValueWithSpan,
7640 pub uses_odbc_syntax: bool,
7651}
7652
7653impl fmt::Display for TypedString {
7654 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7655 let data_type = &self.data_type;
7656 let value = &self.value;
7657 match self.uses_odbc_syntax {
7658 false => {
7659 f.write_fmt(format_args!("{0}", data_type))write!(f, "{data_type}")?;
7660 f.write_fmt(format_args!(" {0}", value))write!(f, " {value}")
7661 }
7662 true => {
7663 let prefix = match data_type {
7664 DataType::Date => "d",
7665 DataType::Time(..) => "t",
7666 DataType::Timestamp(..) => "ts",
7667 _ => "?",
7668 };
7669 f.write_fmt(format_args!("{{{0} {1}}}", prefix, value))write!(f, "{{{prefix} {value}}}")
7670 }
7671 }
7672 }
7673}
7674
7675#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Function {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["name", "uses_odbc_syntax", "parameters", "args", "filter",
"null_treatment", "over", "within_group"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.name, &self.uses_odbc_syntax, &self.parameters,
&self.args, &self.filter, &self.null_treatment, &self.over,
&&self.within_group];
::core::fmt::Formatter::debug_struct_fields_finish(f, "Function",
names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Function {
#[inline]
fn clone(&self) -> Function {
Function {
name: ::core::clone::Clone::clone(&self.name),
uses_odbc_syntax: ::core::clone::Clone::clone(&self.uses_odbc_syntax),
parameters: ::core::clone::Clone::clone(&self.parameters),
args: ::core::clone::Clone::clone(&self.args),
filter: ::core::clone::Clone::clone(&self.filter),
null_treatment: ::core::clone::Clone::clone(&self.null_treatment),
over: ::core::clone::Clone::clone(&self.over),
within_group: ::core::clone::Clone::clone(&self.within_group),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Function {
#[inline]
fn eq(&self, other: &Function) -> bool {
self.uses_odbc_syntax == other.uses_odbc_syntax &&
self.name == other.name &&
self.parameters == other.parameters &&
self.args == other.args && self.filter == other.filter &&
self.null_treatment == other.null_treatment &&
self.over == other.over &&
self.within_group == other.within_group
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Function {
#[inline]
fn partial_cmp(&self, other: &Function)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Function {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<FunctionArguments>;
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<Option<NullTreatment>>;
let _: ::core::cmp::AssertParamIsEq<Option<WindowType>>;
let _: ::core::cmp::AssertParamIsEq<Vec<OrderByExpr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Function {
#[inline]
fn cmp(&self, other: &Function) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.uses_odbc_syntax,
&other.uses_odbc_syntax) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.parameters,
&other.parameters) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.args, &other.args) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.filter, &other.filter) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.null_treatment,
&other.null_treatment) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.over, &other.over) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.within_group,
&other.within_group),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Function {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.uses_odbc_syntax, state);
::core::hash::Hash::hash(&self.parameters, state);
::core::hash::Hash::hash(&self.args, state);
::core::hash::Hash::hash(&self.filter, state);
::core::hash::Hash::hash(&self.null_treatment, state);
::core::hash::Hash::hash(&self.over, state);
::core::hash::Hash::hash(&self.within_group, state)
}
}Hash)]
7677#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7678#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Function {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.uses_odbc_syntax,
visitor)?;
sqlparser::ast::Visit::visit(&self.parameters, visitor)?;
sqlparser::ast::Visit::visit(&self.args, visitor)?;
sqlparser::ast::Visit::visit(&self.filter, visitor)?;
sqlparser::ast::Visit::visit(&self.null_treatment,
visitor)?;
sqlparser::ast::Visit::visit(&self.over, visitor)?;
sqlparser::ast::Visit::visit(&self.within_group, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Function {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.uses_odbc_syntax,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.parameters,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.args, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.filter, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.null_treatment,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.over, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.within_group,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7679pub struct Function {
7680 pub name: ObjectName,
7682 pub uses_odbc_syntax: bool,
7691 pub parameters: FunctionArguments,
7701 pub args: FunctionArguments,
7704 pub filter: Option<Box<Expr>>,
7706 pub null_treatment: Option<NullTreatment>,
7715 pub over: Option<WindowType>,
7717 pub within_group: Vec<OrderByExpr>,
7725}
7726
7727impl fmt::Display for Function {
7728 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7729 if self.uses_odbc_syntax {
7730 f.write_fmt(format_args!("{{fn "))write!(f, "{{fn ")?;
7731 }
7732
7733 f.write_fmt(format_args!("{0}{1}{2}", self.name, self.parameters, self.args))write!(f, "{}{}{}", self.name, self.parameters, self.args)?;
7734
7735 if !self.within_group.is_empty() {
7736 f.write_fmt(format_args!(" WITHIN GROUP (ORDER BY {0})",
display_comma_separated(&self.within_group)))write!(
7737 f,
7738 " WITHIN GROUP (ORDER BY {})",
7739 display_comma_separated(&self.within_group)
7740 )?;
7741 }
7742
7743 if let Some(filter_cond) = &self.filter {
7744 f.write_fmt(format_args!(" FILTER (WHERE {0})", filter_cond))write!(f, " FILTER (WHERE {filter_cond})")?;
7745 }
7746
7747 if let Some(null_treatment) = &self.null_treatment {
7748 f.write_fmt(format_args!(" {0}", null_treatment))write!(f, " {null_treatment}")?;
7749 }
7750
7751 if let Some(o) = &self.over {
7752 f.write_str(" OVER ")?;
7753 o.fmt(f)?;
7754 }
7755
7756 if self.uses_odbc_syntax {
7757 f.write_fmt(format_args!("}}"))write!(f, "}}")?;
7758 }
7759
7760 Ok(())
7761 }
7762}
7763
7764#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionArguments {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FunctionArguments::None =>
::core::fmt::Formatter::write_str(f, "None"),
FunctionArguments::Subquery(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Subquery", &__self_0),
FunctionArguments::List(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "List",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionArguments {
#[inline]
fn clone(&self) -> FunctionArguments {
match self {
FunctionArguments::None => FunctionArguments::None,
FunctionArguments::Subquery(__self_0) =>
FunctionArguments::Subquery(::core::clone::Clone::clone(__self_0)),
FunctionArguments::List(__self_0) =>
FunctionArguments::List(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionArguments {
#[inline]
fn eq(&self, other: &FunctionArguments) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FunctionArguments::Subquery(__self_0),
FunctionArguments::Subquery(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArguments::List(__self_0),
FunctionArguments::List(__arg1_0)) => __self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionArguments {
#[inline]
fn partial_cmp(&self, other: &FunctionArguments)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionArguments {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<FunctionArgumentList>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionArguments {
#[inline]
fn cmp(&self, other: &FunctionArguments) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FunctionArguments::Subquery(__self_0),
FunctionArguments::Subquery(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArguments::List(__self_0),
FunctionArguments::List(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionArguments {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FunctionArguments::Subquery(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArguments::List(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
7766#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7767#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionArguments {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::None => {}
Self::Subquery(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::List(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionArguments {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::None => {}
Self::Subquery(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::List(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7768pub enum FunctionArguments {
7769 None,
7772 Subquery(Box<Query>),
7775 List(FunctionArgumentList),
7778}
7779
7780impl fmt::Display for FunctionArguments {
7781 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7782 match self {
7783 FunctionArguments::None => Ok(()),
7784 FunctionArguments::Subquery(query) => f.write_fmt(format_args!("({0})", query))write!(f, "({query})"),
7785 FunctionArguments::List(args) => f.write_fmt(format_args!("({0})", args))write!(f, "({args})"),
7786 }
7787 }
7788}
7789
7790#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionArgumentList {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"FunctionArgumentList", "duplicate_treatment",
&self.duplicate_treatment, "args", &self.args, "clauses",
&&self.clauses)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionArgumentList {
#[inline]
fn clone(&self) -> FunctionArgumentList {
FunctionArgumentList {
duplicate_treatment: ::core::clone::Clone::clone(&self.duplicate_treatment),
args: ::core::clone::Clone::clone(&self.args),
clauses: ::core::clone::Clone::clone(&self.clauses),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionArgumentList {
#[inline]
fn eq(&self, other: &FunctionArgumentList) -> bool {
self.duplicate_treatment == other.duplicate_treatment &&
self.args == other.args && self.clauses == other.clauses
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionArgumentList {
#[inline]
fn partial_cmp(&self, other: &FunctionArgumentList)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionArgumentList {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<DuplicateTreatment>>;
let _: ::core::cmp::AssertParamIsEq<Vec<FunctionArg>>;
let _: ::core::cmp::AssertParamIsEq<Vec<FunctionArgumentClause>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionArgumentList {
#[inline]
fn cmp(&self, other: &FunctionArgumentList) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.duplicate_treatment,
&other.duplicate_treatment) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.args, &other.args) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.clauses, &other.clauses),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionArgumentList {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.duplicate_treatment, state);
::core::hash::Hash::hash(&self.args, state);
::core::hash::Hash::hash(&self.clauses, state)
}
}Hash)]
7792#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7793#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionArgumentList {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.duplicate_treatment,
visitor)?;
sqlparser::ast::Visit::visit(&self.args, visitor)?;
sqlparser::ast::Visit::visit(&self.clauses, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionArgumentList {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.duplicate_treatment,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.args, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.clauses,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7794pub struct FunctionArgumentList {
7795 pub duplicate_treatment: Option<DuplicateTreatment>,
7797 pub args: Vec<FunctionArg>,
7799 pub clauses: Vec<FunctionArgumentClause>,
7801}
7802
7803impl fmt::Display for FunctionArgumentList {
7804 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7805 if let Some(duplicate_treatment) = self.duplicate_treatment {
7806 f.write_fmt(format_args!("{0} ", duplicate_treatment))write!(f, "{duplicate_treatment} ")?;
7807 }
7808 f.write_fmt(format_args!("{0}", display_comma_separated(&self.args)))write!(f, "{}", display_comma_separated(&self.args))?;
7809 if !self.clauses.is_empty() {
7810 if !self.args.is_empty() {
7811 f.write_fmt(format_args!(" "))write!(f, " ")?;
7812 }
7813 f.write_fmt(format_args!("{0}", display_separated(&self.clauses, " ")))write!(f, "{}", display_separated(&self.clauses, " "))?;
7814 }
7815 Ok(())
7816 }
7817}
7818
7819#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionArgumentClause {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FunctionArgumentClause::IgnoreOrRespectNulls(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IgnoreOrRespectNulls", &__self_0),
FunctionArgumentClause::OrderBy(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"OrderBy", &__self_0),
FunctionArgumentClause::Limit(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Limit",
&__self_0),
FunctionArgumentClause::OnOverflow(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"OnOverflow", &__self_0),
FunctionArgumentClause::Having(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Having",
&__self_0),
FunctionArgumentClause::Separator(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Separator", &__self_0),
FunctionArgumentClause::JsonNullClause(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"JsonNullClause", &__self_0),
FunctionArgumentClause::JsonReturningClause(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"JsonReturningClause", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionArgumentClause {
#[inline]
fn clone(&self) -> FunctionArgumentClause {
match self {
FunctionArgumentClause::IgnoreOrRespectNulls(__self_0) =>
FunctionArgumentClause::IgnoreOrRespectNulls(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::OrderBy(__self_0) =>
FunctionArgumentClause::OrderBy(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::Limit(__self_0) =>
FunctionArgumentClause::Limit(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::OnOverflow(__self_0) =>
FunctionArgumentClause::OnOverflow(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::Having(__self_0) =>
FunctionArgumentClause::Having(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::Separator(__self_0) =>
FunctionArgumentClause::Separator(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::JsonNullClause(__self_0) =>
FunctionArgumentClause::JsonNullClause(::core::clone::Clone::clone(__self_0)),
FunctionArgumentClause::JsonReturningClause(__self_0) =>
FunctionArgumentClause::JsonReturningClause(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionArgumentClause {
#[inline]
fn eq(&self, other: &FunctionArgumentClause) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FunctionArgumentClause::IgnoreOrRespectNulls(__self_0),
FunctionArgumentClause::IgnoreOrRespectNulls(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::OrderBy(__self_0),
FunctionArgumentClause::OrderBy(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::Limit(__self_0),
FunctionArgumentClause::Limit(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::OnOverflow(__self_0),
FunctionArgumentClause::OnOverflow(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::Having(__self_0),
FunctionArgumentClause::Having(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::Separator(__self_0),
FunctionArgumentClause::Separator(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::JsonNullClause(__self_0),
FunctionArgumentClause::JsonNullClause(__arg1_0)) =>
__self_0 == __arg1_0,
(FunctionArgumentClause::JsonReturningClause(__self_0),
FunctionArgumentClause::JsonReturningClause(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionArgumentClause {
#[inline]
fn partial_cmp(&self, other: &FunctionArgumentClause)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionArgumentClause {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<NullTreatment>;
let _: ::core::cmp::AssertParamIsEq<Vec<OrderByExpr>>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<ListAggOnOverflow>;
let _: ::core::cmp::AssertParamIsEq<HavingBound>;
let _: ::core::cmp::AssertParamIsEq<Value>;
let _: ::core::cmp::AssertParamIsEq<JsonNullClause>;
let _: ::core::cmp::AssertParamIsEq<JsonReturningClause>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionArgumentClause {
#[inline]
fn cmp(&self, other: &FunctionArgumentClause) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FunctionArgumentClause::IgnoreOrRespectNulls(__self_0),
FunctionArgumentClause::IgnoreOrRespectNulls(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::OrderBy(__self_0),
FunctionArgumentClause::OrderBy(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::Limit(__self_0),
FunctionArgumentClause::Limit(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::OnOverflow(__self_0),
FunctionArgumentClause::OnOverflow(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::Having(__self_0),
FunctionArgumentClause::Having(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::Separator(__self_0),
FunctionArgumentClause::Separator(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::JsonNullClause(__self_0),
FunctionArgumentClause::JsonNullClause(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(FunctionArgumentClause::JsonReturningClause(__self_0),
FunctionArgumentClause::JsonReturningClause(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionArgumentClause {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FunctionArgumentClause::IgnoreOrRespectNulls(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::OrderBy(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::Limit(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::OnOverflow(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::Having(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::Separator(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::JsonNullClause(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
FunctionArgumentClause::JsonReturningClause(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
7820#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7821#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionArgumentClause {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IgnoreOrRespectNulls(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::OrderBy(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Limit(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::OnOverflow(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Having(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Separator(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::JsonNullClause(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::JsonReturningClause(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionArgumentClause {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IgnoreOrRespectNulls(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::OrderBy(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Limit(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::OnOverflow(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Having(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Separator(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::JsonNullClause(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::JsonReturningClause(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7822pub enum FunctionArgumentClause {
7824 IgnoreOrRespectNulls(NullTreatment),
7833 OrderBy(Vec<OrderByExpr>),
7837 Limit(Expr),
7839 OnOverflow(ListAggOnOverflow),
7843 Having(HavingBound),
7852 Separator(Value),
7856 JsonNullClause(JsonNullClause),
7862 JsonReturningClause(JsonReturningClause),
7866}
7867
7868impl fmt::Display for FunctionArgumentClause {
7869 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7870 match self {
7871 FunctionArgumentClause::IgnoreOrRespectNulls(null_treatment) => {
7872 f.write_fmt(format_args!("{0}", null_treatment))write!(f, "{null_treatment}")
7873 }
7874 FunctionArgumentClause::OrderBy(order_by) => {
7875 f.write_fmt(format_args!("ORDER BY {0}", display_comma_separated(order_by)))write!(f, "ORDER BY {}", display_comma_separated(order_by))
7876 }
7877 FunctionArgumentClause::Limit(limit) => f.write_fmt(format_args!("LIMIT {0}", limit))write!(f, "LIMIT {limit}"),
7878 FunctionArgumentClause::OnOverflow(on_overflow) => f.write_fmt(format_args!("{0}", on_overflow))write!(f, "{on_overflow}"),
7879 FunctionArgumentClause::Having(bound) => f.write_fmt(format_args!("{0}", bound))write!(f, "{bound}"),
7880 FunctionArgumentClause::Separator(sep) => f.write_fmt(format_args!("SEPARATOR {0}", sep))write!(f, "SEPARATOR {sep}"),
7881 FunctionArgumentClause::JsonNullClause(null_clause) => f.write_fmt(format_args!("{0}", null_clause))write!(f, "{null_clause}"),
7882 FunctionArgumentClause::JsonReturningClause(returning_clause) => {
7883 f.write_fmt(format_args!("{0}", returning_clause))write!(f, "{returning_clause}")
7884 }
7885 }
7886 }
7887}
7888
7889#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Method {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "Method",
"expr", &self.expr, "method_chain", &&self.method_chain)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Method {
#[inline]
fn clone(&self) -> Method {
Method {
expr: ::core::clone::Clone::clone(&self.expr),
method_chain: ::core::clone::Clone::clone(&self.method_chain),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Method {
#[inline]
fn eq(&self, other: &Method) -> bool {
self.expr == other.expr && self.method_chain == other.method_chain
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Method {
#[inline]
fn partial_cmp(&self, other: &Method)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Method {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Function>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Method {
#[inline]
fn cmp(&self, other: &Method) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.expr, &other.expr) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.method_chain,
&other.method_chain),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Method {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.expr, state);
::core::hash::Hash::hash(&self.method_chain, state)
}
}Hash)]
7891#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7892#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Method {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.expr, visitor)?;
sqlparser::ast::Visit::visit(&self.method_chain, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Method {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.expr, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.method_chain,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7893pub struct Method {
7894 pub expr: Box<Expr>,
7896 pub method_chain: Vec<Function>,
7899}
7900
7901impl fmt::Display for Method {
7902 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
7903 f.write_fmt(format_args!("{0}.{1}", self.expr,
display_separated(&self.method_chain, ".")))write!(
7904 f,
7905 "{}.{}",
7906 self.expr,
7907 display_separated(&self.method_chain, ".")
7908 )
7909 }
7910}
7911
7912#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DuplicateTreatment {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
DuplicateTreatment::Distinct => "Distinct",
DuplicateTreatment::All => "All",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for DuplicateTreatment { }Copy, #[automatically_derived]
impl ::core::clone::Clone for DuplicateTreatment {
#[inline]
fn clone(&self) -> DuplicateTreatment { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DuplicateTreatment {
#[inline]
fn eq(&self, other: &DuplicateTreatment) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DuplicateTreatment {
#[inline]
fn partial_cmp(&self, other: &DuplicateTreatment)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DuplicateTreatment {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DuplicateTreatment {
#[inline]
fn cmp(&self, other: &DuplicateTreatment) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DuplicateTreatment {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
7913#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7914#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DuplicateTreatment {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Distinct => {} Self::All => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DuplicateTreatment {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Distinct => {} Self::All => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7915pub enum DuplicateTreatment {
7917 Distinct,
7919 All,
7921}
7922
7923impl fmt::Display for DuplicateTreatment {
7924 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
7925 match self {
7926 DuplicateTreatment::Distinct => f.write_fmt(format_args!("DISTINCT"))write!(f, "DISTINCT"),
7927 DuplicateTreatment::All => f.write_fmt(format_args!("ALL"))write!(f, "ALL"),
7928 }
7929 }
7930}
7931
7932#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AnalyzeFormatKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
AnalyzeFormatKind::Keyword(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Keyword", &__self_0),
AnalyzeFormatKind::Assignment(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Assignment", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for AnalyzeFormatKind { }Copy, #[automatically_derived]
impl ::core::clone::Clone for AnalyzeFormatKind {
#[inline]
fn clone(&self) -> AnalyzeFormatKind {
let _: ::core::clone::AssertParamIsClone<AnalyzeFormat>;
*self
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AnalyzeFormatKind {
#[inline]
fn eq(&self, other: &AnalyzeFormatKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(AnalyzeFormatKind::Keyword(__self_0),
AnalyzeFormatKind::Keyword(__arg1_0)) =>
__self_0 == __arg1_0,
(AnalyzeFormatKind::Assignment(__self_0),
AnalyzeFormatKind::Assignment(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AnalyzeFormatKind {
#[inline]
fn partial_cmp(&self, other: &AnalyzeFormatKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AnalyzeFormatKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<AnalyzeFormat>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AnalyzeFormatKind {
#[inline]
fn cmp(&self, other: &AnalyzeFormatKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(AnalyzeFormatKind::Keyword(__self_0),
AnalyzeFormatKind::Keyword(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(AnalyzeFormatKind::Assignment(__self_0),
AnalyzeFormatKind::Assignment(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AnalyzeFormatKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
AnalyzeFormatKind::Keyword(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
AnalyzeFormatKind::Assignment(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
7933#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7934#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AnalyzeFormatKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Keyword(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Assignment(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AnalyzeFormatKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Keyword(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Assignment(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7935pub enum AnalyzeFormatKind {
7937 Keyword(AnalyzeFormat),
7939 Assignment(AnalyzeFormat),
7941}
7942
7943impl fmt::Display for AnalyzeFormatKind {
7944 fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
7945 match self {
7946 AnalyzeFormatKind::Keyword(format) => f.write_fmt(format_args!("FORMAT {0}", format))write!(f, "FORMAT {format}"),
7947 AnalyzeFormatKind::Assignment(format) => f.write_fmt(format_args!("FORMAT={0}", format))write!(f, "FORMAT={format}"),
7948 }
7949 }
7950}
7951
7952#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AnalyzeFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
AnalyzeFormat::TEXT => "TEXT",
AnalyzeFormat::GRAPHVIZ => "GRAPHVIZ",
AnalyzeFormat::JSON => "JSON",
AnalyzeFormat::TRADITIONAL => "TRADITIONAL",
AnalyzeFormat::TREE => "TREE",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for AnalyzeFormat { }Copy, #[automatically_derived]
impl ::core::clone::Clone for AnalyzeFormat {
#[inline]
fn clone(&self) -> AnalyzeFormat { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AnalyzeFormat {
#[inline]
fn eq(&self, other: &AnalyzeFormat) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AnalyzeFormat {
#[inline]
fn partial_cmp(&self, other: &AnalyzeFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AnalyzeFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AnalyzeFormat {
#[inline]
fn cmp(&self, other: &AnalyzeFormat) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AnalyzeFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
7953#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7954#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AnalyzeFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::TEXT => {}
Self::GRAPHVIZ => {}
Self::JSON => {}
Self::TRADITIONAL => {}
Self::TREE => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AnalyzeFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::TEXT => {}
Self::GRAPHVIZ => {}
Self::JSON => {}
Self::TRADITIONAL => {}
Self::TREE => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7955pub enum AnalyzeFormat {
7957 TEXT,
7959 GRAPHVIZ,
7961 JSON,
7963 TRADITIONAL,
7965 TREE,
7967}
7968
7969impl fmt::Display for AnalyzeFormat {
7970 fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
7971 f.write_str(match self {
7972 AnalyzeFormat::TEXT => "TEXT",
7973 AnalyzeFormat::GRAPHVIZ => "GRAPHVIZ",
7974 AnalyzeFormat::JSON => "JSON",
7975 AnalyzeFormat::TRADITIONAL => "TRADITIONAL",
7976 AnalyzeFormat::TREE => "TREE",
7977 })
7978 }
7979}
7980
7981#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FileFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FileFormat::TEXTFILE => "TEXTFILE",
FileFormat::SEQUENCEFILE => "SEQUENCEFILE",
FileFormat::ORC => "ORC",
FileFormat::PARQUET => "PARQUET",
FileFormat::AVRO => "AVRO",
FileFormat::RCFILE => "RCFILE",
FileFormat::JSONFILE => "JSONFILE",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for FileFormat { }Copy, #[automatically_derived]
impl ::core::clone::Clone for FileFormat {
#[inline]
fn clone(&self) -> FileFormat { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FileFormat {
#[inline]
fn eq(&self, other: &FileFormat) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FileFormat {
#[inline]
fn partial_cmp(&self, other: &FileFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FileFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FileFormat {
#[inline]
fn cmp(&self, other: &FileFormat) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FileFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
7983#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
7984#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FileFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::TEXTFILE => {}
Self::SEQUENCEFILE => {}
Self::ORC => {}
Self::PARQUET => {}
Self::AVRO => {}
Self::RCFILE => {}
Self::JSONFILE => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FileFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::TEXTFILE => {}
Self::SEQUENCEFILE => {}
Self::ORC => {}
Self::PARQUET => {}
Self::AVRO => {}
Self::RCFILE => {}
Self::JSONFILE => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
7985pub enum FileFormat {
7986 TEXTFILE,
7988 SEQUENCEFILE,
7990 ORC,
7992 PARQUET,
7994 AVRO,
7996 RCFILE,
7998 JSONFILE,
8000}
8001
8002impl fmt::Display for FileFormat {
8003 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8004 use self::FileFormat::*;
8005 f.write_str(match self {
8006 TEXTFILE => "TEXTFILE",
8007 SEQUENCEFILE => "SEQUENCEFILE",
8008 ORC => "ORC",
8009 PARQUET => "PARQUET",
8010 AVRO => "AVRO",
8011 RCFILE => "RCFILE",
8012 JSONFILE => "JSONFILE",
8013 })
8014 }
8015}
8016
8017#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ListAggOnOverflow {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ListAggOnOverflow::Error =>
::core::fmt::Formatter::write_str(f, "Error"),
ListAggOnOverflow::Truncate {
filler: __self_0, with_count: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"Truncate", "filler", __self_0, "with_count", &__self_1),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ListAggOnOverflow {
#[inline]
fn clone(&self) -> ListAggOnOverflow {
match self {
ListAggOnOverflow::Error => ListAggOnOverflow::Error,
ListAggOnOverflow::Truncate {
filler: __self_0, with_count: __self_1 } =>
ListAggOnOverflow::Truncate {
filler: ::core::clone::Clone::clone(__self_0),
with_count: ::core::clone::Clone::clone(__self_1),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ListAggOnOverflow {
#[inline]
fn eq(&self, other: &ListAggOnOverflow) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(ListAggOnOverflow::Truncate {
filler: __self_0, with_count: __self_1 },
ListAggOnOverflow::Truncate {
filler: __arg1_0, with_count: __arg1_1 }) =>
__self_1 == __arg1_1 && __self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ListAggOnOverflow {
#[inline]
fn partial_cmp(&self, other: &ListAggOnOverflow)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ListAggOnOverflow {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<Box<Expr>>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ListAggOnOverflow {
#[inline]
fn cmp(&self, other: &ListAggOnOverflow) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(ListAggOnOverflow::Truncate {
filler: __self_0, with_count: __self_1 },
ListAggOnOverflow::Truncate {
filler: __arg1_0, with_count: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ListAggOnOverflow {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
ListAggOnOverflow::Truncate {
filler: __self_0, with_count: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
_ => {}
}
}
}Hash)]
8019#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8020#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ListAggOnOverflow {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Error => {}
Self::Truncate { filler, with_count } => {
sqlparser::ast::Visit::visit(filler, visitor)?;
sqlparser::ast::Visit::visit(with_count, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ListAggOnOverflow {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Error => {}
Self::Truncate { filler, with_count } => {
sqlparser::ast::VisitMut::visit(filler, visitor)?;
sqlparser::ast::VisitMut::visit(with_count, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8021pub enum ListAggOnOverflow {
8022 Error,
8024
8025 Truncate {
8027 filler: Option<Box<Expr>>,
8029 with_count: bool,
8031 },
8032}
8033
8034impl fmt::Display for ListAggOnOverflow {
8035 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8036 f.write_fmt(format_args!("ON OVERFLOW"))write!(f, "ON OVERFLOW")?;
8037 match self {
8038 ListAggOnOverflow::Error => f.write_fmt(format_args!(" ERROR"))write!(f, " ERROR"),
8039 ListAggOnOverflow::Truncate { filler, with_count } => {
8040 f.write_fmt(format_args!(" TRUNCATE"))write!(f, " TRUNCATE")?;
8041 if let Some(filler) = filler {
8042 f.write_fmt(format_args!(" {0}", filler))write!(f, " {filler}")?;
8043 }
8044 if *with_count {
8045 f.write_fmt(format_args!(" WITH"))write!(f, " WITH")?;
8046 } else {
8047 f.write_fmt(format_args!(" WITHOUT"))write!(f, " WITHOUT")?;
8048 }
8049 f.write_fmt(format_args!(" COUNT"))write!(f, " COUNT")
8050 }
8051 }
8052 }
8053}
8054
8055#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HavingBound {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_tuple_field2_finish(f, "HavingBound",
&self.0, &&self.1)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HavingBound {
#[inline]
fn clone(&self) -> HavingBound {
HavingBound(::core::clone::Clone::clone(&self.0),
::core::clone::Clone::clone(&self.1))
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HavingBound {
#[inline]
fn eq(&self, other: &HavingBound) -> bool {
self.0 == other.0 && self.1 == other.1
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HavingBound {
#[inline]
fn partial_cmp(&self, other: &HavingBound)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HavingBound {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<HavingBoundKind>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HavingBound {
#[inline]
fn cmp(&self, other: &HavingBound) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.0, &other.0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.1, &other.1),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HavingBound {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.0, state);
::core::hash::Hash::hash(&self.1, state)
}
}Hash)]
8057#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8058#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HavingBound {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.0, visitor)?;
sqlparser::ast::Visit::visit(&self.1, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HavingBound {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.0, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.1, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8059pub struct HavingBound(pub HavingBoundKind, pub Expr);
8060
8061impl fmt::Display for HavingBound {
8062 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8063 f.write_fmt(format_args!("HAVING {0} {1}", self.0, self.1))write!(f, "HAVING {} {}", self.0, self.1)
8064 }
8065}
8066
8067#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HavingBoundKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
HavingBoundKind::Min => "Min",
HavingBoundKind::Max => "Max",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for HavingBoundKind { }Copy, #[automatically_derived]
impl ::core::clone::Clone for HavingBoundKind {
#[inline]
fn clone(&self) -> HavingBoundKind { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HavingBoundKind {
#[inline]
fn eq(&self, other: &HavingBoundKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HavingBoundKind {
#[inline]
fn partial_cmp(&self, other: &HavingBoundKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HavingBoundKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HavingBoundKind {
#[inline]
fn cmp(&self, other: &HavingBoundKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HavingBoundKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8068#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8069#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HavingBoundKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Min => {} Self::Max => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HavingBoundKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Min => {} Self::Max => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8070pub enum HavingBoundKind {
8072 Min,
8074 Max,
8076}
8077
8078impl fmt::Display for HavingBoundKind {
8079 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8080 match self {
8081 HavingBoundKind::Min => f.write_fmt(format_args!("MIN"))write!(f, "MIN"),
8082 HavingBoundKind::Max => f.write_fmt(format_args!("MAX"))write!(f, "MAX"),
8083 }
8084 }
8085}
8086
8087#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ObjectType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ObjectType::Table => "Table",
ObjectType::View => "View",
ObjectType::MaterializedView => "MaterializedView",
ObjectType::Index => "Index",
ObjectType::Schema => "Schema",
ObjectType::Database => "Database",
ObjectType::Role => "Role",
ObjectType::Sequence => "Sequence",
ObjectType::Stage => "Stage",
ObjectType::Type => "Type",
ObjectType::User => "User",
ObjectType::Stream => "Stream",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for ObjectType { }Copy, #[automatically_derived]
impl ::core::clone::Clone for ObjectType {
#[inline]
fn clone(&self) -> ObjectType { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ObjectType {
#[inline]
fn eq(&self, other: &ObjectType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ObjectType {
#[inline]
fn partial_cmp(&self, other: &ObjectType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ObjectType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ObjectType {
#[inline]
fn cmp(&self, other: &ObjectType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ObjectType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8088#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8089#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ObjectType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Table => {}
Self::View => {}
Self::MaterializedView => {}
Self::Index => {}
Self::Schema => {}
Self::Database => {}
Self::Role => {}
Self::Sequence => {}
Self::Stage => {}
Self::Type => {}
Self::User => {}
Self::Stream => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ObjectType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Table => {}
Self::View => {}
Self::MaterializedView => {}
Self::Index => {}
Self::Schema => {}
Self::Database => {}
Self::Role => {}
Self::Sequence => {}
Self::Stage => {}
Self::Type => {}
Self::User => {}
Self::Stream => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8090pub enum ObjectType {
8092 Table,
8094 View,
8096 MaterializedView,
8098 Index,
8100 Schema,
8102 Database,
8104 Role,
8106 Sequence,
8108 Stage,
8110 Type,
8112 User,
8114 Stream,
8116}
8117
8118impl fmt::Display for ObjectType {
8119 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8120 f.write_str(match self {
8121 ObjectType::Table => "TABLE",
8122 ObjectType::View => "VIEW",
8123 ObjectType::MaterializedView => "MATERIALIZED VIEW",
8124 ObjectType::Index => "INDEX",
8125 ObjectType::Schema => "SCHEMA",
8126 ObjectType::Database => "DATABASE",
8127 ObjectType::Role => "ROLE",
8128 ObjectType::Sequence => "SEQUENCE",
8129 ObjectType::Stage => "STAGE",
8130 ObjectType::Type => "TYPE",
8131 ObjectType::User => "USER",
8132 ObjectType::Stream => "STREAM",
8133 })
8134 }
8135}
8136
8137#[derive(#[automatically_derived]
impl ::core::fmt::Debug for KillType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
KillType::Connection => "Connection",
KillType::Query => "Query",
KillType::Mutation => "Mutation",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for KillType { }Copy, #[automatically_derived]
impl ::core::clone::Clone for KillType {
#[inline]
fn clone(&self) -> KillType { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for KillType {
#[inline]
fn eq(&self, other: &KillType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for KillType {
#[inline]
fn partial_cmp(&self, other: &KillType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for KillType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for KillType {
#[inline]
fn cmp(&self, other: &KillType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for KillType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8138#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8139#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for KillType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Connection => {}
Self::Query => {}
Self::Mutation => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for KillType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Connection => {}
Self::Query => {}
Self::Mutation => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8140pub enum KillType {
8142 Connection,
8144 Query,
8146 Mutation,
8148}
8149
8150impl fmt::Display for KillType {
8151 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8152 f.write_str(match self {
8153 KillType::Connection => "CONNECTION",
8155 KillType::Query => "QUERY",
8156 KillType::Mutation => "MUTATION",
8158 })
8159 }
8160}
8161
8162#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveDistributionStyle {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
HiveDistributionStyle::PARTITIONED { columns: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"PARTITIONED", "columns", &__self_0),
HiveDistributionStyle::SKEWED {
columns: __self_0,
on: __self_1,
stored_as_directories: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"SKEWED", "columns", __self_0, "on", __self_1,
"stored_as_directories", &__self_2),
HiveDistributionStyle::NONE =>
::core::fmt::Formatter::write_str(f, "NONE"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HiveDistributionStyle {
#[inline]
fn clone(&self) -> HiveDistributionStyle {
match self {
HiveDistributionStyle::PARTITIONED { columns: __self_0 } =>
HiveDistributionStyle::PARTITIONED {
columns: ::core::clone::Clone::clone(__self_0),
},
HiveDistributionStyle::SKEWED {
columns: __self_0,
on: __self_1,
stored_as_directories: __self_2 } =>
HiveDistributionStyle::SKEWED {
columns: ::core::clone::Clone::clone(__self_0),
on: ::core::clone::Clone::clone(__self_1),
stored_as_directories: ::core::clone::Clone::clone(__self_2),
},
HiveDistributionStyle::NONE => HiveDistributionStyle::NONE,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveDistributionStyle {
#[inline]
fn eq(&self, other: &HiveDistributionStyle) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(HiveDistributionStyle::PARTITIONED { columns: __self_0 },
HiveDistributionStyle::PARTITIONED { columns: __arg1_0 }) =>
__self_0 == __arg1_0,
(HiveDistributionStyle::SKEWED {
columns: __self_0,
on: __self_1,
stored_as_directories: __self_2 },
HiveDistributionStyle::SKEWED {
columns: __arg1_0,
on: __arg1_1,
stored_as_directories: __arg1_2 }) =>
__self_2 == __arg1_2 && __self_0 == __arg1_0 &&
__self_1 == __arg1_1,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveDistributionStyle {
#[inline]
fn partial_cmp(&self, other: &HiveDistributionStyle)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveDistributionStyle {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<ColumnDef>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ColumnDef>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ColumnDef>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveDistributionStyle {
#[inline]
fn cmp(&self, other: &HiveDistributionStyle) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(HiveDistributionStyle::PARTITIONED { columns: __self_0 },
HiveDistributionStyle::PARTITIONED { columns: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(HiveDistributionStyle::SKEWED {
columns: __self_0,
on: __self_1,
stored_as_directories: __self_2 },
HiveDistributionStyle::SKEWED {
columns: __arg1_0,
on: __arg1_1,
stored_as_directories: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveDistributionStyle {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
HiveDistributionStyle::PARTITIONED { columns: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
HiveDistributionStyle::SKEWED {
columns: __self_0,
on: __self_1,
stored_as_directories: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
_ => {}
}
}
}Hash)]
8163#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8164#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveDistributionStyle {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::PARTITIONED { columns } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
}
Self::SKEWED { columns, on, stored_as_directories } => {
sqlparser::ast::Visit::visit(columns, visitor)?;
sqlparser::ast::Visit::visit(on, visitor)?;
sqlparser::ast::Visit::visit(stored_as_directories,
visitor)?;
}
Self::NONE => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveDistributionStyle {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::PARTITIONED { columns } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
}
Self::SKEWED { columns, on, stored_as_directories } => {
sqlparser::ast::VisitMut::visit(columns, visitor)?;
sqlparser::ast::VisitMut::visit(on, visitor)?;
sqlparser::ast::VisitMut::visit(stored_as_directories,
visitor)?;
}
Self::NONE => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8165pub enum HiveDistributionStyle {
8167 PARTITIONED {
8169 columns: Vec<ColumnDef>,
8171 },
8172 SKEWED {
8174 columns: Vec<ColumnDef>,
8176 on: Vec<ColumnDef>,
8178 stored_as_directories: bool,
8180 },
8181 NONE,
8183}
8184
8185#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveRowFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
HiveRowFormat::SERDE { class: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "SERDE",
"class", &__self_0),
HiveRowFormat::DELIMITED { delimiters: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"DELIMITED", "delimiters", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HiveRowFormat {
#[inline]
fn clone(&self) -> HiveRowFormat {
match self {
HiveRowFormat::SERDE { class: __self_0 } =>
HiveRowFormat::SERDE {
class: ::core::clone::Clone::clone(__self_0),
},
HiveRowFormat::DELIMITED { delimiters: __self_0 } =>
HiveRowFormat::DELIMITED {
delimiters: ::core::clone::Clone::clone(__self_0),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveRowFormat {
#[inline]
fn eq(&self, other: &HiveRowFormat) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(HiveRowFormat::SERDE { class: __self_0 },
HiveRowFormat::SERDE { class: __arg1_0 }) =>
__self_0 == __arg1_0,
(HiveRowFormat::DELIMITED { delimiters: __self_0 },
HiveRowFormat::DELIMITED { delimiters: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveRowFormat {
#[inline]
fn partial_cmp(&self, other: &HiveRowFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveRowFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<Vec<HiveRowDelimiter>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveRowFormat {
#[inline]
fn cmp(&self, other: &HiveRowFormat) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(HiveRowFormat::SERDE { class: __self_0 },
HiveRowFormat::SERDE { class: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(HiveRowFormat::DELIMITED { delimiters: __self_0 },
HiveRowFormat::DELIMITED { delimiters: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveRowFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
HiveRowFormat::SERDE { class: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
HiveRowFormat::DELIMITED { delimiters: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8186#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8187#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveRowFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::SERDE { class } => {
sqlparser::ast::Visit::visit(class, visitor)?;
}
Self::DELIMITED { delimiters } => {
sqlparser::ast::Visit::visit(delimiters, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveRowFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::SERDE { class } => {
sqlparser::ast::VisitMut::visit(class, visitor)?;
}
Self::DELIMITED { delimiters } => {
sqlparser::ast::VisitMut::visit(delimiters, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8188pub enum HiveRowFormat {
8190 SERDE {
8192 class: String,
8194 },
8195 DELIMITED {
8197 delimiters: Vec<HiveRowDelimiter>,
8199 },
8200}
8201
8202#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveLoadDataFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"HiveLoadDataFormat", "serde", &self.serde, "input_format",
&&self.input_format)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HiveLoadDataFormat {
#[inline]
fn clone(&self) -> HiveLoadDataFormat {
HiveLoadDataFormat {
serde: ::core::clone::Clone::clone(&self.serde),
input_format: ::core::clone::Clone::clone(&self.input_format),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveLoadDataFormat {
#[inline]
fn eq(&self, other: &HiveLoadDataFormat) -> bool {
self.serde == other.serde && self.input_format == other.input_format
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveLoadDataFormat {
#[inline]
fn partial_cmp(&self, other: &HiveLoadDataFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveLoadDataFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveLoadDataFormat {
#[inline]
fn cmp(&self, other: &HiveLoadDataFormat) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.serde, &other.serde) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.input_format,
&other.input_format),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveLoadDataFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.serde, state);
::core::hash::Hash::hash(&self.input_format, state)
}
}Hash)]
8203#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8204#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveLoadDataFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.serde, visitor)?;
sqlparser::ast::Visit::visit(&self.input_format, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveLoadDataFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.serde, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.input_format,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8205pub struct HiveLoadDataFormat {
8207 pub serde: Expr,
8209 pub input_format: Expr,
8211}
8212
8213#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveRowDelimiter {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"HiveRowDelimiter", "delimiter", &self.delimiter, "char",
&&self.char)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HiveRowDelimiter {
#[inline]
fn clone(&self) -> HiveRowDelimiter {
HiveRowDelimiter {
delimiter: ::core::clone::Clone::clone(&self.delimiter),
char: ::core::clone::Clone::clone(&self.char),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveRowDelimiter {
#[inline]
fn eq(&self, other: &HiveRowDelimiter) -> bool {
self.delimiter == other.delimiter && self.char == other.char
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveRowDelimiter {
#[inline]
fn partial_cmp(&self, other: &HiveRowDelimiter)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveRowDelimiter {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<HiveDelimiter>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveRowDelimiter {
#[inline]
fn cmp(&self, other: &HiveRowDelimiter) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.delimiter, &other.delimiter) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.char, &other.char),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveRowDelimiter {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.delimiter, state);
::core::hash::Hash::hash(&self.char, state)
}
}Hash)]
8214#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8215#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveRowDelimiter {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.delimiter, visitor)?;
sqlparser::ast::Visit::visit(&self.char, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveRowDelimiter {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.delimiter,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.char, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8216pub struct HiveRowDelimiter {
8218 pub delimiter: HiveDelimiter,
8220 pub char: Ident,
8222}
8223
8224impl fmt::Display for HiveRowDelimiter {
8225 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8226 f.write_fmt(format_args!("{0} ", self.delimiter))write!(f, "{} ", self.delimiter)?;
8227 f.write_fmt(format_args!("{0}", self.char))write!(f, "{}", self.char)
8228 }
8229}
8230
8231#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveDelimiter {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
HiveDelimiter::FieldsTerminatedBy => "FieldsTerminatedBy",
HiveDelimiter::FieldsEscapedBy => "FieldsEscapedBy",
HiveDelimiter::CollectionItemsTerminatedBy =>
"CollectionItemsTerminatedBy",
HiveDelimiter::MapKeysTerminatedBy => "MapKeysTerminatedBy",
HiveDelimiter::LinesTerminatedBy => "LinesTerminatedBy",
HiveDelimiter::NullDefinedAs => "NullDefinedAs",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for HiveDelimiter { }Copy, #[automatically_derived]
impl ::core::clone::Clone for HiveDelimiter {
#[inline]
fn clone(&self) -> HiveDelimiter { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveDelimiter {
#[inline]
fn eq(&self, other: &HiveDelimiter) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveDelimiter {
#[inline]
fn partial_cmp(&self, other: &HiveDelimiter)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveDelimiter {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveDelimiter {
#[inline]
fn cmp(&self, other: &HiveDelimiter) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveDelimiter {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8232#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8233#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveDelimiter {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::FieldsTerminatedBy => {}
Self::FieldsEscapedBy => {}
Self::CollectionItemsTerminatedBy => {}
Self::MapKeysTerminatedBy => {}
Self::LinesTerminatedBy => {}
Self::NullDefinedAs => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveDelimiter {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::FieldsTerminatedBy => {}
Self::FieldsEscapedBy => {}
Self::CollectionItemsTerminatedBy => {}
Self::MapKeysTerminatedBy => {}
Self::LinesTerminatedBy => {}
Self::NullDefinedAs => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8234pub enum HiveDelimiter {
8236 FieldsTerminatedBy,
8238 FieldsEscapedBy,
8240 CollectionItemsTerminatedBy,
8242 MapKeysTerminatedBy,
8244 LinesTerminatedBy,
8246 NullDefinedAs,
8248}
8249
8250impl fmt::Display for HiveDelimiter {
8251 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8252 use HiveDelimiter::*;
8253 f.write_str(match self {
8254 FieldsTerminatedBy => "FIELDS TERMINATED BY",
8255 FieldsEscapedBy => "ESCAPED BY",
8256 CollectionItemsTerminatedBy => "COLLECTION ITEMS TERMINATED BY",
8257 MapKeysTerminatedBy => "MAP KEYS TERMINATED BY",
8258 LinesTerminatedBy => "LINES TERMINATED BY",
8259 NullDefinedAs => "NULL DEFINED AS",
8260 })
8261 }
8262}
8263
8264#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveDescribeFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
HiveDescribeFormat::Extended => "Extended",
HiveDescribeFormat::Formatted => "Formatted",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for HiveDescribeFormat { }Copy, #[automatically_derived]
impl ::core::clone::Clone for HiveDescribeFormat {
#[inline]
fn clone(&self) -> HiveDescribeFormat { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveDescribeFormat {
#[inline]
fn eq(&self, other: &HiveDescribeFormat) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveDescribeFormat {
#[inline]
fn partial_cmp(&self, other: &HiveDescribeFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveDescribeFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveDescribeFormat {
#[inline]
fn cmp(&self, other: &HiveDescribeFormat) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveDescribeFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8265#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8266#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveDescribeFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Extended => {} Self::Formatted => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveDescribeFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Extended => {} Self::Formatted => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8267pub enum HiveDescribeFormat {
8269 Extended,
8271 Formatted,
8273}
8274
8275impl fmt::Display for HiveDescribeFormat {
8276 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8277 use HiveDescribeFormat::*;
8278 f.write_str(match self {
8279 Extended => "EXTENDED",
8280 Formatted => "FORMATTED",
8281 })
8282 }
8283}
8284
8285#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DescribeAlias {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
DescribeAlias::Describe => "Describe",
DescribeAlias::Explain => "Explain",
DescribeAlias::Desc => "Desc",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for DescribeAlias { }Copy, #[automatically_derived]
impl ::core::clone::Clone for DescribeAlias {
#[inline]
fn clone(&self) -> DescribeAlias { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DescribeAlias {
#[inline]
fn eq(&self, other: &DescribeAlias) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DescribeAlias {
#[inline]
fn partial_cmp(&self, other: &DescribeAlias)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DescribeAlias {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DescribeAlias {
#[inline]
fn cmp(&self, other: &DescribeAlias) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DescribeAlias {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8286#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8287#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DescribeAlias {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Describe => {}
Self::Explain => {}
Self::Desc => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DescribeAlias {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Describe => {}
Self::Explain => {}
Self::Desc => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8288pub enum DescribeAlias {
8290 Describe,
8292 Explain,
8294 Desc,
8296}
8297
8298impl fmt::Display for DescribeAlias {
8299 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8300 use DescribeAlias::*;
8301 f.write_str(match self {
8302 Describe => "DESCRIBE",
8303 Explain => "EXPLAIN",
8304 Desc => "DESC",
8305 })
8306 }
8307}
8308
8309#[derive(#[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::fmt::Debug for HiveIOFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
HiveIOFormat::IOF {
input_format: __self_0, output_format: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "IOF",
"input_format", __self_0, "output_format", &__self_1),
HiveIOFormat::FileFormat { format: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"FileFormat", "format", &__self_0),
}
}
}Debug, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::clone::Clone for HiveIOFormat {
#[inline]
fn clone(&self) -> HiveIOFormat {
match self {
HiveIOFormat::IOF {
input_format: __self_0, output_format: __self_1 } =>
HiveIOFormat::IOF {
input_format: ::core::clone::Clone::clone(__self_0),
output_format: ::core::clone::Clone::clone(__self_1),
},
HiveIOFormat::FileFormat { format: __self_0 } =>
HiveIOFormat::FileFormat {
format: ::core::clone::Clone::clone(__self_0),
},
}
}
}Clone, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::PartialEq for HiveIOFormat {
#[inline]
fn eq(&self, other: &HiveIOFormat) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(HiveIOFormat::IOF {
input_format: __self_0, output_format: __self_1 },
HiveIOFormat::IOF {
input_format: __arg1_0, output_format: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(HiveIOFormat::FileFormat { format: __self_0 },
HiveIOFormat::FileFormat { format: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::PartialOrd for HiveIOFormat {
#[inline]
fn partial_cmp(&self, other: &HiveIOFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::Eq for HiveIOFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<FileFormat>;
}
}Eq, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::Ord for HiveIOFormat {
#[inline]
fn cmp(&self, other: &HiveIOFormat) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(HiveIOFormat::IOF {
input_format: __self_0, output_format: __self_1 },
HiveIOFormat::IOF {
input_format: __arg1_0, output_format: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(HiveIOFormat::FileFormat { format: __self_0 },
HiveIOFormat::FileFormat { format: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::hash::Hash for HiveIOFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
HiveIOFormat::IOF {
input_format: __self_0, output_format: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
HiveIOFormat::FileFormat { format: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8310#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8311#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveIOFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IOF { input_format, output_format } => {
sqlparser::ast::Visit::visit(input_format, visitor)?;
sqlparser::ast::Visit::visit(output_format, visitor)?;
}
Self::FileFormat { format } => {
sqlparser::ast::Visit::visit(format, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveIOFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IOF { input_format, output_format } => {
sqlparser::ast::VisitMut::visit(input_format, visitor)?;
sqlparser::ast::VisitMut::visit(output_format, visitor)?;
}
Self::FileFormat { format } => {
sqlparser::ast::VisitMut::visit(format, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8312#[allow(clippy::large_enum_variant)]
8313pub enum HiveIOFormat {
8315 IOF {
8317 input_format: Expr,
8319 output_format: Expr,
8321 },
8322 FileFormat {
8324 format: FileFormat,
8326 },
8327}
8328
8329#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveFormat {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field4_finish(f, "HiveFormat",
"row_format", &self.row_format, "serde_properties",
&self.serde_properties, "storage", &self.storage, "location",
&&self.location)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HiveFormat {
#[inline]
fn clone(&self) -> HiveFormat {
HiveFormat {
row_format: ::core::clone::Clone::clone(&self.row_format),
serde_properties: ::core::clone::Clone::clone(&self.serde_properties),
storage: ::core::clone::Clone::clone(&self.storage),
location: ::core::clone::Clone::clone(&self.location),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveFormat {
#[inline]
fn eq(&self, other: &HiveFormat) -> bool {
self.row_format == other.row_format &&
self.serde_properties == other.serde_properties &&
self.storage == other.storage &&
self.location == other.location
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveFormat {
#[inline]
fn partial_cmp(&self, other: &HiveFormat)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveFormat {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<HiveRowFormat>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<SqlOption>>>;
let _: ::core::cmp::AssertParamIsEq<Option<HiveIOFormat>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveFormat {
#[inline]
fn cmp(&self, other: &HiveFormat) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.row_format, &other.row_format) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.serde_properties,
&other.serde_properties) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.storage, &other.storage) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.location, &other.location),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveFormat {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.row_format, state);
::core::hash::Hash::hash(&self.serde_properties, state);
::core::hash::Hash::hash(&self.storage, state);
::core::hash::Hash::hash(&self.location, state)
}
}Hash, #[automatically_derived]
impl ::core::default::Default for HiveFormat {
#[inline]
fn default() -> HiveFormat {
HiveFormat {
row_format: ::core::default::Default::default(),
serde_properties: ::core::default::Default::default(),
storage: ::core::default::Default::default(),
location: ::core::default::Default::default(),
}
}
}Default)]
8330#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8331#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveFormat {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.row_format, visitor)?;
sqlparser::ast::Visit::visit(&self.serde_properties,
visitor)?;
sqlparser::ast::Visit::visit(&self.storage, visitor)?;
sqlparser::ast::Visit::visit(&self.location, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveFormat {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.row_format,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.serde_properties,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.storage,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.location,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8332pub struct HiveFormat {
8334 pub row_format: Option<HiveRowFormat>,
8336 pub serde_properties: Option<Vec<SqlOption>>,
8338 pub storage: Option<HiveIOFormat>,
8340 pub location: Option<String>,
8342}
8343
8344#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ClusteredIndex {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"ClusteredIndex", "name", &self.name, "asc", &&self.asc)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ClusteredIndex {
#[inline]
fn clone(&self) -> ClusteredIndex {
ClusteredIndex {
name: ::core::clone::Clone::clone(&self.name),
asc: ::core::clone::Clone::clone(&self.asc),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ClusteredIndex {
#[inline]
fn eq(&self, other: &ClusteredIndex) -> bool {
self.name == other.name && self.asc == other.asc
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ClusteredIndex {
#[inline]
fn partial_cmp(&self, other: &ClusteredIndex)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ClusteredIndex {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ClusteredIndex {
#[inline]
fn cmp(&self, other: &ClusteredIndex) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.asc, &other.asc),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ClusteredIndex {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.asc, state)
}
}Hash)]
8345#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8346#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ClusteredIndex {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.asc, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ClusteredIndex {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.asc, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8347pub struct ClusteredIndex {
8349 pub name: Ident,
8351 pub asc: Option<bool>,
8353}
8354
8355impl fmt::Display for ClusteredIndex {
8356 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8357 f.write_fmt(format_args!("{0}", self.name))write!(f, "{}", self.name)?;
8358 match self.asc {
8359 Some(true) => f.write_fmt(format_args!(" ASC"))write!(f, " ASC"),
8360 Some(false) => f.write_fmt(format_args!(" DESC"))write!(f, " DESC"),
8361 _ => Ok(()),
8362 }
8363 }
8364}
8365
8366#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TableOptionsClustered {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
TableOptionsClustered::ColumnstoreIndex =>
::core::fmt::Formatter::write_str(f, "ColumnstoreIndex"),
TableOptionsClustered::ColumnstoreIndexOrder(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ColumnstoreIndexOrder", &__self_0),
TableOptionsClustered::Index(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Index",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TableOptionsClustered {
#[inline]
fn clone(&self) -> TableOptionsClustered {
match self {
TableOptionsClustered::ColumnstoreIndex =>
TableOptionsClustered::ColumnstoreIndex,
TableOptionsClustered::ColumnstoreIndexOrder(__self_0) =>
TableOptionsClustered::ColumnstoreIndexOrder(::core::clone::Clone::clone(__self_0)),
TableOptionsClustered::Index(__self_0) =>
TableOptionsClustered::Index(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TableOptionsClustered {
#[inline]
fn eq(&self, other: &TableOptionsClustered) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(TableOptionsClustered::ColumnstoreIndexOrder(__self_0),
TableOptionsClustered::ColumnstoreIndexOrder(__arg1_0)) =>
__self_0 == __arg1_0,
(TableOptionsClustered::Index(__self_0),
TableOptionsClustered::Index(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TableOptionsClustered {
#[inline]
fn partial_cmp(&self, other: &TableOptionsClustered)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TableOptionsClustered {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<ClusteredIndex>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TableOptionsClustered {
#[inline]
fn cmp(&self, other: &TableOptionsClustered) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(TableOptionsClustered::ColumnstoreIndexOrder(__self_0),
TableOptionsClustered::ColumnstoreIndexOrder(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(TableOptionsClustered::Index(__self_0),
TableOptionsClustered::Index(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TableOptionsClustered {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
TableOptionsClustered::ColumnstoreIndexOrder(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
TableOptionsClustered::Index(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
8367#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8368#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TableOptionsClustered {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ColumnstoreIndex => {}
Self::ColumnstoreIndexOrder(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Index(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TableOptionsClustered {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ColumnstoreIndex => {}
Self::ColumnstoreIndexOrder(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Index(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8369pub enum TableOptionsClustered {
8371 ColumnstoreIndex,
8373 ColumnstoreIndexOrder(Vec<Ident>),
8375 Index(Vec<ClusteredIndex>),
8377}
8378
8379impl fmt::Display for TableOptionsClustered {
8380 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8381 match self {
8382 TableOptionsClustered::ColumnstoreIndex => {
8383 f.write_fmt(format_args!("CLUSTERED COLUMNSTORE INDEX"))write!(f, "CLUSTERED COLUMNSTORE INDEX")
8384 }
8385 TableOptionsClustered::ColumnstoreIndexOrder(values) => {
8386 f.write_fmt(format_args!("CLUSTERED COLUMNSTORE INDEX ORDER ({0})",
display_comma_separated(values)))write!(
8387 f,
8388 "CLUSTERED COLUMNSTORE INDEX ORDER ({})",
8389 display_comma_separated(values)
8390 )
8391 }
8392 TableOptionsClustered::Index(values) => {
8393 f.write_fmt(format_args!("CLUSTERED INDEX ({0})",
display_comma_separated(values)))write!(f, "CLUSTERED INDEX ({})", display_comma_separated(values))
8394 }
8395 }
8396 }
8397}
8398
8399#[derive(#[automatically_derived]
impl ::core::fmt::Debug for PartitionRangeDirection {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
PartitionRangeDirection::Left => "Left",
PartitionRangeDirection::Right => "Right",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for PartitionRangeDirection {
#[inline]
fn clone(&self) -> PartitionRangeDirection { *self }
}Clone, #[automatically_derived]
impl ::core::marker::Copy for PartitionRangeDirection { }Copy, #[automatically_derived]
impl ::core::cmp::PartialEq for PartitionRangeDirection {
#[inline]
fn eq(&self, other: &PartitionRangeDirection) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for PartitionRangeDirection {
#[inline]
fn partial_cmp(&self, other: &PartitionRangeDirection)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for PartitionRangeDirection {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for PartitionRangeDirection {
#[inline]
fn cmp(&self, other: &PartitionRangeDirection) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for PartitionRangeDirection {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8401#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8402#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for PartitionRangeDirection {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Left => {} Self::Right => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for PartitionRangeDirection {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Left => {} Self::Right => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8403pub enum PartitionRangeDirection {
8404 Left,
8406 Right,
8408}
8409
8410#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SqlOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
SqlOption::Clustered(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Clustered", &__self_0),
SqlOption::Ident(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Ident",
&__self_0),
SqlOption::KeyValue { key: __self_0, value: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"KeyValue", "key", __self_0, "value", &__self_1),
SqlOption::Partition {
column_name: __self_0,
range_direction: __self_1,
for_values: __self_2 } =>
::core::fmt::Formatter::debug_struct_field3_finish(f,
"Partition", "column_name", __self_0, "range_direction",
__self_1, "for_values", &__self_2),
SqlOption::Comment(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Comment", &__self_0),
SqlOption::TableSpace(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"TableSpace", &__self_0),
SqlOption::NamedParenthesizedList(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"NamedParenthesizedList", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SqlOption {
#[inline]
fn clone(&self) -> SqlOption {
match self {
SqlOption::Clustered(__self_0) =>
SqlOption::Clustered(::core::clone::Clone::clone(__self_0)),
SqlOption::Ident(__self_0) =>
SqlOption::Ident(::core::clone::Clone::clone(__self_0)),
SqlOption::KeyValue { key: __self_0, value: __self_1 } =>
SqlOption::KeyValue {
key: ::core::clone::Clone::clone(__self_0),
value: ::core::clone::Clone::clone(__self_1),
},
SqlOption::Partition {
column_name: __self_0,
range_direction: __self_1,
for_values: __self_2 } =>
SqlOption::Partition {
column_name: ::core::clone::Clone::clone(__self_0),
range_direction: ::core::clone::Clone::clone(__self_1),
for_values: ::core::clone::Clone::clone(__self_2),
},
SqlOption::Comment(__self_0) =>
SqlOption::Comment(::core::clone::Clone::clone(__self_0)),
SqlOption::TableSpace(__self_0) =>
SqlOption::TableSpace(::core::clone::Clone::clone(__self_0)),
SqlOption::NamedParenthesizedList(__self_0) =>
SqlOption::NamedParenthesizedList(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SqlOption {
#[inline]
fn eq(&self, other: &SqlOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(SqlOption::Clustered(__self_0),
SqlOption::Clustered(__arg1_0)) => __self_0 == __arg1_0,
(SqlOption::Ident(__self_0), SqlOption::Ident(__arg1_0)) =>
__self_0 == __arg1_0,
(SqlOption::KeyValue { key: __self_0, value: __self_1 },
SqlOption::KeyValue { key: __arg1_0, value: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(SqlOption::Partition {
column_name: __self_0,
range_direction: __self_1,
for_values: __self_2 }, SqlOption::Partition {
column_name: __arg1_0,
range_direction: __arg1_1,
for_values: __arg1_2 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1 &&
__self_2 == __arg1_2,
(SqlOption::Comment(__self_0), SqlOption::Comment(__arg1_0))
=> __self_0 == __arg1_0,
(SqlOption::TableSpace(__self_0),
SqlOption::TableSpace(__arg1_0)) => __self_0 == __arg1_0,
(SqlOption::NamedParenthesizedList(__self_0),
SqlOption::NamedParenthesizedList(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SqlOption {
#[inline]
fn partial_cmp(&self, other: &SqlOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SqlOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<TableOptionsClustered>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Option<PartitionRangeDirection>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
let _: ::core::cmp::AssertParamIsEq<CommentDef>;
let _: ::core::cmp::AssertParamIsEq<TablespaceOption>;
let _: ::core::cmp::AssertParamIsEq<NamedParenthesizedList>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SqlOption {
#[inline]
fn cmp(&self, other: &SqlOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(SqlOption::Clustered(__self_0),
SqlOption::Clustered(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SqlOption::Ident(__self_0), SqlOption::Ident(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SqlOption::KeyValue { key: __self_0, value: __self_1 },
SqlOption::KeyValue { key: __arg1_0, value: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(SqlOption::Partition {
column_name: __self_0,
range_direction: __self_1,
for_values: __self_2 }, SqlOption::Partition {
column_name: __arg1_0,
range_direction: __arg1_1,
for_values: __arg1_2 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(__self_1, __arg1_1) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_2, __arg1_2),
cmp => cmp,
},
cmp => cmp,
},
(SqlOption::Comment(__self_0), SqlOption::Comment(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SqlOption::TableSpace(__self_0),
SqlOption::TableSpace(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SqlOption::NamedParenthesizedList(__self_0),
SqlOption::NamedParenthesizedList(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SqlOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
SqlOption::Clustered(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SqlOption::Ident(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SqlOption::KeyValue { key: __self_0, value: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
SqlOption::Partition {
column_name: __self_0,
range_direction: __self_1,
for_values: __self_2 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state);
::core::hash::Hash::hash(__self_2, state)
}
SqlOption::Comment(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SqlOption::TableSpace(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SqlOption::NamedParenthesizedList(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8411#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8412#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SqlOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Clustered(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Ident(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::KeyValue { key, value } => {
sqlparser::ast::Visit::visit(key, visitor)?;
sqlparser::ast::Visit::visit(value, visitor)?;
}
Self::Partition { column_name, range_direction, for_values }
=> {
sqlparser::ast::Visit::visit(column_name, visitor)?;
sqlparser::ast::Visit::visit(range_direction, visitor)?;
sqlparser::ast::Visit::visit(for_values, visitor)?;
}
Self::Comment(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::TableSpace(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::NamedParenthesizedList(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SqlOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Clustered(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Ident(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::KeyValue { key, value } => {
sqlparser::ast::VisitMut::visit(key, visitor)?;
sqlparser::ast::VisitMut::visit(value, visitor)?;
}
Self::Partition { column_name, range_direction, for_values }
=> {
sqlparser::ast::VisitMut::visit(column_name, visitor)?;
sqlparser::ast::VisitMut::visit(range_direction, visitor)?;
sqlparser::ast::VisitMut::visit(for_values, visitor)?;
}
Self::Comment(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::TableSpace(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::NamedParenthesizedList(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8413pub enum SqlOption {
8415 Clustered(TableOptionsClustered),
8419 Ident(Ident),
8423 KeyValue {
8427 key: Ident,
8429 value: Expr,
8431 },
8432 Partition {
8439 column_name: Ident,
8441 range_direction: Option<PartitionRangeDirection>,
8443 for_values: Vec<Expr>,
8445 },
8446 Comment(CommentDef),
8448 TableSpace(TablespaceOption),
8451 NamedParenthesizedList(NamedParenthesizedList),
8458}
8459
8460impl fmt::Display for SqlOption {
8461 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8462 match self {
8463 SqlOption::Clustered(c) => f.write_fmt(format_args!("{0}", c))write!(f, "{c}"),
8464 SqlOption::Ident(ident) => {
8465 f.write_fmt(format_args!("{0}", ident))write!(f, "{ident}")
8466 }
8467 SqlOption::KeyValue { key: name, value } => {
8468 f.write_fmt(format_args!("{0} = {1}", name, value))write!(f, "{name} = {value}")
8469 }
8470 SqlOption::Partition {
8471 column_name,
8472 range_direction,
8473 for_values,
8474 } => {
8475 let direction = match range_direction {
8476 Some(PartitionRangeDirection::Left) => " LEFT",
8477 Some(PartitionRangeDirection::Right) => " RIGHT",
8478 None => "",
8479 };
8480
8481 f.write_fmt(format_args!("PARTITION ({0} RANGE{1} FOR VALUES ({2}))",
column_name, direction, display_comma_separated(for_values)))write!(
8482 f,
8483 "PARTITION ({} RANGE{} FOR VALUES ({}))",
8484 column_name,
8485 direction,
8486 display_comma_separated(for_values)
8487 )
8488 }
8489 SqlOption::TableSpace(tablespace_option) => {
8490 f.write_fmt(format_args!("TABLESPACE {0}", tablespace_option.name))write!(f, "TABLESPACE {}", tablespace_option.name)?;
8491 match tablespace_option.storage {
8492 Some(StorageType::Disk) => f.write_fmt(format_args!(" STORAGE DISK"))write!(f, " STORAGE DISK"),
8493 Some(StorageType::Memory) => f.write_fmt(format_args!(" STORAGE MEMORY"))write!(f, " STORAGE MEMORY"),
8494 None => Ok(()),
8495 }
8496 }
8497 SqlOption::Comment(comment) => match comment {
8498 CommentDef::WithEq(comment) => {
8499 f.write_fmt(format_args!("COMMENT = \'{0}\'", comment))write!(f, "COMMENT = '{comment}'")
8500 }
8501 CommentDef::WithoutEq(comment) => {
8502 f.write_fmt(format_args!("COMMENT \'{0}\'", comment))write!(f, "COMMENT '{comment}'")
8503 }
8504 },
8505 SqlOption::NamedParenthesizedList(value) => {
8506 f.write_fmt(format_args!("{0} = ", value.key))write!(f, "{} = ", value.key)?;
8507 if let Some(key) = &value.name {
8508 f.write_fmt(format_args!("{0}", key))write!(f, "{key}")?;
8509 }
8510 if !value.values.is_empty() {
8511 f.write_fmt(format_args!("({0})", display_comma_separated(&value.values)))write!(f, "({})", display_comma_separated(&value.values))?
8512 }
8513 Ok(())
8514 }
8515 }
8516 }
8517}
8518
8519#[derive(#[automatically_derived]
impl ::core::fmt::Debug for StorageType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
StorageType::Disk => "Disk",
StorageType::Memory => "Memory",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for StorageType {
#[inline]
fn clone(&self) -> StorageType {
match self {
StorageType::Disk => StorageType::Disk,
StorageType::Memory => StorageType::Memory,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for StorageType {
#[inline]
fn eq(&self, other: &StorageType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::Eq for StorageType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::hash::Hash for StorageType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash, #[automatically_derived]
impl ::core::cmp::PartialOrd for StorageType {
#[inline]
fn partial_cmp(&self, other: &StorageType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Ord for StorageType {
#[inline]
fn cmp(&self, other: &StorageType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord)]
8520#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8521#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for StorageType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Disk => {} Self::Memory => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for StorageType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Disk => {} Self::Memory => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8522pub enum StorageType {
8524 Disk,
8526 Memory,
8528}
8529
8530#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TablespaceOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"TablespaceOption", "name", &self.name, "storage", &&self.storage)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TablespaceOption {
#[inline]
fn clone(&self) -> TablespaceOption {
TablespaceOption {
name: ::core::clone::Clone::clone(&self.name),
storage: ::core::clone::Clone::clone(&self.storage),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TablespaceOption {
#[inline]
fn eq(&self, other: &TablespaceOption) -> bool {
self.name == other.name && self.storage == other.storage
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::Eq for TablespaceOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<Option<StorageType>>;
}
}Eq, #[automatically_derived]
impl ::core::hash::Hash for TablespaceOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.storage, state)
}
}Hash, #[automatically_derived]
impl ::core::cmp::PartialOrd for TablespaceOption {
#[inline]
fn partial_cmp(&self, other: &TablespaceOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Ord for TablespaceOption {
#[inline]
fn cmp(&self, other: &TablespaceOption) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.storage, &other.storage),
cmp => cmp,
}
}
}Ord)]
8531#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8532#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TablespaceOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.storage, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TablespaceOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.storage,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8533pub struct TablespaceOption {
8536 pub name: String,
8538 pub storage: Option<StorageType>,
8540}
8541
8542#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SecretOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "SecretOption",
"key", &self.key, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SecretOption {
#[inline]
fn clone(&self) -> SecretOption {
SecretOption {
key: ::core::clone::Clone::clone(&self.key),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SecretOption {
#[inline]
fn eq(&self, other: &SecretOption) -> bool {
self.key == other.key && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SecretOption {
#[inline]
fn partial_cmp(&self, other: &SecretOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SecretOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SecretOption {
#[inline]
fn cmp(&self, other: &SecretOption) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.key, &other.key) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SecretOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.key, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
8543#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8544#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SecretOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.key, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SecretOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.key, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8545pub struct SecretOption {
8547 pub key: Ident,
8549 pub value: Ident,
8551}
8552
8553impl fmt::Display for SecretOption {
8554 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8555 f.write_fmt(format_args!("{0} {1}", self.key, self.value))write!(f, "{} {}", self.key, self.value)
8556 }
8557}
8558
8559#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateServerStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["name", "if_not_exists", "server_type", "version",
"foreign_data_wrapper", "options"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.name, &self.if_not_exists, &self.server_type,
&self.version, &self.foreign_data_wrapper, &&self.options];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"CreateServerStatement", names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateServerStatement {
#[inline]
fn clone(&self) -> CreateServerStatement {
CreateServerStatement {
name: ::core::clone::Clone::clone(&self.name),
if_not_exists: ::core::clone::Clone::clone(&self.if_not_exists),
server_type: ::core::clone::Clone::clone(&self.server_type),
version: ::core::clone::Clone::clone(&self.version),
foreign_data_wrapper: ::core::clone::Clone::clone(&self.foreign_data_wrapper),
options: ::core::clone::Clone::clone(&self.options),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateServerStatement {
#[inline]
fn eq(&self, other: &CreateServerStatement) -> bool {
self.if_not_exists == other.if_not_exists && self.name == other.name
&& self.server_type == other.server_type &&
self.version == other.version &&
self.foreign_data_wrapper == other.foreign_data_wrapper &&
self.options == other.options
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateServerStatement {
#[inline]
fn partial_cmp(&self, other: &CreateServerStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateServerStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<CreateServerOption>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateServerStatement {
#[inline]
fn cmp(&self, other: &CreateServerStatement) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.if_not_exists,
&other.if_not_exists) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.server_type,
&other.server_type) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.version, &other.version) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.foreign_data_wrapper,
&other.foreign_data_wrapper) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.options, &other.options),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateServerStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.if_not_exists, state);
::core::hash::Hash::hash(&self.server_type, state);
::core::hash::Hash::hash(&self.version, state);
::core::hash::Hash::hash(&self.foreign_data_wrapper, state);
::core::hash::Hash::hash(&self.options, state)
}
}Hash)]
8563#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8564#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateServerStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(&self.server_type, visitor)?;
sqlparser::ast::Visit::visit(&self.version, visitor)?;
sqlparser::ast::Visit::visit(&self.foreign_data_wrapper,
visitor)?;
sqlparser::ast::Visit::visit(&self.options, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateServerStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.if_not_exists,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.server_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.version,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.foreign_data_wrapper,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.options,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8565pub struct CreateServerStatement {
8566 pub name: ObjectName,
8568 pub if_not_exists: bool,
8570 pub server_type: Option<Ident>,
8572 pub version: Option<Ident>,
8574 pub foreign_data_wrapper: ObjectName,
8576 pub options: Option<Vec<CreateServerOption>>,
8578}
8579
8580impl fmt::Display for CreateServerStatement {
8581 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
8582 let CreateServerStatement {
8583 name,
8584 if_not_exists,
8585 server_type,
8586 version,
8587 foreign_data_wrapper,
8588 options,
8589 } = self;
8590
8591 f.write_fmt(format_args!("CREATE SERVER {0}{1} ",
if *if_not_exists { "IF NOT EXISTS " } else { "" }, name))write!(
8592 f,
8593 "CREATE SERVER {if_not_exists}{name} ",
8594 if_not_exists = if *if_not_exists { "IF NOT EXISTS " } else { "" },
8595 )?;
8596
8597 if let Some(st) = server_type {
8598 f.write_fmt(format_args!("TYPE {0} ", st))write!(f, "TYPE {st} ")?;
8599 }
8600
8601 if let Some(v) = version {
8602 f.write_fmt(format_args!("VERSION {0} ", v))write!(f, "VERSION {v} ")?;
8603 }
8604
8605 f.write_fmt(format_args!("FOREIGN DATA WRAPPER {0}", foreign_data_wrapper))write!(f, "FOREIGN DATA WRAPPER {foreign_data_wrapper}")?;
8606
8607 if let Some(o) = options {
8608 f.write_fmt(format_args!(" OPTIONS ({0})", display_comma_separated(o)))write!(f, " OPTIONS ({o})", o = display_comma_separated(o))?;
8609 }
8610
8611 Ok(())
8612 }
8613}
8614
8615#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateServerOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"CreateServerOption", "key", &self.key, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateServerOption {
#[inline]
fn clone(&self) -> CreateServerOption {
CreateServerOption {
key: ::core::clone::Clone::clone(&self.key),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateServerOption {
#[inline]
fn eq(&self, other: &CreateServerOption) -> bool {
self.key == other.key && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateServerOption {
#[inline]
fn partial_cmp(&self, other: &CreateServerOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateServerOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateServerOption {
#[inline]
fn cmp(&self, other: &CreateServerOption) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.key, &other.key) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateServerOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.key, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
8617#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8618#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateServerOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.key, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateServerOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.key, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8619pub struct CreateServerOption {
8620 pub key: Ident,
8622 pub value: Ident,
8624}
8625
8626impl fmt::Display for CreateServerOption {
8627 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8628 f.write_fmt(format_args!("{0} {1}", self.key, self.value))write!(f, "{} {}", self.key, self.value)
8629 }
8630}
8631
8632#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AttachDuckDBDatabaseOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
AttachDuckDBDatabaseOption::ReadOnly(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ReadOnly", &__self_0),
AttachDuckDBDatabaseOption::Type(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Type",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AttachDuckDBDatabaseOption {
#[inline]
fn clone(&self) -> AttachDuckDBDatabaseOption {
match self {
AttachDuckDBDatabaseOption::ReadOnly(__self_0) =>
AttachDuckDBDatabaseOption::ReadOnly(::core::clone::Clone::clone(__self_0)),
AttachDuckDBDatabaseOption::Type(__self_0) =>
AttachDuckDBDatabaseOption::Type(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AttachDuckDBDatabaseOption {
#[inline]
fn eq(&self, other: &AttachDuckDBDatabaseOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(AttachDuckDBDatabaseOption::ReadOnly(__self_0),
AttachDuckDBDatabaseOption::ReadOnly(__arg1_0)) =>
__self_0 == __arg1_0,
(AttachDuckDBDatabaseOption::Type(__self_0),
AttachDuckDBDatabaseOption::Type(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AttachDuckDBDatabaseOption {
#[inline]
fn partial_cmp(&self, other: &AttachDuckDBDatabaseOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AttachDuckDBDatabaseOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AttachDuckDBDatabaseOption {
#[inline]
fn cmp(&self, other: &AttachDuckDBDatabaseOption)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(AttachDuckDBDatabaseOption::ReadOnly(__self_0),
AttachDuckDBDatabaseOption::ReadOnly(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(AttachDuckDBDatabaseOption::Type(__self_0),
AttachDuckDBDatabaseOption::Type(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AttachDuckDBDatabaseOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
AttachDuckDBDatabaseOption::ReadOnly(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
AttachDuckDBDatabaseOption::Type(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8633#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8634#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AttachDuckDBDatabaseOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ReadOnly(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Type(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AttachDuckDBDatabaseOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ReadOnly(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Type(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8635pub enum AttachDuckDBDatabaseOption {
8637 ReadOnly(Option<bool>),
8639 Type(Ident),
8641}
8642
8643impl fmt::Display for AttachDuckDBDatabaseOption {
8644 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8645 match self {
8646 AttachDuckDBDatabaseOption::ReadOnly(Some(true)) => f.write_fmt(format_args!("READ_ONLY true"))write!(f, "READ_ONLY true"),
8647 AttachDuckDBDatabaseOption::ReadOnly(Some(false)) => f.write_fmt(format_args!("READ_ONLY false"))write!(f, "READ_ONLY false"),
8648 AttachDuckDBDatabaseOption::ReadOnly(None) => f.write_fmt(format_args!("READ_ONLY"))write!(f, "READ_ONLY"),
8649 AttachDuckDBDatabaseOption::Type(t) => f.write_fmt(format_args!("TYPE {0}", t))write!(f, "TYPE {t}"),
8650 }
8651 }
8652}
8653
8654#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TransactionMode {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
TransactionMode::AccessMode(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AccessMode", &__self_0),
TransactionMode::IsolationLevel(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IsolationLevel", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for TransactionMode { }Copy, #[automatically_derived]
impl ::core::clone::Clone for TransactionMode {
#[inline]
fn clone(&self) -> TransactionMode {
let _: ::core::clone::AssertParamIsClone<TransactionAccessMode>;
let _: ::core::clone::AssertParamIsClone<TransactionIsolationLevel>;
*self
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TransactionMode {
#[inline]
fn eq(&self, other: &TransactionMode) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(TransactionMode::AccessMode(__self_0),
TransactionMode::AccessMode(__arg1_0)) =>
__self_0 == __arg1_0,
(TransactionMode::IsolationLevel(__self_0),
TransactionMode::IsolationLevel(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TransactionMode {
#[inline]
fn partial_cmp(&self, other: &TransactionMode)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TransactionMode {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<TransactionAccessMode>;
let _: ::core::cmp::AssertParamIsEq<TransactionIsolationLevel>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TransactionMode {
#[inline]
fn cmp(&self, other: &TransactionMode) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(TransactionMode::AccessMode(__self_0),
TransactionMode::AccessMode(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(TransactionMode::IsolationLevel(__self_0),
TransactionMode::IsolationLevel(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TransactionMode {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
TransactionMode::AccessMode(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
TransactionMode::IsolationLevel(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8655#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8656#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TransactionMode {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AccessMode(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IsolationLevel(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TransactionMode {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AccessMode(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IsolationLevel(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8657pub enum TransactionMode {
8659 AccessMode(TransactionAccessMode),
8661 IsolationLevel(TransactionIsolationLevel),
8663}
8664
8665impl fmt::Display for TransactionMode {
8666 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8667 use TransactionMode::*;
8668 match self {
8669 AccessMode(access_mode) => f.write_fmt(format_args!("{0}", access_mode))write!(f, "{access_mode}"),
8670 IsolationLevel(iso_level) => f.write_fmt(format_args!("ISOLATION LEVEL {0}", iso_level))write!(f, "ISOLATION LEVEL {iso_level}"),
8671 }
8672 }
8673}
8674
8675#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TransactionAccessMode {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
TransactionAccessMode::ReadOnly => "ReadOnly",
TransactionAccessMode::ReadWrite => "ReadWrite",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for TransactionAccessMode { }Copy, #[automatically_derived]
impl ::core::clone::Clone for TransactionAccessMode {
#[inline]
fn clone(&self) -> TransactionAccessMode { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TransactionAccessMode {
#[inline]
fn eq(&self, other: &TransactionAccessMode) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TransactionAccessMode {
#[inline]
fn partial_cmp(&self, other: &TransactionAccessMode)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TransactionAccessMode {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TransactionAccessMode {
#[inline]
fn cmp(&self, other: &TransactionAccessMode) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TransactionAccessMode {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8676#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8677#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TransactionAccessMode {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::ReadOnly => {} Self::ReadWrite => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TransactionAccessMode {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::ReadOnly => {} Self::ReadWrite => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8678pub enum TransactionAccessMode {
8680 ReadOnly,
8682 ReadWrite,
8684}
8685
8686impl fmt::Display for TransactionAccessMode {
8687 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8688 use TransactionAccessMode::*;
8689 f.write_str(match self {
8690 ReadOnly => "READ ONLY",
8691 ReadWrite => "READ WRITE",
8692 })
8693 }
8694}
8695
8696#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TransactionIsolationLevel {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
TransactionIsolationLevel::ReadUncommitted =>
"ReadUncommitted",
TransactionIsolationLevel::ReadCommitted => "ReadCommitted",
TransactionIsolationLevel::RepeatableRead => "RepeatableRead",
TransactionIsolationLevel::Serializable => "Serializable",
TransactionIsolationLevel::Snapshot => "Snapshot",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for TransactionIsolationLevel { }Copy, #[automatically_derived]
impl ::core::clone::Clone for TransactionIsolationLevel {
#[inline]
fn clone(&self) -> TransactionIsolationLevel { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TransactionIsolationLevel {
#[inline]
fn eq(&self, other: &TransactionIsolationLevel) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TransactionIsolationLevel {
#[inline]
fn partial_cmp(&self, other: &TransactionIsolationLevel)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TransactionIsolationLevel {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TransactionIsolationLevel {
#[inline]
fn cmp(&self, other: &TransactionIsolationLevel)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TransactionIsolationLevel {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8697#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8698#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TransactionIsolationLevel {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ReadUncommitted => {}
Self::ReadCommitted => {}
Self::RepeatableRead => {}
Self::Serializable => {}
Self::Snapshot => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TransactionIsolationLevel {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ReadUncommitted => {}
Self::ReadCommitted => {}
Self::RepeatableRead => {}
Self::Serializable => {}
Self::Snapshot => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8699pub enum TransactionIsolationLevel {
8701 ReadUncommitted,
8703 ReadCommitted,
8705 RepeatableRead,
8707 Serializable,
8709 Snapshot,
8711}
8712
8713impl fmt::Display for TransactionIsolationLevel {
8714 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8715 use TransactionIsolationLevel::*;
8716 f.write_str(match self {
8717 ReadUncommitted => "READ UNCOMMITTED",
8718 ReadCommitted => "READ COMMITTED",
8719 RepeatableRead => "REPEATABLE READ",
8720 Serializable => "SERIALIZABLE",
8721 Snapshot => "SNAPSHOT",
8722 })
8723 }
8724}
8725
8726#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TransactionModifier {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
TransactionModifier::Deferred => "Deferred",
TransactionModifier::Immediate => "Immediate",
TransactionModifier::Exclusive => "Exclusive",
TransactionModifier::Try => "Try",
TransactionModifier::Catch => "Catch",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for TransactionModifier { }Copy, #[automatically_derived]
impl ::core::clone::Clone for TransactionModifier {
#[inline]
fn clone(&self) -> TransactionModifier { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TransactionModifier {
#[inline]
fn eq(&self, other: &TransactionModifier) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TransactionModifier {
#[inline]
fn partial_cmp(&self, other: &TransactionModifier)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TransactionModifier {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TransactionModifier {
#[inline]
fn cmp(&self, other: &TransactionModifier) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TransactionModifier {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8731#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8732#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TransactionModifier {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Deferred => {}
Self::Immediate => {}
Self::Exclusive => {}
Self::Try => {}
Self::Catch => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TransactionModifier {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Deferred => {}
Self::Immediate => {}
Self::Exclusive => {}
Self::Try => {}
Self::Catch => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8733pub enum TransactionModifier {
8734 Deferred,
8736 Immediate,
8738 Exclusive,
8740 Try,
8742 Catch,
8744}
8745
8746impl fmt::Display for TransactionModifier {
8747 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8748 use TransactionModifier::*;
8749 f.write_str(match self {
8750 Deferred => "DEFERRED",
8751 Immediate => "IMMEDIATE",
8752 Exclusive => "EXCLUSIVE",
8753 Try => "TRY",
8754 Catch => "CATCH",
8755 })
8756 }
8757}
8758
8759#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowStatementFilter {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ShowStatementFilter::Like(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Like",
&__self_0),
ShowStatementFilter::ILike(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "ILike",
&__self_0),
ShowStatementFilter::Where(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Where",
&__self_0),
ShowStatementFilter::NoKeyword(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"NoKeyword", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowStatementFilter {
#[inline]
fn clone(&self) -> ShowStatementFilter {
match self {
ShowStatementFilter::Like(__self_0) =>
ShowStatementFilter::Like(::core::clone::Clone::clone(__self_0)),
ShowStatementFilter::ILike(__self_0) =>
ShowStatementFilter::ILike(::core::clone::Clone::clone(__self_0)),
ShowStatementFilter::Where(__self_0) =>
ShowStatementFilter::Where(::core::clone::Clone::clone(__self_0)),
ShowStatementFilter::NoKeyword(__self_0) =>
ShowStatementFilter::NoKeyword(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowStatementFilter {
#[inline]
fn eq(&self, other: &ShowStatementFilter) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(ShowStatementFilter::Like(__self_0),
ShowStatementFilter::Like(__arg1_0)) =>
__self_0 == __arg1_0,
(ShowStatementFilter::ILike(__self_0),
ShowStatementFilter::ILike(__arg1_0)) =>
__self_0 == __arg1_0,
(ShowStatementFilter::Where(__self_0),
ShowStatementFilter::Where(__arg1_0)) =>
__self_0 == __arg1_0,
(ShowStatementFilter::NoKeyword(__self_0),
ShowStatementFilter::NoKeyword(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowStatementFilter {
#[inline]
fn partial_cmp(&self, other: &ShowStatementFilter)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowStatementFilter {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowStatementFilter {
#[inline]
fn cmp(&self, other: &ShowStatementFilter) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(ShowStatementFilter::Like(__self_0),
ShowStatementFilter::Like(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ShowStatementFilter::ILike(__self_0),
ShowStatementFilter::ILike(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ShowStatementFilter::Where(__self_0),
ShowStatementFilter::Where(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ShowStatementFilter::NoKeyword(__self_0),
ShowStatementFilter::NoKeyword(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowStatementFilter {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
ShowStatementFilter::Like(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
ShowStatementFilter::ILike(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
ShowStatementFilter::Where(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
ShowStatementFilter::NoKeyword(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8760#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8761#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowStatementFilter {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Like(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ILike(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Where(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::NoKeyword(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowStatementFilter {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Like(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ILike(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Where(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::NoKeyword(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8762pub enum ShowStatementFilter {
8764 Like(String),
8766 ILike(String),
8768 Where(Expr),
8770 NoKeyword(String),
8772}
8773
8774impl fmt::Display for ShowStatementFilter {
8775 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8776 use ShowStatementFilter::*;
8777 match self {
8778 Like(pattern) => f.write_fmt(format_args!("LIKE \'{0}\'",
value::escape_single_quote_string(pattern)))write!(f, "LIKE '{}'", value::escape_single_quote_string(pattern)),
8779 ILike(pattern) => f.write_fmt(format_args!("ILIKE {0}",
value::escape_single_quote_string(pattern)))write!(f, "ILIKE {}", value::escape_single_quote_string(pattern)),
8780 Where(expr) => f.write_fmt(format_args!("WHERE {0}", expr))write!(f, "WHERE {expr}"),
8781 NoKeyword(pattern) => f.write_fmt(format_args!("\'{0}\'",
value::escape_single_quote_string(pattern)))write!(f, "'{}'", value::escape_single_quote_string(pattern)),
8782 }
8783 }
8784}
8785
8786#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowStatementInClause {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ShowStatementInClause::IN => "IN",
ShowStatementInClause::FROM => "FROM",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowStatementInClause {
#[inline]
fn clone(&self) -> ShowStatementInClause {
match self {
ShowStatementInClause::IN => ShowStatementInClause::IN,
ShowStatementInClause::FROM => ShowStatementInClause::FROM,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowStatementInClause {
#[inline]
fn eq(&self, other: &ShowStatementInClause) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowStatementInClause {
#[inline]
fn partial_cmp(&self, other: &ShowStatementInClause)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowStatementInClause {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowStatementInClause {
#[inline]
fn cmp(&self, other: &ShowStatementInClause) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowStatementInClause {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8787#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8788#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowStatementInClause {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::IN => {} Self::FROM => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowStatementInClause {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::IN => {} Self::FROM => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8789pub enum ShowStatementInClause {
8791 IN,
8793 FROM,
8795}
8796
8797impl fmt::Display for ShowStatementInClause {
8798 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8799 use ShowStatementInClause::*;
8800 match self {
8801 FROM => f.write_fmt(format_args!("FROM"))write!(f, "FROM"),
8802 IN => f.write_fmt(format_args!("IN"))write!(f, "IN"),
8803 }
8804 }
8805}
8806
8807#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SqliteOnConflict {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
SqliteOnConflict::Rollback => "Rollback",
SqliteOnConflict::Abort => "Abort",
SqliteOnConflict::Fail => "Fail",
SqliteOnConflict::Ignore => "Ignore",
SqliteOnConflict::Replace => "Replace",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for SqliteOnConflict { }Copy, #[automatically_derived]
impl ::core::clone::Clone for SqliteOnConflict {
#[inline]
fn clone(&self) -> SqliteOnConflict { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SqliteOnConflict {
#[inline]
fn eq(&self, other: &SqliteOnConflict) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SqliteOnConflict {
#[inline]
fn partial_cmp(&self, other: &SqliteOnConflict)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SqliteOnConflict {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SqliteOnConflict {
#[inline]
fn cmp(&self, other: &SqliteOnConflict) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SqliteOnConflict {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8812#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8813#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SqliteOnConflict {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Rollback => {}
Self::Abort => {}
Self::Fail => {}
Self::Ignore => {}
Self::Replace => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SqliteOnConflict {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Rollback => {}
Self::Abort => {}
Self::Fail => {}
Self::Ignore => {}
Self::Replace => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8814pub enum SqliteOnConflict {
8815 Rollback,
8817 Abort,
8819 Fail,
8821 Ignore,
8823 Replace,
8825}
8826
8827impl fmt::Display for SqliteOnConflict {
8828 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8829 use SqliteOnConflict::*;
8830 match self {
8831 Rollback => f.write_fmt(format_args!("OR ROLLBACK"))write!(f, "OR ROLLBACK"),
8832 Abort => f.write_fmt(format_args!("OR ABORT"))write!(f, "OR ABORT"),
8833 Fail => f.write_fmt(format_args!("OR FAIL"))write!(f, "OR FAIL"),
8834 Ignore => f.write_fmt(format_args!("OR IGNORE"))write!(f, "OR IGNORE"),
8835 Replace => f.write_fmt(format_args!("OR REPLACE"))write!(f, "OR REPLACE"),
8836 }
8837 }
8838}
8839
8840#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MysqlInsertPriority {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
MysqlInsertPriority::LowPriority => "LowPriority",
MysqlInsertPriority::Delayed => "Delayed",
MysqlInsertPriority::HighPriority => "HighPriority",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for MysqlInsertPriority { }Copy, #[automatically_derived]
impl ::core::clone::Clone for MysqlInsertPriority {
#[inline]
fn clone(&self) -> MysqlInsertPriority { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MysqlInsertPriority {
#[inline]
fn eq(&self, other: &MysqlInsertPriority) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MysqlInsertPriority {
#[inline]
fn partial_cmp(&self, other: &MysqlInsertPriority)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MysqlInsertPriority {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MysqlInsertPriority {
#[inline]
fn cmp(&self, other: &MysqlInsertPriority) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MysqlInsertPriority {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8846#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8847#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MysqlInsertPriority {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::LowPriority => {}
Self::Delayed => {}
Self::HighPriority => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MysqlInsertPriority {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::LowPriority => {}
Self::Delayed => {}
Self::HighPriority => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8848pub enum MysqlInsertPriority {
8849 LowPriority,
8851 Delayed,
8853 HighPriority,
8855}
8856
8857impl fmt::Display for crate::ast::MysqlInsertPriority {
8858 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8859 use MysqlInsertPriority::*;
8860 match self {
8861 LowPriority => f.write_fmt(format_args!("LOW_PRIORITY"))write!(f, "LOW_PRIORITY"),
8862 Delayed => f.write_fmt(format_args!("DELAYED"))write!(f, "DELAYED"),
8863 HighPriority => f.write_fmt(format_args!("HIGH_PRIORITY"))write!(f, "HIGH_PRIORITY"),
8864 }
8865 }
8866}
8867
8868#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CopySource {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CopySource::Table { table_name: __self_0, columns: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f, "Table",
"table_name", __self_0, "columns", &__self_1),
CopySource::Query(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Query",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CopySource {
#[inline]
fn clone(&self) -> CopySource {
match self {
CopySource::Table { table_name: __self_0, columns: __self_1 } =>
CopySource::Table {
table_name: ::core::clone::Clone::clone(__self_0),
columns: ::core::clone::Clone::clone(__self_1),
},
CopySource::Query(__self_0) =>
CopySource::Query(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CopySource {
#[inline]
fn eq(&self, other: &CopySource) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CopySource::Table { table_name: __self_0, columns: __self_1
}, CopySource::Table {
table_name: __arg1_0, columns: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(CopySource::Query(__self_0), CopySource::Query(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CopySource {
#[inline]
fn partial_cmp(&self, other: &CopySource)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CopySource {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CopySource {
#[inline]
fn cmp(&self, other: &CopySource) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CopySource::Table { table_name: __self_0, columns: __self_1
}, CopySource::Table {
table_name: __arg1_0, columns: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(CopySource::Query(__self_0), CopySource::Query(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CopySource {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CopySource::Table { table_name: __self_0, columns: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
CopySource::Query(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8869#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8870#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CopySource {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Table { table_name, columns } => {
sqlparser::ast::Visit::visit(table_name, visitor)?;
sqlparser::ast::Visit::visit(columns, visitor)?;
}
Self::Query(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CopySource {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Table { table_name, columns } => {
sqlparser::ast::VisitMut::visit(table_name, visitor)?;
sqlparser::ast::VisitMut::visit(columns, visitor)?;
}
Self::Query(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8871pub enum CopySource {
8873 Table {
8875 table_name: ObjectName,
8877 columns: Vec<Ident>,
8880 },
8881 Query(Box<Query>),
8883}
8884
8885#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CopyTarget {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CopyTarget::Stdin =>
::core::fmt::Formatter::write_str(f, "Stdin"),
CopyTarget::Stdout =>
::core::fmt::Formatter::write_str(f, "Stdout"),
CopyTarget::File { filename: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "File",
"filename", &__self_0),
CopyTarget::Program { command: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Program", "command", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CopyTarget {
#[inline]
fn clone(&self) -> CopyTarget {
match self {
CopyTarget::Stdin => CopyTarget::Stdin,
CopyTarget::Stdout => CopyTarget::Stdout,
CopyTarget::File { filename: __self_0 } =>
CopyTarget::File {
filename: ::core::clone::Clone::clone(__self_0),
},
CopyTarget::Program { command: __self_0 } =>
CopyTarget::Program {
command: ::core::clone::Clone::clone(__self_0),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CopyTarget {
#[inline]
fn eq(&self, other: &CopyTarget) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CopyTarget::File { filename: __self_0 }, CopyTarget::File {
filename: __arg1_0 }) => __self_0 == __arg1_0,
(CopyTarget::Program { command: __self_0 },
CopyTarget::Program { command: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CopyTarget {
#[inline]
fn partial_cmp(&self, other: &CopyTarget)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CopyTarget {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CopyTarget {
#[inline]
fn cmp(&self, other: &CopyTarget) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CopyTarget::File { filename: __self_0 }, CopyTarget::File {
filename: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyTarget::Program { command: __self_0 },
CopyTarget::Program { command: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CopyTarget {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CopyTarget::File { filename: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
CopyTarget::Program { command: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
8886#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8887#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CopyTarget {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Stdin => {}
Self::Stdout => {}
Self::File { filename } => {
sqlparser::ast::Visit::visit(filename, visitor)?;
}
Self::Program { command } => {
sqlparser::ast::Visit::visit(command, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CopyTarget {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Stdin => {}
Self::Stdout => {}
Self::File { filename } => {
sqlparser::ast::VisitMut::visit(filename, visitor)?;
}
Self::Program { command } => {
sqlparser::ast::VisitMut::visit(command, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8888pub enum CopyTarget {
8890 Stdin,
8892 Stdout,
8894 File {
8896 filename: String,
8898 },
8899 Program {
8901 command: String,
8903 },
8904}
8905
8906impl fmt::Display for CopyTarget {
8907 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8908 use CopyTarget::*;
8909 match self {
8910 Stdin => f.write_fmt(format_args!("STDIN"))write!(f, "STDIN"),
8911 Stdout => f.write_fmt(format_args!("STDOUT"))write!(f, "STDOUT"),
8912 File { filename } => f.write_fmt(format_args!("\'{0}\'",
value::escape_single_quote_string(filename)))write!(f, "'{}'", value::escape_single_quote_string(filename)),
8913 Program { command } => f.write_fmt(format_args!("PROGRAM \'{0}\'",
value::escape_single_quote_string(command)))write!(
8914 f,
8915 "PROGRAM '{}'",
8916 value::escape_single_quote_string(command)
8917 ),
8918 }
8919 }
8920}
8921
8922#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OnCommit {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
OnCommit::DeleteRows => "DeleteRows",
OnCommit::PreserveRows => "PreserveRows",
OnCommit::Drop => "Drop",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for OnCommit { }Copy, #[automatically_derived]
impl ::core::clone::Clone for OnCommit {
#[inline]
fn clone(&self) -> OnCommit { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OnCommit {
#[inline]
fn eq(&self, other: &OnCommit) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OnCommit {
#[inline]
fn partial_cmp(&self, other: &OnCommit)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OnCommit {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OnCommit {
#[inline]
fn cmp(&self, other: &OnCommit) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OnCommit {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
8923#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8924#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OnCommit {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DeleteRows => {}
Self::PreserveRows => {}
Self::Drop => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OnCommit {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::DeleteRows => {}
Self::PreserveRows => {}
Self::Drop => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8925pub enum OnCommit {
8927 DeleteRows,
8929 PreserveRows,
8931 Drop,
8933}
8934
8935#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CopyOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CopyOption::Format(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Format",
&__self_0),
CopyOption::Freeze(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Freeze",
&__self_0),
CopyOption::Delimiter(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Delimiter", &__self_0),
CopyOption::Null(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Null",
&__self_0),
CopyOption::Header(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Header",
&__self_0),
CopyOption::Quote(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Quote",
&__self_0),
CopyOption::Escape(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Escape",
&__self_0),
CopyOption::ForceQuote(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ForceQuote", &__self_0),
CopyOption::ForceNotNull(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ForceNotNull", &__self_0),
CopyOption::ForceNull(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ForceNull", &__self_0),
CopyOption::Encoding(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Encoding", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CopyOption {
#[inline]
fn clone(&self) -> CopyOption {
match self {
CopyOption::Format(__self_0) =>
CopyOption::Format(::core::clone::Clone::clone(__self_0)),
CopyOption::Freeze(__self_0) =>
CopyOption::Freeze(::core::clone::Clone::clone(__self_0)),
CopyOption::Delimiter(__self_0) =>
CopyOption::Delimiter(::core::clone::Clone::clone(__self_0)),
CopyOption::Null(__self_0) =>
CopyOption::Null(::core::clone::Clone::clone(__self_0)),
CopyOption::Header(__self_0) =>
CopyOption::Header(::core::clone::Clone::clone(__self_0)),
CopyOption::Quote(__self_0) =>
CopyOption::Quote(::core::clone::Clone::clone(__self_0)),
CopyOption::Escape(__self_0) =>
CopyOption::Escape(::core::clone::Clone::clone(__self_0)),
CopyOption::ForceQuote(__self_0) =>
CopyOption::ForceQuote(::core::clone::Clone::clone(__self_0)),
CopyOption::ForceNotNull(__self_0) =>
CopyOption::ForceNotNull(::core::clone::Clone::clone(__self_0)),
CopyOption::ForceNull(__self_0) =>
CopyOption::ForceNull(::core::clone::Clone::clone(__self_0)),
CopyOption::Encoding(__self_0) =>
CopyOption::Encoding(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CopyOption {
#[inline]
fn eq(&self, other: &CopyOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CopyOption::Format(__self_0), CopyOption::Format(__arg1_0))
=> __self_0 == __arg1_0,
(CopyOption::Freeze(__self_0), CopyOption::Freeze(__arg1_0))
=> __self_0 == __arg1_0,
(CopyOption::Delimiter(__self_0),
CopyOption::Delimiter(__arg1_0)) => __self_0 == __arg1_0,
(CopyOption::Null(__self_0), CopyOption::Null(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyOption::Header(__self_0), CopyOption::Header(__arg1_0))
=> __self_0 == __arg1_0,
(CopyOption::Quote(__self_0), CopyOption::Quote(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyOption::Escape(__self_0), CopyOption::Escape(__arg1_0))
=> __self_0 == __arg1_0,
(CopyOption::ForceQuote(__self_0),
CopyOption::ForceQuote(__arg1_0)) => __self_0 == __arg1_0,
(CopyOption::ForceNotNull(__self_0),
CopyOption::ForceNotNull(__arg1_0)) => __self_0 == __arg1_0,
(CopyOption::ForceNull(__self_0),
CopyOption::ForceNull(__arg1_0)) => __self_0 == __arg1_0,
(CopyOption::Encoding(__self_0),
CopyOption::Encoding(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CopyOption {
#[inline]
fn partial_cmp(&self, other: &CopyOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CopyOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<char>;
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CopyOption {
#[inline]
fn cmp(&self, other: &CopyOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CopyOption::Format(__self_0), CopyOption::Format(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Freeze(__self_0), CopyOption::Freeze(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Delimiter(__self_0),
CopyOption::Delimiter(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Null(__self_0), CopyOption::Null(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Header(__self_0), CopyOption::Header(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Quote(__self_0), CopyOption::Quote(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Escape(__self_0), CopyOption::Escape(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::ForceQuote(__self_0),
CopyOption::ForceQuote(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::ForceNotNull(__self_0),
CopyOption::ForceNotNull(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::ForceNull(__self_0),
CopyOption::ForceNull(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyOption::Encoding(__self_0),
CopyOption::Encoding(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CopyOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CopyOption::Format(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Freeze(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Delimiter(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Null(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Header(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Quote(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Escape(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::ForceQuote(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::ForceNotNull(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::ForceNull(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyOption::Encoding(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
8939#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8940#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CopyOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Format(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Freeze(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Delimiter(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Null(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Header(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Quote(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Escape(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ForceQuote(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ForceNotNull(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ForceNull(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Encoding(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CopyOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Format(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Freeze(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Delimiter(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Null(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Header(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Quote(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Escape(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ForceQuote(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ForceNotNull(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ForceNull(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Encoding(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8941pub enum CopyOption {
8942 Format(Ident),
8944 Freeze(bool),
8946 Delimiter(char),
8948 Null(String),
8950 Header(bool),
8952 Quote(char),
8954 Escape(char),
8956 ForceQuote(Vec<Ident>),
8958 ForceNotNull(Vec<Ident>),
8960 ForceNull(Vec<Ident>),
8962 Encoding(String),
8964}
8965
8966impl fmt::Display for CopyOption {
8967 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
8968 use CopyOption::*;
8969 match self {
8970 Format(name) => f.write_fmt(format_args!("FORMAT {0}", name))write!(f, "FORMAT {name}"),
8971 Freeze(true) => f.write_fmt(format_args!("FREEZE"))write!(f, "FREEZE"),
8972 Freeze(false) => f.write_fmt(format_args!("FREEZE FALSE"))write!(f, "FREEZE FALSE"),
8973 Delimiter(char) => f.write_fmt(format_args!("DELIMITER \'{0}\'", char))write!(f, "DELIMITER '{char}'"),
8974 Null(string) => f.write_fmt(format_args!("NULL \'{0}\'",
value::escape_single_quote_string(string)))write!(f, "NULL '{}'", value::escape_single_quote_string(string)),
8975 Header(true) => f.write_fmt(format_args!("HEADER"))write!(f, "HEADER"),
8976 Header(false) => f.write_fmt(format_args!("HEADER FALSE"))write!(f, "HEADER FALSE"),
8977 Quote(char) => f.write_fmt(format_args!("QUOTE \'{0}\'", char))write!(f, "QUOTE '{char}'"),
8978 Escape(char) => f.write_fmt(format_args!("ESCAPE \'{0}\'", char))write!(f, "ESCAPE '{char}'"),
8979 ForceQuote(columns) => f.write_fmt(format_args!("FORCE_QUOTE ({0})",
display_comma_separated(columns)))write!(f, "FORCE_QUOTE ({})", display_comma_separated(columns)),
8980 ForceNotNull(columns) => {
8981 f.write_fmt(format_args!("FORCE_NOT_NULL ({0})",
display_comma_separated(columns)))write!(f, "FORCE_NOT_NULL ({})", display_comma_separated(columns))
8982 }
8983 ForceNull(columns) => f.write_fmt(format_args!("FORCE_NULL ({0})",
display_comma_separated(columns)))write!(f, "FORCE_NULL ({})", display_comma_separated(columns)),
8984 Encoding(name) => f.write_fmt(format_args!("ENCODING \'{0}\'",
value::escape_single_quote_string(name)))write!(f, "ENCODING '{}'", value::escape_single_quote_string(name)),
8985 }
8986 }
8987}
8988
8989#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CopyLegacyOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CopyLegacyOption::AcceptAnyDate =>
::core::fmt::Formatter::write_str(f, "AcceptAnyDate"),
CopyLegacyOption::AcceptInvChars(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AcceptInvChars", &__self_0),
CopyLegacyOption::AddQuotes =>
::core::fmt::Formatter::write_str(f, "AddQuotes"),
CopyLegacyOption::AllowOverwrite =>
::core::fmt::Formatter::write_str(f, "AllowOverwrite"),
CopyLegacyOption::Binary =>
::core::fmt::Formatter::write_str(f, "Binary"),
CopyLegacyOption::BlankAsNull =>
::core::fmt::Formatter::write_str(f, "BlankAsNull"),
CopyLegacyOption::Bzip2 =>
::core::fmt::Formatter::write_str(f, "Bzip2"),
CopyLegacyOption::CleanPath =>
::core::fmt::Formatter::write_str(f, "CleanPath"),
CopyLegacyOption::CompUpdate { preset: __self_0, enabled: __self_1
} =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"CompUpdate", "preset", __self_0, "enabled", &__self_1),
CopyLegacyOption::Csv(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Csv",
&__self_0),
CopyLegacyOption::DateFormat(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"DateFormat", &__self_0),
CopyLegacyOption::Delimiter(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Delimiter", &__self_0),
CopyLegacyOption::EmptyAsNull =>
::core::fmt::Formatter::write_str(f, "EmptyAsNull"),
CopyLegacyOption::Encrypted { auto: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Encrypted", "auto", &__self_0),
CopyLegacyOption::Escape =>
::core::fmt::Formatter::write_str(f, "Escape"),
CopyLegacyOption::Extension(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Extension", &__self_0),
CopyLegacyOption::FixedWidth(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"FixedWidth", &__self_0),
CopyLegacyOption::Gzip =>
::core::fmt::Formatter::write_str(f, "Gzip"),
CopyLegacyOption::Header =>
::core::fmt::Formatter::write_str(f, "Header"),
CopyLegacyOption::IamRole(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IamRole", &__self_0),
CopyLegacyOption::IgnoreHeader(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IgnoreHeader", &__self_0),
CopyLegacyOption::Json(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Json",
&__self_0),
CopyLegacyOption::Manifest { verbose: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"Manifest", "verbose", &__self_0),
CopyLegacyOption::MaxFileSize(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"MaxFileSize", &__self_0),
CopyLegacyOption::Null(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Null",
&__self_0),
CopyLegacyOption::Parallel(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Parallel", &__self_0),
CopyLegacyOption::Parquet =>
::core::fmt::Formatter::write_str(f, "Parquet"),
CopyLegacyOption::PartitionBy(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"PartitionBy", &__self_0),
CopyLegacyOption::Region(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Region",
&__self_0),
CopyLegacyOption::RemoveQuotes =>
::core::fmt::Formatter::write_str(f, "RemoveQuotes"),
CopyLegacyOption::RowGroupSize(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"RowGroupSize", &__self_0),
CopyLegacyOption::StatUpdate(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"StatUpdate", &__self_0),
CopyLegacyOption::TimeFormat(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"TimeFormat", &__self_0),
CopyLegacyOption::TruncateColumns =>
::core::fmt::Formatter::write_str(f, "TruncateColumns"),
CopyLegacyOption::Zstd =>
::core::fmt::Formatter::write_str(f, "Zstd"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CopyLegacyOption {
#[inline]
fn clone(&self) -> CopyLegacyOption {
match self {
CopyLegacyOption::AcceptAnyDate =>
CopyLegacyOption::AcceptAnyDate,
CopyLegacyOption::AcceptInvChars(__self_0) =>
CopyLegacyOption::AcceptInvChars(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::AddQuotes => CopyLegacyOption::AddQuotes,
CopyLegacyOption::AllowOverwrite =>
CopyLegacyOption::AllowOverwrite,
CopyLegacyOption::Binary => CopyLegacyOption::Binary,
CopyLegacyOption::BlankAsNull => CopyLegacyOption::BlankAsNull,
CopyLegacyOption::Bzip2 => CopyLegacyOption::Bzip2,
CopyLegacyOption::CleanPath => CopyLegacyOption::CleanPath,
CopyLegacyOption::CompUpdate { preset: __self_0, enabled: __self_1
} =>
CopyLegacyOption::CompUpdate {
preset: ::core::clone::Clone::clone(__self_0),
enabled: ::core::clone::Clone::clone(__self_1),
},
CopyLegacyOption::Csv(__self_0) =>
CopyLegacyOption::Csv(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::DateFormat(__self_0) =>
CopyLegacyOption::DateFormat(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Delimiter(__self_0) =>
CopyLegacyOption::Delimiter(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::EmptyAsNull => CopyLegacyOption::EmptyAsNull,
CopyLegacyOption::Encrypted { auto: __self_0 } =>
CopyLegacyOption::Encrypted {
auto: ::core::clone::Clone::clone(__self_0),
},
CopyLegacyOption::Escape => CopyLegacyOption::Escape,
CopyLegacyOption::Extension(__self_0) =>
CopyLegacyOption::Extension(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::FixedWidth(__self_0) =>
CopyLegacyOption::FixedWidth(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Gzip => CopyLegacyOption::Gzip,
CopyLegacyOption::Header => CopyLegacyOption::Header,
CopyLegacyOption::IamRole(__self_0) =>
CopyLegacyOption::IamRole(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::IgnoreHeader(__self_0) =>
CopyLegacyOption::IgnoreHeader(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Json(__self_0) =>
CopyLegacyOption::Json(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Manifest { verbose: __self_0 } =>
CopyLegacyOption::Manifest {
verbose: ::core::clone::Clone::clone(__self_0),
},
CopyLegacyOption::MaxFileSize(__self_0) =>
CopyLegacyOption::MaxFileSize(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Null(__self_0) =>
CopyLegacyOption::Null(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Parallel(__self_0) =>
CopyLegacyOption::Parallel(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Parquet => CopyLegacyOption::Parquet,
CopyLegacyOption::PartitionBy(__self_0) =>
CopyLegacyOption::PartitionBy(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::Region(__self_0) =>
CopyLegacyOption::Region(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::RemoveQuotes => CopyLegacyOption::RemoveQuotes,
CopyLegacyOption::RowGroupSize(__self_0) =>
CopyLegacyOption::RowGroupSize(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::StatUpdate(__self_0) =>
CopyLegacyOption::StatUpdate(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::TimeFormat(__self_0) =>
CopyLegacyOption::TimeFormat(::core::clone::Clone::clone(__self_0)),
CopyLegacyOption::TruncateColumns =>
CopyLegacyOption::TruncateColumns,
CopyLegacyOption::Zstd => CopyLegacyOption::Zstd,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CopyLegacyOption {
#[inline]
fn eq(&self, other: &CopyLegacyOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CopyLegacyOption::AcceptInvChars(__self_0),
CopyLegacyOption::AcceptInvChars(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::CompUpdate {
preset: __self_0, enabled: __self_1 },
CopyLegacyOption::CompUpdate {
preset: __arg1_0, enabled: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(CopyLegacyOption::Csv(__self_0),
CopyLegacyOption::Csv(__arg1_0)) => __self_0 == __arg1_0,
(CopyLegacyOption::DateFormat(__self_0),
CopyLegacyOption::DateFormat(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::Delimiter(__self_0),
CopyLegacyOption::Delimiter(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::Encrypted { auto: __self_0 },
CopyLegacyOption::Encrypted { auto: __arg1_0 }) =>
__self_0 == __arg1_0,
(CopyLegacyOption::Extension(__self_0),
CopyLegacyOption::Extension(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::FixedWidth(__self_0),
CopyLegacyOption::FixedWidth(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::IamRole(__self_0),
CopyLegacyOption::IamRole(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::IgnoreHeader(__self_0),
CopyLegacyOption::IgnoreHeader(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::Json(__self_0),
CopyLegacyOption::Json(__arg1_0)) => __self_0 == __arg1_0,
(CopyLegacyOption::Manifest { verbose: __self_0 },
CopyLegacyOption::Manifest { verbose: __arg1_0 }) =>
__self_0 == __arg1_0,
(CopyLegacyOption::MaxFileSize(__self_0),
CopyLegacyOption::MaxFileSize(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::Null(__self_0),
CopyLegacyOption::Null(__arg1_0)) => __self_0 == __arg1_0,
(CopyLegacyOption::Parallel(__self_0),
CopyLegacyOption::Parallel(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::PartitionBy(__self_0),
CopyLegacyOption::PartitionBy(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::Region(__self_0),
CopyLegacyOption::Region(__arg1_0)) => __self_0 == __arg1_0,
(CopyLegacyOption::RowGroupSize(__self_0),
CopyLegacyOption::RowGroupSize(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::StatUpdate(__self_0),
CopyLegacyOption::StatUpdate(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyOption::TimeFormat(__self_0),
CopyLegacyOption::TimeFormat(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CopyLegacyOption {
#[inline]
fn partial_cmp(&self, other: &CopyLegacyOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CopyLegacyOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Vec<CopyLegacyCsvOption>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<char>;
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<IamRoleKind>;
let _: ::core::cmp::AssertParamIsEq<u64>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
let _: ::core::cmp::AssertParamIsEq<FileSize>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<UnloadPartitionBy>;
let _: ::core::cmp::AssertParamIsEq<Option<bool>>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CopyLegacyOption {
#[inline]
fn cmp(&self, other: &CopyLegacyOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CopyLegacyOption::AcceptInvChars(__self_0),
CopyLegacyOption::AcceptInvChars(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::CompUpdate {
preset: __self_0, enabled: __self_1 },
CopyLegacyOption::CompUpdate {
preset: __arg1_0, enabled: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(CopyLegacyOption::Csv(__self_0),
CopyLegacyOption::Csv(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::DateFormat(__self_0),
CopyLegacyOption::DateFormat(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Delimiter(__self_0),
CopyLegacyOption::Delimiter(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Encrypted { auto: __self_0 },
CopyLegacyOption::Encrypted { auto: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Extension(__self_0),
CopyLegacyOption::Extension(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::FixedWidth(__self_0),
CopyLegacyOption::FixedWidth(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::IamRole(__self_0),
CopyLegacyOption::IamRole(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::IgnoreHeader(__self_0),
CopyLegacyOption::IgnoreHeader(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Json(__self_0),
CopyLegacyOption::Json(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Manifest { verbose: __self_0 },
CopyLegacyOption::Manifest { verbose: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::MaxFileSize(__self_0),
CopyLegacyOption::MaxFileSize(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Null(__self_0),
CopyLegacyOption::Null(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Parallel(__self_0),
CopyLegacyOption::Parallel(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::PartitionBy(__self_0),
CopyLegacyOption::PartitionBy(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::Region(__self_0),
CopyLegacyOption::Region(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::RowGroupSize(__self_0),
CopyLegacyOption::RowGroupSize(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::StatUpdate(__self_0),
CopyLegacyOption::StatUpdate(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyOption::TimeFormat(__self_0),
CopyLegacyOption::TimeFormat(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CopyLegacyOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CopyLegacyOption::AcceptInvChars(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::CompUpdate { preset: __self_0, enabled: __self_1
} => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
CopyLegacyOption::Csv(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::DateFormat(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Delimiter(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Encrypted { auto: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Extension(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::FixedWidth(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::IamRole(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::IgnoreHeader(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Json(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Manifest { verbose: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::MaxFileSize(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Null(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Parallel(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::PartitionBy(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::Region(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::RowGroupSize(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::StatUpdate(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyOption::TimeFormat(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
8994#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
8995#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CopyLegacyOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AcceptAnyDate => {}
Self::AcceptInvChars(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AddQuotes => {}
Self::AllowOverwrite => {}
Self::Binary => {}
Self::BlankAsNull => {}
Self::Bzip2 => {}
Self::CleanPath => {}
Self::CompUpdate { preset, enabled } => {
sqlparser::ast::Visit::visit(preset, visitor)?;
sqlparser::ast::Visit::visit(enabled, visitor)?;
}
Self::Csv(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::DateFormat(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Delimiter(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::EmptyAsNull => {}
Self::Encrypted { auto } => {
sqlparser::ast::Visit::visit(auto, visitor)?;
}
Self::Escape => {}
Self::Extension(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::FixedWidth(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Gzip => {}
Self::Header => {}
Self::IamRole(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IgnoreHeader(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Json(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Manifest { verbose } => {
sqlparser::ast::Visit::visit(verbose, visitor)?;
}
Self::MaxFileSize(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Null(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Parallel(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Parquet => {}
Self::PartitionBy(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Region(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::RemoveQuotes => {}
Self::RowGroupSize(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::StatUpdate(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::TimeFormat(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::TruncateColumns => {}
Self::Zstd => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CopyLegacyOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AcceptAnyDate => {}
Self::AcceptInvChars(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AddQuotes => {}
Self::AllowOverwrite => {}
Self::Binary => {}
Self::BlankAsNull => {}
Self::Bzip2 => {}
Self::CleanPath => {}
Self::CompUpdate { preset, enabled } => {
sqlparser::ast::VisitMut::visit(preset, visitor)?;
sqlparser::ast::VisitMut::visit(enabled, visitor)?;
}
Self::Csv(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::DateFormat(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Delimiter(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::EmptyAsNull => {}
Self::Encrypted { auto } => {
sqlparser::ast::VisitMut::visit(auto, visitor)?;
}
Self::Escape => {}
Self::Extension(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::FixedWidth(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Gzip => {}
Self::Header => {}
Self::IamRole(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IgnoreHeader(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Json(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Manifest { verbose } => {
sqlparser::ast::VisitMut::visit(verbose, visitor)?;
}
Self::MaxFileSize(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Null(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Parallel(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Parquet => {}
Self::PartitionBy(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Region(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::RemoveQuotes => {}
Self::RowGroupSize(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::StatUpdate(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::TimeFormat(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::TruncateColumns => {}
Self::Zstd => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
8996pub enum CopyLegacyOption {
8997 AcceptAnyDate,
8999 AcceptInvChars(Option<String>),
9001 AddQuotes,
9003 AllowOverwrite,
9005 Binary,
9007 BlankAsNull,
9009 Bzip2,
9011 CleanPath,
9013 CompUpdate {
9015 preset: bool,
9017 enabled: Option<bool>,
9019 },
9020 Csv(Vec<CopyLegacyCsvOption>),
9022 DateFormat(Option<String>),
9024 Delimiter(char),
9026 EmptyAsNull,
9028 Encrypted {
9030 auto: bool,
9032 },
9033 Escape,
9035 Extension(String),
9037 FixedWidth(String),
9039 Gzip,
9041 Header,
9043 IamRole(IamRoleKind),
9045 IgnoreHeader(u64),
9047 Json(Option<String>),
9049 Manifest {
9051 verbose: bool,
9053 },
9054 MaxFileSize(FileSize),
9056 Null(String),
9058 Parallel(Option<bool>),
9060 Parquet,
9062 PartitionBy(UnloadPartitionBy),
9064 Region(String),
9066 RemoveQuotes,
9068 RowGroupSize(FileSize),
9070 StatUpdate(Option<bool>),
9072 TimeFormat(Option<String>),
9074 TruncateColumns,
9076 Zstd,
9078}
9079
9080impl fmt::Display for CopyLegacyOption {
9081 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9082 use CopyLegacyOption::*;
9083 match self {
9084 AcceptAnyDate => f.write_fmt(format_args!("ACCEPTANYDATE"))write!(f, "ACCEPTANYDATE"),
9085 AcceptInvChars(ch) => {
9086 f.write_fmt(format_args!("ACCEPTINVCHARS"))write!(f, "ACCEPTINVCHARS")?;
9087 if let Some(ch) = ch {
9088 f.write_fmt(format_args!(" \'{0}\'", value::escape_single_quote_string(ch)))write!(f, " '{}'", value::escape_single_quote_string(ch))?;
9089 }
9090 Ok(())
9091 }
9092 AddQuotes => f.write_fmt(format_args!("ADDQUOTES"))write!(f, "ADDQUOTES"),
9093 AllowOverwrite => f.write_fmt(format_args!("ALLOWOVERWRITE"))write!(f, "ALLOWOVERWRITE"),
9094 Binary => f.write_fmt(format_args!("BINARY"))write!(f, "BINARY"),
9095 BlankAsNull => f.write_fmt(format_args!("BLANKSASNULL"))write!(f, "BLANKSASNULL"),
9096 Bzip2 => f.write_fmt(format_args!("BZIP2"))write!(f, "BZIP2"),
9097 CleanPath => f.write_fmt(format_args!("CLEANPATH"))write!(f, "CLEANPATH"),
9098 CompUpdate { preset, enabled } => {
9099 f.write_fmt(format_args!("COMPUPDATE"))write!(f, "COMPUPDATE")?;
9100 if *preset {
9101 f.write_fmt(format_args!(" PRESET"))write!(f, " PRESET")?;
9102 } else if let Some(enabled) = enabled {
9103 f.write_fmt(format_args!("{0}",
match enabled { true => " TRUE", false => " FALSE", }))write!(
9104 f,
9105 "{}",
9106 match enabled {
9107 true => " TRUE",
9108 false => " FALSE",
9109 }
9110 )?;
9111 }
9112 Ok(())
9113 }
9114 Csv(opts) => {
9115 f.write_fmt(format_args!("CSV"))write!(f, "CSV")?;
9116 if !opts.is_empty() {
9117 f.write_fmt(format_args!(" {0}", display_separated(opts, " ")))write!(f, " {}", display_separated(opts, " "))?;
9118 }
9119 Ok(())
9120 }
9121 DateFormat(fmt) => {
9122 f.write_fmt(format_args!("DATEFORMAT"))write!(f, "DATEFORMAT")?;
9123 if let Some(fmt) = fmt {
9124 f.write_fmt(format_args!(" \'{0}\'", value::escape_single_quote_string(fmt)))write!(f, " '{}'", value::escape_single_quote_string(fmt))?;
9125 }
9126 Ok(())
9127 }
9128 Delimiter(char) => f.write_fmt(format_args!("DELIMITER \'{0}\'", char))write!(f, "DELIMITER '{char}'"),
9129 EmptyAsNull => f.write_fmt(format_args!("EMPTYASNULL"))write!(f, "EMPTYASNULL"),
9130 Encrypted { auto } => f.write_fmt(format_args!("ENCRYPTED{0}", if *auto { " AUTO" } else { "" }))write!(f, "ENCRYPTED{}", if *auto { " AUTO" } else { "" }),
9131 Escape => f.write_fmt(format_args!("ESCAPE"))write!(f, "ESCAPE"),
9132 Extension(ext) => f.write_fmt(format_args!("EXTENSION \'{0}\'",
value::escape_single_quote_string(ext)))write!(f, "EXTENSION '{}'", value::escape_single_quote_string(ext)),
9133 FixedWidth(spec) => f.write_fmt(format_args!("FIXEDWIDTH \'{0}\'",
value::escape_single_quote_string(spec)))write!(
9134 f,
9135 "FIXEDWIDTH '{}'",
9136 value::escape_single_quote_string(spec)
9137 ),
9138 Gzip => f.write_fmt(format_args!("GZIP"))write!(f, "GZIP"),
9139 Header => f.write_fmt(format_args!("HEADER"))write!(f, "HEADER"),
9140 IamRole(role) => f.write_fmt(format_args!("IAM_ROLE {0}", role))write!(f, "IAM_ROLE {role}"),
9141 IgnoreHeader(num_rows) => f.write_fmt(format_args!("IGNOREHEADER {0}", num_rows))write!(f, "IGNOREHEADER {num_rows}"),
9142 Json(opt) => {
9143 f.write_fmt(format_args!("JSON"))write!(f, "JSON")?;
9144 if let Some(opt) = opt {
9145 f.write_fmt(format_args!(" AS \'{0}\'",
value::escape_single_quote_string(opt)))write!(f, " AS '{}'", value::escape_single_quote_string(opt))?;
9146 }
9147 Ok(())
9148 }
9149 Manifest { verbose } => f.write_fmt(format_args!("MANIFEST{0}",
if *verbose { " VERBOSE" } else { "" }))write!(f, "MANIFEST{}", if *verbose { " VERBOSE" } else { "" }),
9150 MaxFileSize(file_size) => f.write_fmt(format_args!("MAXFILESIZE {0}", file_size))write!(f, "MAXFILESIZE {file_size}"),
9151 Null(string) => f.write_fmt(format_args!("NULL \'{0}\'",
value::escape_single_quote_string(string)))write!(f, "NULL '{}'", value::escape_single_quote_string(string)),
9152 Parallel(enabled) => {
9153 f.write_fmt(format_args!("PARALLEL{0}",
match enabled {
Some(true) => " TRUE",
Some(false) => " FALSE",
_ => "",
}))write!(
9154 f,
9155 "PARALLEL{}",
9156 match enabled {
9157 Some(true) => " TRUE",
9158 Some(false) => " FALSE",
9159 _ => "",
9160 }
9161 )
9162 }
9163 Parquet => f.write_fmt(format_args!("PARQUET"))write!(f, "PARQUET"),
9164 PartitionBy(p) => f.write_fmt(format_args!("{0}", p))write!(f, "{p}"),
9165 Region(region) => f.write_fmt(format_args!("REGION \'{0}\'",
value::escape_single_quote_string(region)))write!(f, "REGION '{}'", value::escape_single_quote_string(region)),
9166 RemoveQuotes => f.write_fmt(format_args!("REMOVEQUOTES"))write!(f, "REMOVEQUOTES"),
9167 RowGroupSize(file_size) => f.write_fmt(format_args!("ROWGROUPSIZE {0}", file_size))write!(f, "ROWGROUPSIZE {file_size}"),
9168 StatUpdate(enabled) => {
9169 f.write_fmt(format_args!("STATUPDATE{0}",
match enabled {
Some(true) => " TRUE",
Some(false) => " FALSE",
_ => "",
}))write!(
9170 f,
9171 "STATUPDATE{}",
9172 match enabled {
9173 Some(true) => " TRUE",
9174 Some(false) => " FALSE",
9175 _ => "",
9176 }
9177 )
9178 }
9179 TimeFormat(fmt) => {
9180 f.write_fmt(format_args!("TIMEFORMAT"))write!(f, "TIMEFORMAT")?;
9181 if let Some(fmt) = fmt {
9182 f.write_fmt(format_args!(" \'{0}\'", value::escape_single_quote_string(fmt)))write!(f, " '{}'", value::escape_single_quote_string(fmt))?;
9183 }
9184 Ok(())
9185 }
9186 TruncateColumns => f.write_fmt(format_args!("TRUNCATECOLUMNS"))write!(f, "TRUNCATECOLUMNS"),
9187 Zstd => f.write_fmt(format_args!("ZSTD"))write!(f, "ZSTD"),
9188 }
9189 }
9190}
9191
9192#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FileSize {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "FileSize",
"size", &self.size, "unit", &&self.unit)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FileSize {
#[inline]
fn clone(&self) -> FileSize {
FileSize {
size: ::core::clone::Clone::clone(&self.size),
unit: ::core::clone::Clone::clone(&self.unit),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FileSize {
#[inline]
fn eq(&self, other: &FileSize) -> bool {
self.size == other.size && self.unit == other.unit
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FileSize {
#[inline]
fn partial_cmp(&self, other: &FileSize)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FileSize {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Value>;
let _: ::core::cmp::AssertParamIsEq<Option<FileSizeUnit>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FileSize {
#[inline]
fn cmp(&self, other: &FileSize) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.size, &other.size) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.unit, &other.unit),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FileSize {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.size, state);
::core::hash::Hash::hash(&self.unit, state)
}
}Hash)]
9196#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9197#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FileSize {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.size, visitor)?;
sqlparser::ast::Visit::visit(&self.unit, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FileSize {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.size, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.unit, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9198pub struct FileSize {
9199 pub size: Value,
9201 pub unit: Option<FileSizeUnit>,
9203}
9204
9205impl fmt::Display for FileSize {
9206 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9207 f.write_fmt(format_args!("{0}", self.size))write!(f, "{}", self.size)?;
9208 if let Some(unit) = &self.unit {
9209 f.write_fmt(format_args!(" {0}", unit))write!(f, " {unit}")?;
9210 }
9211 Ok(())
9212 }
9213}
9214
9215#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FileSizeUnit {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FileSizeUnit::MB => "MB",
FileSizeUnit::GB => "GB",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FileSizeUnit {
#[inline]
fn clone(&self) -> FileSizeUnit {
match self {
FileSizeUnit::MB => FileSizeUnit::MB,
FileSizeUnit::GB => FileSizeUnit::GB,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FileSizeUnit {
#[inline]
fn eq(&self, other: &FileSizeUnit) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FileSizeUnit {
#[inline]
fn partial_cmp(&self, other: &FileSizeUnit)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FileSizeUnit {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FileSizeUnit {
#[inline]
fn cmp(&self, other: &FileSizeUnit) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FileSizeUnit {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9217#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9218#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FileSizeUnit {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::MB => {} Self::GB => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FileSizeUnit {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::MB => {} Self::GB => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9219pub enum FileSizeUnit {
9220 MB,
9222 GB,
9224}
9225
9226impl fmt::Display for FileSizeUnit {
9227 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9228 match self {
9229 FileSizeUnit::MB => f.write_fmt(format_args!("MB"))write!(f, "MB"),
9230 FileSizeUnit::GB => f.write_fmt(format_args!("GB"))write!(f, "GB"),
9231 }
9232 }
9233}
9234
9235#[derive(#[automatically_derived]
impl ::core::fmt::Debug for UnloadPartitionBy {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"UnloadPartitionBy", "columns", &self.columns, "include",
&&self.include)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for UnloadPartitionBy {
#[inline]
fn clone(&self) -> UnloadPartitionBy {
UnloadPartitionBy {
columns: ::core::clone::Clone::clone(&self.columns),
include: ::core::clone::Clone::clone(&self.include),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for UnloadPartitionBy {
#[inline]
fn eq(&self, other: &UnloadPartitionBy) -> bool {
self.include == other.include && self.columns == other.columns
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for UnloadPartitionBy {
#[inline]
fn partial_cmp(&self, other: &UnloadPartitionBy)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for UnloadPartitionBy {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for UnloadPartitionBy {
#[inline]
fn cmp(&self, other: &UnloadPartitionBy) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.columns, &other.columns) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.include, &other.include),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for UnloadPartitionBy {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.columns, state);
::core::hash::Hash::hash(&self.include, state)
}
}Hash)]
9241#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9242#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for UnloadPartitionBy {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.columns, visitor)?;
sqlparser::ast::Visit::visit(&self.include, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for UnloadPartitionBy {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.columns,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.include,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9243pub struct UnloadPartitionBy {
9244 pub columns: Vec<Ident>,
9246 pub include: bool,
9248}
9249
9250impl fmt::Display for UnloadPartitionBy {
9251 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9252 f.write_fmt(format_args!("PARTITION BY ({0}){1}",
display_comma_separated(&self.columns),
if self.include { " INCLUDE" } else { "" }))write!(
9253 f,
9254 "PARTITION BY ({}){}",
9255 display_comma_separated(&self.columns),
9256 if self.include { " INCLUDE" } else { "" }
9257 )
9258 }
9259}
9260
9261#[derive(#[automatically_derived]
impl ::core::fmt::Debug for IamRoleKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
IamRoleKind::Default =>
::core::fmt::Formatter::write_str(f, "Default"),
IamRoleKind::Arn(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Arn",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for IamRoleKind {
#[inline]
fn clone(&self) -> IamRoleKind {
match self {
IamRoleKind::Default => IamRoleKind::Default,
IamRoleKind::Arn(__self_0) =>
IamRoleKind::Arn(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for IamRoleKind {
#[inline]
fn eq(&self, other: &IamRoleKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(IamRoleKind::Arn(__self_0), IamRoleKind::Arn(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for IamRoleKind {
#[inline]
fn partial_cmp(&self, other: &IamRoleKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for IamRoleKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for IamRoleKind {
#[inline]
fn cmp(&self, other: &IamRoleKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(IamRoleKind::Arn(__self_0), IamRoleKind::Arn(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for IamRoleKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
IamRoleKind::Arn(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
9265#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9266#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for IamRoleKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Default => {}
Self::Arn(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for IamRoleKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Default => {}
Self::Arn(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9267pub enum IamRoleKind {
9268 Default,
9270 Arn(String),
9272}
9273
9274impl fmt::Display for IamRoleKind {
9275 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9276 match self {
9277 IamRoleKind::Default => f.write_fmt(format_args!("DEFAULT"))write!(f, "DEFAULT"),
9278 IamRoleKind::Arn(arn) => f.write_fmt(format_args!("\'{0}\'", arn))write!(f, "'{arn}'"),
9279 }
9280 }
9281}
9282
9283#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CopyLegacyCsvOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CopyLegacyCsvOption::Header =>
::core::fmt::Formatter::write_str(f, "Header"),
CopyLegacyCsvOption::Quote(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Quote",
&__self_0),
CopyLegacyCsvOption::Escape(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Escape",
&__self_0),
CopyLegacyCsvOption::ForceQuote(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ForceQuote", &__self_0),
CopyLegacyCsvOption::ForceNotNull(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ForceNotNull", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CopyLegacyCsvOption {
#[inline]
fn clone(&self) -> CopyLegacyCsvOption {
match self {
CopyLegacyCsvOption::Header => CopyLegacyCsvOption::Header,
CopyLegacyCsvOption::Quote(__self_0) =>
CopyLegacyCsvOption::Quote(::core::clone::Clone::clone(__self_0)),
CopyLegacyCsvOption::Escape(__self_0) =>
CopyLegacyCsvOption::Escape(::core::clone::Clone::clone(__self_0)),
CopyLegacyCsvOption::ForceQuote(__self_0) =>
CopyLegacyCsvOption::ForceQuote(::core::clone::Clone::clone(__self_0)),
CopyLegacyCsvOption::ForceNotNull(__self_0) =>
CopyLegacyCsvOption::ForceNotNull(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CopyLegacyCsvOption {
#[inline]
fn eq(&self, other: &CopyLegacyCsvOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CopyLegacyCsvOption::Quote(__self_0),
CopyLegacyCsvOption::Quote(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyCsvOption::Escape(__self_0),
CopyLegacyCsvOption::Escape(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyCsvOption::ForceQuote(__self_0),
CopyLegacyCsvOption::ForceQuote(__arg1_0)) =>
__self_0 == __arg1_0,
(CopyLegacyCsvOption::ForceNotNull(__self_0),
CopyLegacyCsvOption::ForceNotNull(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CopyLegacyCsvOption {
#[inline]
fn partial_cmp(&self, other: &CopyLegacyCsvOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CopyLegacyCsvOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<char>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CopyLegacyCsvOption {
#[inline]
fn cmp(&self, other: &CopyLegacyCsvOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CopyLegacyCsvOption::Quote(__self_0),
CopyLegacyCsvOption::Quote(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyCsvOption::Escape(__self_0),
CopyLegacyCsvOption::Escape(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyCsvOption::ForceQuote(__self_0),
CopyLegacyCsvOption::ForceQuote(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CopyLegacyCsvOption::ForceNotNull(__self_0),
CopyLegacyCsvOption::ForceNotNull(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CopyLegacyCsvOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CopyLegacyCsvOption::Quote(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyCsvOption::Escape(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyCsvOption::ForceQuote(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CopyLegacyCsvOption::ForceNotNull(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
9287#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9288#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CopyLegacyCsvOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Header => {}
Self::Quote(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Escape(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ForceQuote(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::ForceNotNull(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CopyLegacyCsvOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Header => {}
Self::Quote(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Escape(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ForceQuote(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::ForceNotNull(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9289pub enum CopyLegacyCsvOption {
9290 Header,
9292 Quote(char),
9294 Escape(char),
9296 ForceQuote(Vec<Ident>),
9298 ForceNotNull(Vec<Ident>),
9300}
9301
9302impl fmt::Display for CopyLegacyCsvOption {
9303 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9304 use CopyLegacyCsvOption::*;
9305 match self {
9306 Header => f.write_fmt(format_args!("HEADER"))write!(f, "HEADER"),
9307 Quote(char) => f.write_fmt(format_args!("QUOTE \'{0}\'", char))write!(f, "QUOTE '{char}'"),
9308 Escape(char) => f.write_fmt(format_args!("ESCAPE \'{0}\'", char))write!(f, "ESCAPE '{char}'"),
9309 ForceQuote(columns) => f.write_fmt(format_args!("FORCE QUOTE {0}", display_comma_separated(columns)))write!(f, "FORCE QUOTE {}", display_comma_separated(columns)),
9310 ForceNotNull(columns) => {
9311 f.write_fmt(format_args!("FORCE NOT NULL {0}",
display_comma_separated(columns)))write!(f, "FORCE NOT NULL {}", display_comma_separated(columns))
9312 }
9313 }
9314 }
9315}
9316
9317#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DiscardObject {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
DiscardObject::ALL => "ALL",
DiscardObject::PLANS => "PLANS",
DiscardObject::SEQUENCES => "SEQUENCES",
DiscardObject::TEMP => "TEMP",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for DiscardObject { }Copy, #[automatically_derived]
impl ::core::clone::Clone for DiscardObject {
#[inline]
fn clone(&self) -> DiscardObject { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DiscardObject {
#[inline]
fn eq(&self, other: &DiscardObject) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DiscardObject {
#[inline]
fn partial_cmp(&self, other: &DiscardObject)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DiscardObject {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DiscardObject {
#[inline]
fn cmp(&self, other: &DiscardObject) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DiscardObject {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9319#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9320#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for DiscardObject {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ALL => {}
Self::PLANS => {}
Self::SEQUENCES => {}
Self::TEMP => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for DiscardObject {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ALL => {}
Self::PLANS => {}
Self::SEQUENCES => {}
Self::TEMP => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9321pub enum DiscardObject {
9322 ALL,
9324 PLANS,
9326 SEQUENCES,
9328 TEMP,
9330}
9331
9332impl fmt::Display for DiscardObject {
9333 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9334 match self {
9335 DiscardObject::ALL => f.write_str("ALL"),
9336 DiscardObject::PLANS => f.write_str("PLANS"),
9337 DiscardObject::SEQUENCES => f.write_str("SEQUENCES"),
9338 DiscardObject::TEMP => f.write_str("TEMP"),
9339 }
9340 }
9341}
9342
9343#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FlushType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FlushType::BinaryLogs => "BinaryLogs",
FlushType::EngineLogs => "EngineLogs",
FlushType::ErrorLogs => "ErrorLogs",
FlushType::GeneralLogs => "GeneralLogs",
FlushType::Hosts => "Hosts",
FlushType::Logs => "Logs",
FlushType::Privileges => "Privileges",
FlushType::OptimizerCosts => "OptimizerCosts",
FlushType::RelayLogs => "RelayLogs",
FlushType::SlowLogs => "SlowLogs",
FlushType::Status => "Status",
FlushType::UserResources => "UserResources",
FlushType::Tables => "Tables",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for FlushType { }Copy, #[automatically_derived]
impl ::core::clone::Clone for FlushType {
#[inline]
fn clone(&self) -> FlushType { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FlushType {
#[inline]
fn eq(&self, other: &FlushType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FlushType {
#[inline]
fn partial_cmp(&self, other: &FlushType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FlushType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FlushType {
#[inline]
fn cmp(&self, other: &FlushType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FlushType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9345#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9346#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FlushType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::BinaryLogs => {}
Self::EngineLogs => {}
Self::ErrorLogs => {}
Self::GeneralLogs => {}
Self::Hosts => {}
Self::Logs => {}
Self::Privileges => {}
Self::OptimizerCosts => {}
Self::RelayLogs => {}
Self::SlowLogs => {}
Self::Status => {}
Self::UserResources => {}
Self::Tables => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FlushType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::BinaryLogs => {}
Self::EngineLogs => {}
Self::ErrorLogs => {}
Self::GeneralLogs => {}
Self::Hosts => {}
Self::Logs => {}
Self::Privileges => {}
Self::OptimizerCosts => {}
Self::RelayLogs => {}
Self::SlowLogs => {}
Self::Status => {}
Self::UserResources => {}
Self::Tables => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9347pub enum FlushType {
9348 BinaryLogs,
9350 EngineLogs,
9352 ErrorLogs,
9354 GeneralLogs,
9356 Hosts,
9358 Logs,
9360 Privileges,
9362 OptimizerCosts,
9364 RelayLogs,
9366 SlowLogs,
9368 Status,
9370 UserResources,
9372 Tables,
9374}
9375
9376impl fmt::Display for FlushType {
9377 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9378 match self {
9379 FlushType::BinaryLogs => f.write_str("BINARY LOGS"),
9380 FlushType::EngineLogs => f.write_str("ENGINE LOGS"),
9381 FlushType::ErrorLogs => f.write_str("ERROR LOGS"),
9382 FlushType::GeneralLogs => f.write_str("GENERAL LOGS"),
9383 FlushType::Hosts => f.write_str("HOSTS"),
9384 FlushType::Logs => f.write_str("LOGS"),
9385 FlushType::Privileges => f.write_str("PRIVILEGES"),
9386 FlushType::OptimizerCosts => f.write_str("OPTIMIZER_COSTS"),
9387 FlushType::RelayLogs => f.write_str("RELAY LOGS"),
9388 FlushType::SlowLogs => f.write_str("SLOW LOGS"),
9389 FlushType::Status => f.write_str("STATUS"),
9390 FlushType::UserResources => f.write_str("USER_RESOURCES"),
9391 FlushType::Tables => f.write_str("TABLES"),
9392 }
9393 }
9394}
9395
9396#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FlushLocation {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FlushLocation::NoWriteToBinlog => "NoWriteToBinlog",
FlushLocation::Local => "Local",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for FlushLocation { }Copy, #[automatically_derived]
impl ::core::clone::Clone for FlushLocation {
#[inline]
fn clone(&self) -> FlushLocation { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FlushLocation {
#[inline]
fn eq(&self, other: &FlushLocation) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FlushLocation {
#[inline]
fn partial_cmp(&self, other: &FlushLocation)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FlushLocation {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FlushLocation {
#[inline]
fn cmp(&self, other: &FlushLocation) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FlushLocation {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9398#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9399#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FlushLocation {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::NoWriteToBinlog => {} Self::Local => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FlushLocation {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::NoWriteToBinlog => {} Self::Local => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9400pub enum FlushLocation {
9401 NoWriteToBinlog,
9403 Local,
9405}
9406
9407impl fmt::Display for FlushLocation {
9408 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9409 match self {
9410 FlushLocation::NoWriteToBinlog => f.write_str("NO_WRITE_TO_BINLOG"),
9411 FlushLocation::Local => f.write_str("LOCAL"),
9412 }
9413 }
9414}
9415
9416#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ContextModifier {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ContextModifier::Local => "Local",
ContextModifier::Session => "Session",
ContextModifier::Global => "Global",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for ContextModifier { }Copy, #[automatically_derived]
impl ::core::clone::Clone for ContextModifier {
#[inline]
fn clone(&self) -> ContextModifier { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ContextModifier {
#[inline]
fn eq(&self, other: &ContextModifier) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ContextModifier {
#[inline]
fn partial_cmp(&self, other: &ContextModifier)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ContextModifier {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ContextModifier {
#[inline]
fn cmp(&self, other: &ContextModifier) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ContextModifier {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9418#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9419#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ContextModifier {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Local => {}
Self::Session => {}
Self::Global => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ContextModifier {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Local => {}
Self::Session => {}
Self::Global => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9420pub enum ContextModifier {
9421 Local,
9423 Session,
9425 Global,
9427}
9428
9429impl fmt::Display for ContextModifier {
9430 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9431 match self {
9432 Self::Local => {
9433 f.write_fmt(format_args!("LOCAL "))write!(f, "LOCAL ")
9434 }
9435 Self::Session => {
9436 f.write_fmt(format_args!("SESSION "))write!(f, "SESSION ")
9437 }
9438 Self::Global => {
9439 f.write_fmt(format_args!("GLOBAL "))write!(f, "GLOBAL ")
9440 }
9441 }
9442 }
9443}
9444
9445#[derive(#[automatically_derived]
impl ::core::fmt::Debug for DropFunctionOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
DropFunctionOption::Restrict => "Restrict",
DropFunctionOption::Cascade => "Cascade",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for DropFunctionOption {
#[inline]
fn clone(&self) -> DropFunctionOption {
match self {
DropFunctionOption::Restrict => DropFunctionOption::Restrict,
DropFunctionOption::Cascade => DropFunctionOption::Cascade,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for DropFunctionOption {
#[inline]
fn eq(&self, other: &DropFunctionOption) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for DropFunctionOption {
#[inline]
fn partial_cmp(&self, other: &DropFunctionOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for DropFunctionOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for DropFunctionOption {
#[inline]
fn cmp(&self, other: &DropFunctionOption) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for DropFunctionOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9447#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9448pub enum DropFunctionOption {
9449 Restrict,
9451 Cascade,
9453}
9454
9455impl fmt::Display for DropFunctionOption {
9456 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9457 match self {
9458 DropFunctionOption::Restrict => f.write_fmt(format_args!("RESTRICT "))write!(f, "RESTRICT "),
9459 DropFunctionOption::Cascade => f.write_fmt(format_args!("CASCADE "))write!(f, "CASCADE "),
9460 }
9461 }
9462}
9463
9464#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionDesc {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "FunctionDesc",
"name", &self.name, "args", &&self.args)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionDesc {
#[inline]
fn clone(&self) -> FunctionDesc {
FunctionDesc {
name: ::core::clone::Clone::clone(&self.name),
args: ::core::clone::Clone::clone(&self.args),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionDesc {
#[inline]
fn eq(&self, other: &FunctionDesc) -> bool {
self.name == other.name && self.args == other.args
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionDesc {
#[inline]
fn partial_cmp(&self, other: &FunctionDesc)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionDesc {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Option<Vec<OperateFunctionArg>>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionDesc {
#[inline]
fn cmp(&self, other: &FunctionDesc) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.args, &other.args),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionDesc {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.args, state)
}
}Hash)]
9466#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9467#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionDesc {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.args, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionDesc {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.args, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9468pub struct FunctionDesc {
9469 pub name: ObjectName,
9471 pub args: Option<Vec<OperateFunctionArg>>,
9473}
9474
9475impl fmt::Display for FunctionDesc {
9476 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9477 f.write_fmt(format_args!("{0}", self.name))write!(f, "{}", self.name)?;
9478 if let Some(args) = &self.args {
9479 f.write_fmt(format_args!("({0})", display_comma_separated(args)))write!(f, "({})", display_comma_separated(args))?;
9480 }
9481 Ok(())
9482 }
9483}
9484
9485#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OperateFunctionArg {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field4_finish(f,
"OperateFunctionArg", "mode", &self.mode, "name", &self.name,
"data_type", &self.data_type, "default_expr", &&self.default_expr)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OperateFunctionArg {
#[inline]
fn clone(&self) -> OperateFunctionArg {
OperateFunctionArg {
mode: ::core::clone::Clone::clone(&self.mode),
name: ::core::clone::Clone::clone(&self.name),
data_type: ::core::clone::Clone::clone(&self.data_type),
default_expr: ::core::clone::Clone::clone(&self.default_expr),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OperateFunctionArg {
#[inline]
fn eq(&self, other: &OperateFunctionArg) -> bool {
self.mode == other.mode && self.name == other.name &&
self.data_type == other.data_type &&
self.default_expr == other.default_expr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OperateFunctionArg {
#[inline]
fn partial_cmp(&self, other: &OperateFunctionArg)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OperateFunctionArg {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ArgMode>>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<DataType>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OperateFunctionArg {
#[inline]
fn cmp(&self, other: &OperateFunctionArg) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.mode, &other.mode) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.data_type,
&other.data_type) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.default_expr,
&other.default_expr),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OperateFunctionArg {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.mode, state);
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.data_type, state);
::core::hash::Hash::hash(&self.default_expr, state)
}
}Hash)]
9487#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9488#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OperateFunctionArg {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.mode, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.data_type, visitor)?;
sqlparser::ast::Visit::visit(&self.default_expr, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OperateFunctionArg {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.mode, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.data_type,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.default_expr,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9489pub struct OperateFunctionArg {
9490 pub mode: Option<ArgMode>,
9492 pub name: Option<Ident>,
9494 pub data_type: DataType,
9496 pub default_expr: Option<Expr>,
9498}
9499
9500impl OperateFunctionArg {
9501 pub fn unnamed(data_type: DataType) -> Self {
9503 Self {
9504 mode: None,
9505 name: None,
9506 data_type,
9507 default_expr: None,
9508 }
9509 }
9510
9511 pub fn with_name(name: &str, data_type: DataType) -> Self {
9513 Self {
9514 mode: None,
9515 name: Some(name.into()),
9516 data_type,
9517 default_expr: None,
9518 }
9519 }
9520}
9521
9522impl fmt::Display for OperateFunctionArg {
9523 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9524 if let Some(mode) = &self.mode {
9525 f.write_fmt(format_args!("{0} ", mode))write!(f, "{mode} ")?;
9526 }
9527 if let Some(name) = &self.name {
9528 f.write_fmt(format_args!("{0} ", name))write!(f, "{name} ")?;
9529 }
9530 f.write_fmt(format_args!("{0}", self.data_type))write!(f, "{}", self.data_type)?;
9531 if let Some(default_expr) = &self.default_expr {
9532 f.write_fmt(format_args!(" = {0}", default_expr))write!(f, " = {default_expr}")?;
9533 }
9534 Ok(())
9535 }
9536}
9537
9538#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ArgMode {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ArgMode::In => "In",
ArgMode::Out => "Out",
ArgMode::InOut => "InOut",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ArgMode {
#[inline]
fn clone(&self) -> ArgMode {
match self {
ArgMode::In => ArgMode::In,
ArgMode::Out => ArgMode::Out,
ArgMode::InOut => ArgMode::InOut,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ArgMode {
#[inline]
fn eq(&self, other: &ArgMode) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ArgMode {
#[inline]
fn partial_cmp(&self, other: &ArgMode)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ArgMode {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ArgMode {
#[inline]
fn cmp(&self, other: &ArgMode) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ArgMode {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9540#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9541#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ArgMode {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::In => {}
Self::Out => {}
Self::InOut => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ArgMode {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::In => {}
Self::Out => {}
Self::InOut => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9542pub enum ArgMode {
9543 In,
9545 Out,
9547 InOut,
9549}
9550
9551impl fmt::Display for ArgMode {
9552 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9553 match self {
9554 ArgMode::In => f.write_fmt(format_args!("IN"))write!(f, "IN"),
9555 ArgMode::Out => f.write_fmt(format_args!("OUT"))write!(f, "OUT"),
9556 ArgMode::InOut => f.write_fmt(format_args!("INOUT"))write!(f, "INOUT"),
9557 }
9558 }
9559}
9560
9561#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionBehavior {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FunctionBehavior::Immutable => "Immutable",
FunctionBehavior::Stable => "Stable",
FunctionBehavior::Volatile => "Volatile",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionBehavior {
#[inline]
fn clone(&self) -> FunctionBehavior {
match self {
FunctionBehavior::Immutable => FunctionBehavior::Immutable,
FunctionBehavior::Stable => FunctionBehavior::Stable,
FunctionBehavior::Volatile => FunctionBehavior::Volatile,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionBehavior {
#[inline]
fn eq(&self, other: &FunctionBehavior) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionBehavior {
#[inline]
fn partial_cmp(&self, other: &FunctionBehavior)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionBehavior {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionBehavior {
#[inline]
fn cmp(&self, other: &FunctionBehavior) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionBehavior {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9563#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9564#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionBehavior {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Immutable => {}
Self::Stable => {}
Self::Volatile => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionBehavior {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Immutable => {}
Self::Stable => {}
Self::Volatile => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9565pub enum FunctionBehavior {
9566 Immutable,
9568 Stable,
9570 Volatile,
9572}
9573
9574impl fmt::Display for FunctionBehavior {
9575 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9576 match self {
9577 FunctionBehavior::Immutable => f.write_fmt(format_args!("IMMUTABLE"))write!(f, "IMMUTABLE"),
9578 FunctionBehavior::Stable => f.write_fmt(format_args!("STABLE"))write!(f, "STABLE"),
9579 FunctionBehavior::Volatile => f.write_fmt(format_args!("VOLATILE"))write!(f, "VOLATILE"),
9580 }
9581 }
9582}
9583
9584#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionSecurity {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FunctionSecurity::Definer => "Definer",
FunctionSecurity::Invoker => "Invoker",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionSecurity {
#[inline]
fn clone(&self) -> FunctionSecurity {
match self {
FunctionSecurity::Definer => FunctionSecurity::Definer,
FunctionSecurity::Invoker => FunctionSecurity::Invoker,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionSecurity {
#[inline]
fn eq(&self, other: &FunctionSecurity) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionSecurity {
#[inline]
fn partial_cmp(&self, other: &FunctionSecurity)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionSecurity {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionSecurity {
#[inline]
fn cmp(&self, other: &FunctionSecurity) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionSecurity {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9588#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9589#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionSecurity {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Definer => {} Self::Invoker => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionSecurity {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Definer => {} Self::Invoker => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9590pub enum FunctionSecurity {
9591 Definer,
9593 Invoker,
9595}
9596
9597impl fmt::Display for FunctionSecurity {
9598 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9599 match self {
9600 FunctionSecurity::Definer => f.write_fmt(format_args!("SECURITY DEFINER"))write!(f, "SECURITY DEFINER"),
9601 FunctionSecurity::Invoker => f.write_fmt(format_args!("SECURITY INVOKER"))write!(f, "SECURITY INVOKER"),
9602 }
9603 }
9604}
9605
9606#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionSetValue {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
FunctionSetValue::Values(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Values",
&__self_0),
FunctionSetValue::FromCurrent =>
::core::fmt::Formatter::write_str(f, "FromCurrent"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionSetValue {
#[inline]
fn clone(&self) -> FunctionSetValue {
match self {
FunctionSetValue::Values(__self_0) =>
FunctionSetValue::Values(::core::clone::Clone::clone(__self_0)),
FunctionSetValue::FromCurrent => FunctionSetValue::FromCurrent,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionSetValue {
#[inline]
fn eq(&self, other: &FunctionSetValue) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(FunctionSetValue::Values(__self_0),
FunctionSetValue::Values(__arg1_0)) => __self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionSetValue {
#[inline]
fn partial_cmp(&self, other: &FunctionSetValue)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionSetValue {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionSetValue {
#[inline]
fn cmp(&self, other: &FunctionSetValue) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(FunctionSetValue::Values(__self_0),
FunctionSetValue::Values(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionSetValue {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
FunctionSetValue::Values(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
9610#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9611#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionSetValue {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Values(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::FromCurrent => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionSetValue {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Values(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::FromCurrent => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9612pub enum FunctionSetValue {
9613 Values(Vec<Expr>),
9615 FromCurrent,
9617}
9618
9619#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionDefinitionSetParam {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"FunctionDefinitionSetParam", "name", &self.name, "value",
&&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionDefinitionSetParam {
#[inline]
fn clone(&self) -> FunctionDefinitionSetParam {
FunctionDefinitionSetParam {
name: ::core::clone::Clone::clone(&self.name),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionDefinitionSetParam {
#[inline]
fn eq(&self, other: &FunctionDefinitionSetParam) -> bool {
self.name == other.name && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionDefinitionSetParam {
#[inline]
fn partial_cmp(&self, other: &FunctionDefinitionSetParam)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionDefinitionSetParam {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<FunctionSetValue>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionDefinitionSetParam {
#[inline]
fn cmp(&self, other: &FunctionDefinitionSetParam)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionDefinitionSetParam {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
9623#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9624#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionDefinitionSetParam {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionDefinitionSetParam {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9625pub struct FunctionDefinitionSetParam {
9626 pub name: Ident,
9628 pub value: FunctionSetValue,
9630}
9631
9632impl fmt::Display for FunctionDefinitionSetParam {
9633 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9634 f.write_fmt(format_args!("SET {0} ", self.name))write!(f, "SET {} ", self.name)?;
9635 match &self.value {
9636 FunctionSetValue::Values(values) => {
9637 f.write_fmt(format_args!("= {0}", display_comma_separated(values)))write!(f, "= {}", display_comma_separated(values))
9638 }
9639 FunctionSetValue::FromCurrent => f.write_fmt(format_args!("FROM CURRENT"))write!(f, "FROM CURRENT"),
9640 }
9641 }
9642}
9643
9644#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionCalledOnNull {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FunctionCalledOnNull::CalledOnNullInput =>
"CalledOnNullInput",
FunctionCalledOnNull::ReturnsNullOnNullInput =>
"ReturnsNullOnNullInput",
FunctionCalledOnNull::Strict => "Strict",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionCalledOnNull {
#[inline]
fn clone(&self) -> FunctionCalledOnNull {
match self {
FunctionCalledOnNull::CalledOnNullInput =>
FunctionCalledOnNull::CalledOnNullInput,
FunctionCalledOnNull::ReturnsNullOnNullInput =>
FunctionCalledOnNull::ReturnsNullOnNullInput,
FunctionCalledOnNull::Strict => FunctionCalledOnNull::Strict,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionCalledOnNull {
#[inline]
fn eq(&self, other: &FunctionCalledOnNull) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionCalledOnNull {
#[inline]
fn partial_cmp(&self, other: &FunctionCalledOnNull)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionCalledOnNull {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionCalledOnNull {
#[inline]
fn cmp(&self, other: &FunctionCalledOnNull) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionCalledOnNull {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9646#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9647#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionCalledOnNull {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::CalledOnNullInput => {}
Self::ReturnsNullOnNullInput => {}
Self::Strict => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionCalledOnNull {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::CalledOnNullInput => {}
Self::ReturnsNullOnNullInput => {}
Self::Strict => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9648pub enum FunctionCalledOnNull {
9649 CalledOnNullInput,
9651 ReturnsNullOnNullInput,
9653 Strict,
9655}
9656
9657impl fmt::Display for FunctionCalledOnNull {
9658 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9659 match self {
9660 FunctionCalledOnNull::CalledOnNullInput => f.write_fmt(format_args!("CALLED ON NULL INPUT"))write!(f, "CALLED ON NULL INPUT"),
9661 FunctionCalledOnNull::ReturnsNullOnNullInput => f.write_fmt(format_args!("RETURNS NULL ON NULL INPUT"))write!(f, "RETURNS NULL ON NULL INPUT"),
9662 FunctionCalledOnNull::Strict => f.write_fmt(format_args!("STRICT"))write!(f, "STRICT"),
9663 }
9664 }
9665}
9666
9667#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionParallel {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FunctionParallel::Unsafe => "Unsafe",
FunctionParallel::Restricted => "Restricted",
FunctionParallel::Safe => "Safe",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionParallel {
#[inline]
fn clone(&self) -> FunctionParallel {
match self {
FunctionParallel::Unsafe => FunctionParallel::Unsafe,
FunctionParallel::Restricted => FunctionParallel::Restricted,
FunctionParallel::Safe => FunctionParallel::Safe,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionParallel {
#[inline]
fn eq(&self, other: &FunctionParallel) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionParallel {
#[inline]
fn partial_cmp(&self, other: &FunctionParallel)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionParallel {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionParallel {
#[inline]
fn cmp(&self, other: &FunctionParallel) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionParallel {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9669#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9670#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionParallel {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Unsafe => {}
Self::Restricted => {}
Self::Safe => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionParallel {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Unsafe => {}
Self::Restricted => {}
Self::Safe => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9671pub enum FunctionParallel {
9672 Unsafe,
9674 Restricted,
9676 Safe,
9678}
9679
9680impl fmt::Display for FunctionParallel {
9681 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9682 match self {
9683 FunctionParallel::Unsafe => f.write_fmt(format_args!("PARALLEL UNSAFE"))write!(f, "PARALLEL UNSAFE"),
9684 FunctionParallel::Restricted => f.write_fmt(format_args!("PARALLEL RESTRICTED"))write!(f, "PARALLEL RESTRICTED"),
9685 FunctionParallel::Safe => f.write_fmt(format_args!("PARALLEL SAFE"))write!(f, "PARALLEL SAFE"),
9686 }
9687 }
9688}
9689
9690#[derive(#[automatically_derived]
impl ::core::fmt::Debug for FunctionDeterminismSpecifier {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
FunctionDeterminismSpecifier::Deterministic =>
"Deterministic",
FunctionDeterminismSpecifier::NotDeterministic =>
"NotDeterministic",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for FunctionDeterminismSpecifier {
#[inline]
fn clone(&self) -> FunctionDeterminismSpecifier {
match self {
FunctionDeterminismSpecifier::Deterministic =>
FunctionDeterminismSpecifier::Deterministic,
FunctionDeterminismSpecifier::NotDeterministic =>
FunctionDeterminismSpecifier::NotDeterministic,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for FunctionDeterminismSpecifier {
#[inline]
fn eq(&self, other: &FunctionDeterminismSpecifier) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for FunctionDeterminismSpecifier {
#[inline]
fn partial_cmp(&self, other: &FunctionDeterminismSpecifier)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for FunctionDeterminismSpecifier {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for FunctionDeterminismSpecifier {
#[inline]
fn cmp(&self, other: &FunctionDeterminismSpecifier)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for FunctionDeterminismSpecifier {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9694#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9695#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for FunctionDeterminismSpecifier {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Deterministic => {}
Self::NotDeterministic => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for FunctionDeterminismSpecifier {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Deterministic => {}
Self::NotDeterministic => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9696pub enum FunctionDeterminismSpecifier {
9697 Deterministic,
9699 NotDeterministic,
9701}
9702
9703impl fmt::Display for FunctionDeterminismSpecifier {
9704 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9705 match self {
9706 FunctionDeterminismSpecifier::Deterministic => {
9707 f.write_fmt(format_args!("DETERMINISTIC"))write!(f, "DETERMINISTIC")
9708 }
9709 FunctionDeterminismSpecifier::NotDeterministic => {
9710 f.write_fmt(format_args!("NOT DETERMINISTIC"))write!(f, "NOT DETERMINISTIC")
9711 }
9712 }
9713 }
9714}
9715
9716#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateFunctionBody {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CreateFunctionBody::AsBeforeOptions {
body: __self_0, link_symbol: __self_1 } =>
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AsBeforeOptions", "body", __self_0, "link_symbol",
&__self_1),
CreateFunctionBody::AsAfterOptions(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AsAfterOptions", &__self_0),
CreateFunctionBody::AsBeginEnd(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AsBeginEnd", &__self_0),
CreateFunctionBody::Return(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Return",
&__self_0),
CreateFunctionBody::AsReturnExpr(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AsReturnExpr", &__self_0),
CreateFunctionBody::AsReturnSelect(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"AsReturnSelect", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateFunctionBody {
#[inline]
fn clone(&self) -> CreateFunctionBody {
match self {
CreateFunctionBody::AsBeforeOptions {
body: __self_0, link_symbol: __self_1 } =>
CreateFunctionBody::AsBeforeOptions {
body: ::core::clone::Clone::clone(__self_0),
link_symbol: ::core::clone::Clone::clone(__self_1),
},
CreateFunctionBody::AsAfterOptions(__self_0) =>
CreateFunctionBody::AsAfterOptions(::core::clone::Clone::clone(__self_0)),
CreateFunctionBody::AsBeginEnd(__self_0) =>
CreateFunctionBody::AsBeginEnd(::core::clone::Clone::clone(__self_0)),
CreateFunctionBody::Return(__self_0) =>
CreateFunctionBody::Return(::core::clone::Clone::clone(__self_0)),
CreateFunctionBody::AsReturnExpr(__self_0) =>
CreateFunctionBody::AsReturnExpr(::core::clone::Clone::clone(__self_0)),
CreateFunctionBody::AsReturnSelect(__self_0) =>
CreateFunctionBody::AsReturnSelect(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateFunctionBody {
#[inline]
fn eq(&self, other: &CreateFunctionBody) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CreateFunctionBody::AsBeforeOptions {
body: __self_0, link_symbol: __self_1 },
CreateFunctionBody::AsBeforeOptions {
body: __arg1_0, link_symbol: __arg1_1 }) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
(CreateFunctionBody::AsAfterOptions(__self_0),
CreateFunctionBody::AsAfterOptions(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateFunctionBody::AsBeginEnd(__self_0),
CreateFunctionBody::AsBeginEnd(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateFunctionBody::Return(__self_0),
CreateFunctionBody::Return(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateFunctionBody::AsReturnExpr(__self_0),
CreateFunctionBody::AsReturnExpr(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateFunctionBody::AsReturnSelect(__self_0),
CreateFunctionBody::AsReturnSelect(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateFunctionBody {
#[inline]
fn partial_cmp(&self, other: &CreateFunctionBody)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateFunctionBody {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<BeginEndStatements>;
let _: ::core::cmp::AssertParamIsEq<Select>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateFunctionBody {
#[inline]
fn cmp(&self, other: &CreateFunctionBody) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CreateFunctionBody::AsBeforeOptions {
body: __self_0, link_symbol: __self_1 },
CreateFunctionBody::AsBeforeOptions {
body: __arg1_0, link_symbol: __arg1_1 }) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
(CreateFunctionBody::AsAfterOptions(__self_0),
CreateFunctionBody::AsAfterOptions(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateFunctionBody::AsBeginEnd(__self_0),
CreateFunctionBody::AsBeginEnd(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateFunctionBody::Return(__self_0),
CreateFunctionBody::Return(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateFunctionBody::AsReturnExpr(__self_0),
CreateFunctionBody::AsReturnExpr(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateFunctionBody::AsReturnSelect(__self_0),
CreateFunctionBody::AsReturnSelect(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateFunctionBody {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CreateFunctionBody::AsBeforeOptions {
body: __self_0, link_symbol: __self_1 } => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
CreateFunctionBody::AsAfterOptions(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateFunctionBody::AsBeginEnd(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateFunctionBody::Return(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateFunctionBody::AsReturnExpr(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateFunctionBody::AsReturnSelect(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
9723#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9724#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateFunctionBody {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AsBeforeOptions { body, link_symbol } => {
sqlparser::ast::Visit::visit(body, visitor)?;
sqlparser::ast::Visit::visit(link_symbol, visitor)?;
}
Self::AsAfterOptions(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AsBeginEnd(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Return(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AsReturnExpr(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::AsReturnSelect(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateFunctionBody {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::AsBeforeOptions { body, link_symbol } => {
sqlparser::ast::VisitMut::visit(body, visitor)?;
sqlparser::ast::VisitMut::visit(link_symbol, visitor)?;
}
Self::AsAfterOptions(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AsBeginEnd(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Return(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AsReturnExpr(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::AsReturnSelect(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9725pub enum CreateFunctionBody {
9726 AsBeforeOptions {
9739 body: Expr,
9741 link_symbol: Option<Expr>,
9750 },
9751 AsAfterOptions(Expr),
9763 AsBeginEnd(BeginEndStatements),
9779 Return(Expr),
9790
9791 AsReturnExpr(Expr),
9802
9803 AsReturnSelect(Select),
9814}
9815
9816#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateFunctionUsing {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CreateFunctionUsing::Jar(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Jar",
&__self_0),
CreateFunctionUsing::File(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "File",
&__self_0),
CreateFunctionUsing::Archive(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Archive", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateFunctionUsing {
#[inline]
fn clone(&self) -> CreateFunctionUsing {
match self {
CreateFunctionUsing::Jar(__self_0) =>
CreateFunctionUsing::Jar(::core::clone::Clone::clone(__self_0)),
CreateFunctionUsing::File(__self_0) =>
CreateFunctionUsing::File(::core::clone::Clone::clone(__self_0)),
CreateFunctionUsing::Archive(__self_0) =>
CreateFunctionUsing::Archive(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateFunctionUsing {
#[inline]
fn eq(&self, other: &CreateFunctionUsing) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CreateFunctionUsing::Jar(__self_0),
CreateFunctionUsing::Jar(__arg1_0)) => __self_0 == __arg1_0,
(CreateFunctionUsing::File(__self_0),
CreateFunctionUsing::File(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateFunctionUsing::Archive(__self_0),
CreateFunctionUsing::Archive(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateFunctionUsing {
#[inline]
fn partial_cmp(&self, other: &CreateFunctionUsing)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateFunctionUsing {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateFunctionUsing {
#[inline]
fn cmp(&self, other: &CreateFunctionUsing) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CreateFunctionUsing::Jar(__self_0),
CreateFunctionUsing::Jar(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateFunctionUsing::File(__self_0),
CreateFunctionUsing::File(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateFunctionUsing::Archive(__self_0),
CreateFunctionUsing::Archive(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateFunctionUsing {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CreateFunctionUsing::Jar(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateFunctionUsing::File(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateFunctionUsing::Archive(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
9817#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9818#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateFunctionUsing {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Jar(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::File(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Archive(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateFunctionUsing {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Jar(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::File(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Archive(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9819pub enum CreateFunctionUsing {
9821 Jar(String),
9823 File(String),
9825 Archive(String),
9827}
9828
9829impl fmt::Display for CreateFunctionUsing {
9830 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9831 f.write_fmt(format_args!("USING "))write!(f, "USING ")?;
9832 match self {
9833 CreateFunctionUsing::Jar(uri) => f.write_fmt(format_args!("JAR \'{0}\'", uri))write!(f, "JAR '{uri}'"),
9834 CreateFunctionUsing::File(uri) => f.write_fmt(format_args!("FILE \'{0}\'", uri))write!(f, "FILE '{uri}'"),
9835 CreateFunctionUsing::Archive(uri) => f.write_fmt(format_args!("ARCHIVE \'{0}\'", uri))write!(f, "ARCHIVE '{uri}'"),
9836 }
9837 }
9838}
9839
9840#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MacroArg {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "MacroArg",
"name", &self.name, "default_expr", &&self.default_expr)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for MacroArg {
#[inline]
fn clone(&self) -> MacroArg {
MacroArg {
name: ::core::clone::Clone::clone(&self.name),
default_expr: ::core::clone::Clone::clone(&self.default_expr),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MacroArg {
#[inline]
fn eq(&self, other: &MacroArg) -> bool {
self.name == other.name && self.default_expr == other.default_expr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MacroArg {
#[inline]
fn partial_cmp(&self, other: &MacroArg)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MacroArg {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MacroArg {
#[inline]
fn cmp(&self, other: &MacroArg) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.default_expr,
&other.default_expr),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MacroArg {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.default_expr, state)
}
}Hash)]
9845#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9846#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MacroArg {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.default_expr, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MacroArg {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.default_expr,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9847pub struct MacroArg {
9848 pub name: Ident,
9850 pub default_expr: Option<Expr>,
9852}
9853
9854impl MacroArg {
9855 pub fn new(name: &str) -> Self {
9857 Self {
9858 name: name.into(),
9859 default_expr: None,
9860 }
9861 }
9862}
9863
9864impl fmt::Display for MacroArg {
9865 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9866 f.write_fmt(format_args!("{0}", self.name))write!(f, "{}", self.name)?;
9867 if let Some(default_expr) = &self.default_expr {
9868 f.write_fmt(format_args!(" := {0}", default_expr))write!(f, " := {default_expr}")?;
9869 }
9870 Ok(())
9871 }
9872}
9873
9874#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MacroDefinition {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
MacroDefinition::Expr(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Expr",
&__self_0),
MacroDefinition::Table(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Table",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for MacroDefinition {
#[inline]
fn clone(&self) -> MacroDefinition {
match self {
MacroDefinition::Expr(__self_0) =>
MacroDefinition::Expr(::core::clone::Clone::clone(__self_0)),
MacroDefinition::Table(__self_0) =>
MacroDefinition::Table(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MacroDefinition {
#[inline]
fn eq(&self, other: &MacroDefinition) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(MacroDefinition::Expr(__self_0),
MacroDefinition::Expr(__arg1_0)) => __self_0 == __arg1_0,
(MacroDefinition::Table(__self_0),
MacroDefinition::Table(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MacroDefinition {
#[inline]
fn partial_cmp(&self, other: &MacroDefinition)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MacroDefinition {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MacroDefinition {
#[inline]
fn cmp(&self, other: &MacroDefinition) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(MacroDefinition::Expr(__self_0),
MacroDefinition::Expr(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(MacroDefinition::Table(__self_0),
MacroDefinition::Table(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MacroDefinition {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
MacroDefinition::Expr(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
MacroDefinition::Table(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
9875#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9876#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MacroDefinition {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Table(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MacroDefinition {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Table(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9877pub enum MacroDefinition {
9879 Expr(Expr),
9881 Table(Box<Query>),
9883}
9884
9885impl fmt::Display for MacroDefinition {
9886 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
9887 match self {
9888 MacroDefinition::Expr(expr) => f.write_fmt(format_args!("{0}", expr))write!(f, "{expr}")?,
9889 MacroDefinition::Table(query) => f.write_fmt(format_args!("{0}", query))write!(f, "{query}")?,
9890 }
9891 Ok(())
9892 }
9893}
9894
9895#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SchemaName {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
SchemaName::Simple(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Simple",
&__self_0),
SchemaName::UnnamedAuthorization(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"UnnamedAuthorization", &__self_0),
SchemaName::NamedAuthorization(__self_0, __self_1) =>
::core::fmt::Formatter::debug_tuple_field2_finish(f,
"NamedAuthorization", __self_0, &__self_1),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SchemaName {
#[inline]
fn clone(&self) -> SchemaName {
match self {
SchemaName::Simple(__self_0) =>
SchemaName::Simple(::core::clone::Clone::clone(__self_0)),
SchemaName::UnnamedAuthorization(__self_0) =>
SchemaName::UnnamedAuthorization(::core::clone::Clone::clone(__self_0)),
SchemaName::NamedAuthorization(__self_0, __self_1) =>
SchemaName::NamedAuthorization(::core::clone::Clone::clone(__self_0),
::core::clone::Clone::clone(__self_1)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SchemaName {
#[inline]
fn eq(&self, other: &SchemaName) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(SchemaName::Simple(__self_0), SchemaName::Simple(__arg1_0))
=> __self_0 == __arg1_0,
(SchemaName::UnnamedAuthorization(__self_0),
SchemaName::UnnamedAuthorization(__arg1_0)) =>
__self_0 == __arg1_0,
(SchemaName::NamedAuthorization(__self_0, __self_1),
SchemaName::NamedAuthorization(__arg1_0, __arg1_1)) =>
__self_0 == __arg1_0 && __self_1 == __arg1_1,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SchemaName {
#[inline]
fn partial_cmp(&self, other: &SchemaName)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SchemaName {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SchemaName {
#[inline]
fn cmp(&self, other: &SchemaName) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(SchemaName::Simple(__self_0), SchemaName::Simple(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SchemaName::UnnamedAuthorization(__self_0),
SchemaName::UnnamedAuthorization(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SchemaName::NamedAuthorization(__self_0, __self_1),
SchemaName::NamedAuthorization(__arg1_0, __arg1_1)) =>
match ::core::cmp::Ord::cmp(__self_0, __arg1_0) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(__self_1, __arg1_1),
cmp => cmp,
},
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SchemaName {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
SchemaName::Simple(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SchemaName::UnnamedAuthorization(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SchemaName::NamedAuthorization(__self_0, __self_1) => {
::core::hash::Hash::hash(__self_0, state);
::core::hash::Hash::hash(__self_1, state)
}
}
}
}Hash)]
9899#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9900#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SchemaName {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Simple(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::UnnamedAuthorization(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::NamedAuthorization(_0, _1) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
sqlparser::ast::Visit::visit(_1, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SchemaName {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Simple(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::UnnamedAuthorization(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::NamedAuthorization(_0, _1) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
sqlparser::ast::VisitMut::visit(_1, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9901pub enum SchemaName {
9902 Simple(ObjectName),
9904 UnnamedAuthorization(Ident),
9906 NamedAuthorization(ObjectName, Ident),
9908}
9909
9910impl fmt::Display for SchemaName {
9911 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9912 match self {
9913 SchemaName::Simple(name) => {
9914 f.write_fmt(format_args!("{0}", name))write!(f, "{name}")
9915 }
9916 SchemaName::UnnamedAuthorization(authorization) => {
9917 f.write_fmt(format_args!("AUTHORIZATION {0}", authorization))write!(f, "AUTHORIZATION {authorization}")
9918 }
9919 SchemaName::NamedAuthorization(name, authorization) => {
9920 f.write_fmt(format_args!("{0} AUTHORIZATION {1}", name, authorization))write!(f, "{name} AUTHORIZATION {authorization}")
9921 }
9922 }
9923 }
9924}
9925
9926#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SearchModifier {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
SearchModifier::InNaturalLanguageMode =>
"InNaturalLanguageMode",
SearchModifier::InNaturalLanguageModeWithQueryExpansion =>
"InNaturalLanguageModeWithQueryExpansion",
SearchModifier::InBooleanMode => "InBooleanMode",
SearchModifier::WithQueryExpansion => "WithQueryExpansion",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SearchModifier {
#[inline]
fn clone(&self) -> SearchModifier {
match self {
SearchModifier::InNaturalLanguageMode =>
SearchModifier::InNaturalLanguageMode,
SearchModifier::InNaturalLanguageModeWithQueryExpansion =>
SearchModifier::InNaturalLanguageModeWithQueryExpansion,
SearchModifier::InBooleanMode => SearchModifier::InBooleanMode,
SearchModifier::WithQueryExpansion =>
SearchModifier::WithQueryExpansion,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SearchModifier {
#[inline]
fn eq(&self, other: &SearchModifier) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SearchModifier {
#[inline]
fn partial_cmp(&self, other: &SearchModifier)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SearchModifier {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SearchModifier {
#[inline]
fn cmp(&self, other: &SearchModifier) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SearchModifier {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
9930#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9931#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SearchModifier {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::InNaturalLanguageMode => {}
Self::InNaturalLanguageModeWithQueryExpansion => {}
Self::InBooleanMode => {}
Self::WithQueryExpansion => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SearchModifier {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::InNaturalLanguageMode => {}
Self::InNaturalLanguageModeWithQueryExpansion => {}
Self::InBooleanMode => {}
Self::WithQueryExpansion => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9932pub enum SearchModifier {
9933 InNaturalLanguageMode,
9935 InNaturalLanguageModeWithQueryExpansion,
9937 InBooleanMode,
9939 WithQueryExpansion,
9941}
9942
9943impl fmt::Display for SearchModifier {
9944 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9945 match self {
9946 Self::InNaturalLanguageMode => {
9947 f.write_fmt(format_args!("IN NATURAL LANGUAGE MODE"))write!(f, "IN NATURAL LANGUAGE MODE")?;
9948 }
9949 Self::InNaturalLanguageModeWithQueryExpansion => {
9950 f.write_fmt(format_args!("IN NATURAL LANGUAGE MODE WITH QUERY EXPANSION"))write!(f, "IN NATURAL LANGUAGE MODE WITH QUERY EXPANSION")?;
9951 }
9952 Self::InBooleanMode => {
9953 f.write_fmt(format_args!("IN BOOLEAN MODE"))write!(f, "IN BOOLEAN MODE")?;
9954 }
9955 Self::WithQueryExpansion => {
9956 f.write_fmt(format_args!("WITH QUERY EXPANSION"))write!(f, "WITH QUERY EXPANSION")?;
9957 }
9958 }
9959
9960 Ok(())
9961 }
9962}
9963
9964#[derive(#[automatically_derived]
impl ::core::fmt::Debug for LockTable {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "LockTable",
"table", &self.table, "alias", &self.alias, "lock_type",
&&self.lock_type)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for LockTable {
#[inline]
fn clone(&self) -> LockTable {
LockTable {
table: ::core::clone::Clone::clone(&self.table),
alias: ::core::clone::Clone::clone(&self.alias),
lock_type: ::core::clone::Clone::clone(&self.lock_type),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for LockTable {
#[inline]
fn eq(&self, other: &LockTable) -> bool {
self.table == other.table && self.alias == other.alias &&
self.lock_type == other.lock_type
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for LockTable {
#[inline]
fn partial_cmp(&self, other: &LockTable)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for LockTable {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<LockTableType>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for LockTable {
#[inline]
fn cmp(&self, other: &LockTable) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.table, &other.table) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.alias, &other.alias) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.lock_type, &other.lock_type),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for LockTable {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.table, state);
::core::hash::Hash::hash(&self.alias, state);
::core::hash::Hash::hash(&self.lock_type, state)
}
}Hash)]
9966#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9967#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for LockTable {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.table, visitor)?;
sqlparser::ast::Visit::visit(&self.alias, visitor)?;
sqlparser::ast::Visit::visit(&self.lock_type, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for LockTable {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.table, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.alias, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.lock_type,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9968pub struct LockTable {
9969 pub table: Ident,
9971 pub alias: Option<Ident>,
9973 pub lock_type: LockTableType,
9975}
9976
9977impl fmt::Display for LockTable {
9978 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
9979 let Self {
9980 table: tbl_name,
9981 alias,
9982 lock_type,
9983 } = self;
9984
9985 f.write_fmt(format_args!("{0} ", tbl_name))write!(f, "{tbl_name} ")?;
9986 if let Some(alias) = alias {
9987 f.write_fmt(format_args!("AS {0} ", alias))write!(f, "AS {alias} ")?;
9988 }
9989 f.write_fmt(format_args!("{0}", lock_type))write!(f, "{lock_type}")?;
9990 Ok(())
9991 }
9992}
9993
9994#[derive(#[automatically_derived]
impl ::core::fmt::Debug for LockTableType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
LockTableType::Read { local: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Read",
"local", &__self_0),
LockTableType::Write { low_priority: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f, "Write",
"low_priority", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for LockTableType {
#[inline]
fn clone(&self) -> LockTableType {
match self {
LockTableType::Read { local: __self_0 } =>
LockTableType::Read {
local: ::core::clone::Clone::clone(__self_0),
},
LockTableType::Write { low_priority: __self_0 } =>
LockTableType::Write {
low_priority: ::core::clone::Clone::clone(__self_0),
},
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for LockTableType {
#[inline]
fn eq(&self, other: &LockTableType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(LockTableType::Read { local: __self_0 },
LockTableType::Read { local: __arg1_0 }) =>
__self_0 == __arg1_0,
(LockTableType::Write { low_priority: __self_0 },
LockTableType::Write { low_priority: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for LockTableType {
#[inline]
fn partial_cmp(&self, other: &LockTableType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for LockTableType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for LockTableType {
#[inline]
fn cmp(&self, other: &LockTableType) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(LockTableType::Read { local: __self_0 },
LockTableType::Read { local: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(LockTableType::Write { low_priority: __self_0 },
LockTableType::Write { low_priority: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for LockTableType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
LockTableType::Read { local: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
LockTableType::Write { low_priority: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
9995#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
9996#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for LockTableType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Read { local } => {
sqlparser::ast::Visit::visit(local, visitor)?;
}
Self::Write { low_priority } => {
sqlparser::ast::Visit::visit(low_priority, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for LockTableType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Read { local } => {
sqlparser::ast::VisitMut::visit(local, visitor)?;
}
Self::Write { low_priority } => {
sqlparser::ast::VisitMut::visit(low_priority, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
9997pub enum LockTableType {
9999 Read {
10001 local: bool,
10003 },
10004 Write {
10006 low_priority: bool,
10008 },
10009}
10010
10011impl fmt::Display for LockTableType {
10012 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10013 match self {
10014 Self::Read { local } => {
10015 f.write_fmt(format_args!("READ"))write!(f, "READ")?;
10016 if *local {
10017 f.write_fmt(format_args!(" LOCAL"))write!(f, " LOCAL")?;
10018 }
10019 }
10020 Self::Write { low_priority } => {
10021 if *low_priority {
10022 f.write_fmt(format_args!("LOW_PRIORITY "))write!(f, "LOW_PRIORITY ")?;
10023 }
10024 f.write_fmt(format_args!("WRITE"))write!(f, "WRITE")?;
10025 }
10026 }
10027
10028 Ok(())
10029 }
10030}
10031
10032#[derive(#[automatically_derived]
impl ::core::fmt::Debug for HiveSetLocation {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"HiveSetLocation", "has_set", &self.has_set, "location",
&&self.location)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for HiveSetLocation {
#[inline]
fn clone(&self) -> HiveSetLocation {
HiveSetLocation {
has_set: ::core::clone::Clone::clone(&self.has_set),
location: ::core::clone::Clone::clone(&self.location),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for HiveSetLocation {
#[inline]
fn eq(&self, other: &HiveSetLocation) -> bool {
self.has_set == other.has_set && self.location == other.location
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for HiveSetLocation {
#[inline]
fn partial_cmp(&self, other: &HiveSetLocation)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for HiveSetLocation {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for HiveSetLocation {
#[inline]
fn cmp(&self, other: &HiveSetLocation) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.has_set, &other.has_set) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.location, &other.location),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for HiveSetLocation {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.has_set, state);
::core::hash::Hash::hash(&self.location, state)
}
}Hash)]
10033#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10034#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for HiveSetLocation {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.has_set, visitor)?;
sqlparser::ast::Visit::visit(&self.location, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for HiveSetLocation {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.has_set,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.location,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10035pub struct HiveSetLocation {
10037 pub has_set: bool,
10039 pub location: Ident,
10041}
10042
10043impl fmt::Display for HiveSetLocation {
10044 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10045 if self.has_set {
10046 f.write_fmt(format_args!("SET "))write!(f, "SET ")?;
10047 }
10048 f.write_fmt(format_args!("LOCATION {0}", self.location))write!(f, "LOCATION {}", self.location)
10049 }
10050}
10051
10052#[allow(clippy::large_enum_variant)]
10054#[derive(#[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::fmt::Debug for MySQLColumnPosition {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
MySQLColumnPosition::First =>
::core::fmt::Formatter::write_str(f, "First"),
MySQLColumnPosition::After(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "After",
&__self_0),
}
}
}Debug, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::clone::Clone for MySQLColumnPosition {
#[inline]
fn clone(&self) -> MySQLColumnPosition {
match self {
MySQLColumnPosition::First => MySQLColumnPosition::First,
MySQLColumnPosition::After(__self_0) =>
MySQLColumnPosition::After(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::PartialEq for MySQLColumnPosition {
#[inline]
fn eq(&self, other: &MySQLColumnPosition) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(MySQLColumnPosition::After(__self_0),
MySQLColumnPosition::After(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::PartialOrd for MySQLColumnPosition {
#[inline]
fn partial_cmp(&self, other: &MySQLColumnPosition)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::Eq for MySQLColumnPosition {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::cmp::Ord for MySQLColumnPosition {
#[inline]
fn cmp(&self, other: &MySQLColumnPosition) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(MySQLColumnPosition::After(__self_0),
MySQLColumnPosition::After(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
#[allow(clippy::large_enum_variant)]
impl ::core::hash::Hash for MySQLColumnPosition {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
MySQLColumnPosition::After(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
10055#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10056#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MySQLColumnPosition {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::First => {}
Self::After(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MySQLColumnPosition {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::First => {}
Self::After(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10057pub enum MySQLColumnPosition {
10059 First,
10061 After(Ident),
10063}
10064
10065impl Display for MySQLColumnPosition {
10066 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10067 match self {
10068 MySQLColumnPosition::First => f.write_fmt(format_args!("FIRST"))write!(f, "FIRST"),
10069 MySQLColumnPosition::After(ident) => {
10070 let column_name = &ident.value;
10071 f.write_fmt(format_args!("AFTER {0}", column_name))write!(f, "AFTER {column_name}")
10072 }
10073 }
10074 }
10075}
10076
10077#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateViewAlgorithm {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CreateViewAlgorithm::Undefined => "Undefined",
CreateViewAlgorithm::Merge => "Merge",
CreateViewAlgorithm::TempTable => "TempTable",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateViewAlgorithm {
#[inline]
fn clone(&self) -> CreateViewAlgorithm {
match self {
CreateViewAlgorithm::Undefined => CreateViewAlgorithm::Undefined,
CreateViewAlgorithm::Merge => CreateViewAlgorithm::Merge,
CreateViewAlgorithm::TempTable => CreateViewAlgorithm::TempTable,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateViewAlgorithm {
#[inline]
fn eq(&self, other: &CreateViewAlgorithm) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateViewAlgorithm {
#[inline]
fn partial_cmp(&self, other: &CreateViewAlgorithm)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateViewAlgorithm {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateViewAlgorithm {
#[inline]
fn cmp(&self, other: &CreateViewAlgorithm) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateViewAlgorithm {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10079#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10080#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateViewAlgorithm {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Undefined => {}
Self::Merge => {}
Self::TempTable => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateViewAlgorithm {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Undefined => {}
Self::Merge => {}
Self::TempTable => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10081pub enum CreateViewAlgorithm {
10083 Undefined,
10085 Merge,
10087 TempTable,
10089}
10090
10091impl Display for CreateViewAlgorithm {
10092 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10093 match self {
10094 CreateViewAlgorithm::Undefined => f.write_fmt(format_args!("UNDEFINED"))write!(f, "UNDEFINED"),
10095 CreateViewAlgorithm::Merge => f.write_fmt(format_args!("MERGE"))write!(f, "MERGE"),
10096 CreateViewAlgorithm::TempTable => f.write_fmt(format_args!("TEMPTABLE"))write!(f, "TEMPTABLE"),
10097 }
10098 }
10099}
10100#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateViewSecurity {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CreateViewSecurity::Definer => "Definer",
CreateViewSecurity::Invoker => "Invoker",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateViewSecurity {
#[inline]
fn clone(&self) -> CreateViewSecurity {
match self {
CreateViewSecurity::Definer => CreateViewSecurity::Definer,
CreateViewSecurity::Invoker => CreateViewSecurity::Invoker,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateViewSecurity {
#[inline]
fn eq(&self, other: &CreateViewSecurity) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateViewSecurity {
#[inline]
fn partial_cmp(&self, other: &CreateViewSecurity)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateViewSecurity {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateViewSecurity {
#[inline]
fn cmp(&self, other: &CreateViewSecurity) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateViewSecurity {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10102#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10103#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateViewSecurity {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Definer => {} Self::Invoker => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateViewSecurity {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Definer => {} Self::Invoker => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10104pub enum CreateViewSecurity {
10106 Definer,
10108 Invoker,
10110}
10111
10112impl Display for CreateViewSecurity {
10113 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10114 match self {
10115 CreateViewSecurity::Definer => f.write_fmt(format_args!("DEFINER"))write!(f, "DEFINER"),
10116 CreateViewSecurity::Invoker => f.write_fmt(format_args!("INVOKER"))write!(f, "INVOKER"),
10117 }
10118 }
10119}
10120
10121#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateViewParams {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"CreateViewParams", "algorithm", &self.algorithm, "definer",
&self.definer, "security", &&self.security)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateViewParams {
#[inline]
fn clone(&self) -> CreateViewParams {
CreateViewParams {
algorithm: ::core::clone::Clone::clone(&self.algorithm),
definer: ::core::clone::Clone::clone(&self.definer),
security: ::core::clone::Clone::clone(&self.security),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateViewParams {
#[inline]
fn eq(&self, other: &CreateViewParams) -> bool {
self.algorithm == other.algorithm && self.definer == other.definer &&
self.security == other.security
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateViewParams {
#[inline]
fn partial_cmp(&self, other: &CreateViewParams)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateViewParams {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<CreateViewAlgorithm>>;
let _: ::core::cmp::AssertParamIsEq<Option<GranteeName>>;
let _: ::core::cmp::AssertParamIsEq<Option<CreateViewSecurity>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateViewParams {
#[inline]
fn cmp(&self, other: &CreateViewParams) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.algorithm, &other.algorithm) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.definer, &other.definer) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.security, &other.security),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateViewParams {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.algorithm, state);
::core::hash::Hash::hash(&self.definer, state);
::core::hash::Hash::hash(&self.security, state)
}
}Hash)]
10125#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10126#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateViewParams {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.algorithm, visitor)?;
sqlparser::ast::Visit::visit(&self.definer, visitor)?;
sqlparser::ast::Visit::visit(&self.security, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateViewParams {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.algorithm,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.definer,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.security,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10127pub struct CreateViewParams {
10128 pub algorithm: Option<CreateViewAlgorithm>,
10130 pub definer: Option<GranteeName>,
10132 pub security: Option<CreateViewSecurity>,
10134}
10135
10136impl Display for CreateViewParams {
10137 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10138 let CreateViewParams {
10139 algorithm,
10140 definer,
10141 security,
10142 } = self;
10143 if let Some(algorithm) = algorithm {
10144 f.write_fmt(format_args!("ALGORITHM = {0} ", algorithm))write!(f, "ALGORITHM = {algorithm} ")?;
10145 }
10146 if let Some(definers) = definer {
10147 f.write_fmt(format_args!("DEFINER = {0} ", definers))write!(f, "DEFINER = {definers} ")?;
10148 }
10149 if let Some(security) = security {
10150 f.write_fmt(format_args!("SQL SECURITY {0} ", security))write!(f, "SQL SECURITY {security} ")?;
10151 }
10152 Ok(())
10153 }
10154}
10155
10156#[derive(#[automatically_derived]
impl ::core::fmt::Debug for NamedParenthesizedList {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"NamedParenthesizedList", "key", &self.key, "name", &self.name,
"values", &&self.values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for NamedParenthesizedList {
#[inline]
fn clone(&self) -> NamedParenthesizedList {
NamedParenthesizedList {
key: ::core::clone::Clone::clone(&self.key),
name: ::core::clone::Clone::clone(&self.name),
values: ::core::clone::Clone::clone(&self.values),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for NamedParenthesizedList {
#[inline]
fn eq(&self, other: &NamedParenthesizedList) -> bool {
self.key == other.key && self.name == other.name &&
self.values == other.values
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for NamedParenthesizedList {
#[inline]
fn partial_cmp(&self, other: &NamedParenthesizedList)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for NamedParenthesizedList {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for NamedParenthesizedList {
#[inline]
fn cmp(&self, other: &NamedParenthesizedList) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.key, &other.key) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.values, &other.values),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for NamedParenthesizedList {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.key, state);
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.values, state)
}
}Hash)]
10157#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10158#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for NamedParenthesizedList {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.key, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.values, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for NamedParenthesizedList {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.key, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.values, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10159pub struct NamedParenthesizedList {
10167 pub key: Ident,
10169 pub name: Option<Ident>,
10171 pub values: Vec<Ident>,
10173}
10174
10175#[derive(#[automatically_derived]
impl ::core::fmt::Debug for RowAccessPolicy {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"RowAccessPolicy", "policy", &self.policy, "on", &&self.on)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for RowAccessPolicy {
#[inline]
fn clone(&self) -> RowAccessPolicy {
RowAccessPolicy {
policy: ::core::clone::Clone::clone(&self.policy),
on: ::core::clone::Clone::clone(&self.on),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for RowAccessPolicy {
#[inline]
fn eq(&self, other: &RowAccessPolicy) -> bool {
self.policy == other.policy && self.on == other.on
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for RowAccessPolicy {
#[inline]
fn partial_cmp(&self, other: &RowAccessPolicy)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for RowAccessPolicy {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Vec<Ident>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for RowAccessPolicy {
#[inline]
fn cmp(&self, other: &RowAccessPolicy) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.policy, &other.policy) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.on, &other.on),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for RowAccessPolicy {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.policy, state);
::core::hash::Hash::hash(&self.on, state)
}
}Hash)]
10180#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10181#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for RowAccessPolicy {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.policy, visitor)?;
sqlparser::ast::Visit::visit(&self.on, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for RowAccessPolicy {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.policy, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.on, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10182pub struct RowAccessPolicy {
10183 pub policy: ObjectName,
10185 pub on: Vec<Ident>,
10187}
10188
10189impl RowAccessPolicy {
10190 pub fn new(policy: ObjectName, on: Vec<Ident>) -> Self {
10192 Self { policy, on }
10193 }
10194}
10195
10196impl Display for RowAccessPolicy {
10197 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10198 f.write_fmt(format_args!("WITH ROW ACCESS POLICY {0} ON ({1})", self.policy,
display_comma_separated(self.on.as_slice())))write!(
10199 f,
10200 "WITH ROW ACCESS POLICY {} ON ({})",
10201 self.policy,
10202 display_comma_separated(self.on.as_slice())
10203 )
10204 }
10205}
10206
10207#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Tag {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "Tag", "key",
&self.key, "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Tag {
#[inline]
fn clone(&self) -> Tag {
Tag {
key: ::core::clone::Clone::clone(&self.key),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Tag {
#[inline]
fn eq(&self, other: &Tag) -> bool {
self.key == other.key && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Tag {
#[inline]
fn partial_cmp(&self, other: &Tag)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Tag {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Tag {
#[inline]
fn cmp(&self, other: &Tag) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.key, &other.key) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Tag {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.key, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
10211#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10212#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Tag {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.key, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Tag {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.key, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10213pub struct Tag {
10214 pub key: ObjectName,
10216 pub value: String,
10218}
10219
10220impl Tag {
10221 pub fn new(key: ObjectName, value: String) -> Self {
10223 Self { key, value }
10224 }
10225}
10226
10227impl Display for Tag {
10228 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10229 f.write_fmt(format_args!("{0}=\'{1}\'", self.key, self.value))write!(f, "{}='{}'", self.key, self.value)
10230 }
10231}
10232
10233#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ContactEntry {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "ContactEntry",
"purpose", &self.purpose, "contact", &&self.contact)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ContactEntry {
#[inline]
fn clone(&self) -> ContactEntry {
ContactEntry {
purpose: ::core::clone::Clone::clone(&self.purpose),
contact: ::core::clone::Clone::clone(&self.contact),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ContactEntry {
#[inline]
fn eq(&self, other: &ContactEntry) -> bool {
self.purpose == other.purpose && self.contact == other.contact
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ContactEntry {
#[inline]
fn partial_cmp(&self, other: &ContactEntry)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ContactEntry {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ContactEntry {
#[inline]
fn cmp(&self, other: &ContactEntry) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.purpose, &other.purpose) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.contact, &other.contact),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ContactEntry {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.purpose, state);
::core::hash::Hash::hash(&self.contact, state)
}
}Hash)]
10237#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10238#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ContactEntry {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.purpose, visitor)?;
sqlparser::ast::Visit::visit(&self.contact, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ContactEntry {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.purpose,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.contact,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10239pub struct ContactEntry {
10240 pub purpose: String,
10242 pub contact: String,
10244}
10245
10246impl Display for ContactEntry {
10247 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10248 f.write_fmt(format_args!("{0} = {1}", self.purpose, self.contact))write!(f, "{} = {}", self.purpose, self.contact)
10249 }
10250}
10251
10252#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CommentDef {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CommentDef::WithEq(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "WithEq",
&__self_0),
CommentDef::WithoutEq(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"WithoutEq", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CommentDef {
#[inline]
fn clone(&self) -> CommentDef {
match self {
CommentDef::WithEq(__self_0) =>
CommentDef::WithEq(::core::clone::Clone::clone(__self_0)),
CommentDef::WithoutEq(__self_0) =>
CommentDef::WithoutEq(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CommentDef {
#[inline]
fn eq(&self, other: &CommentDef) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CommentDef::WithEq(__self_0), CommentDef::WithEq(__arg1_0))
=> __self_0 == __arg1_0,
(CommentDef::WithoutEq(__self_0),
CommentDef::WithoutEq(__arg1_0)) => __self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CommentDef {
#[inline]
fn partial_cmp(&self, other: &CommentDef)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CommentDef {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CommentDef {
#[inline]
fn cmp(&self, other: &CommentDef) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CommentDef::WithEq(__self_0), CommentDef::WithEq(__arg1_0))
=> ::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CommentDef::WithoutEq(__self_0),
CommentDef::WithoutEq(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CommentDef {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CommentDef::WithEq(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CommentDef::WithoutEq(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
10254#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10255#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CommentDef {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::WithEq(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::WithoutEq(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CommentDef {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::WithEq(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::WithoutEq(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10256pub enum CommentDef {
10257 WithEq(String),
10260 WithoutEq(String),
10262}
10263
10264impl Display for CommentDef {
10265 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10266 match self {
10267 CommentDef::WithEq(comment) | CommentDef::WithoutEq(comment) => f.write_fmt(format_args!("{0}", comment))write!(f, "{comment}"),
10268 }
10269 }
10270}
10271
10272#[derive(#[automatically_derived]
impl<T: ::core::fmt::Debug> ::core::fmt::Debug for WrappedCollection<T> {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
WrappedCollection::NoWrapping(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"NoWrapping", &__self_0),
WrappedCollection::Parentheses(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Parentheses", &__self_0),
}
}
}Debug, #[automatically_derived]
impl<T: ::core::clone::Clone> ::core::clone::Clone for WrappedCollection<T> {
#[inline]
fn clone(&self) -> WrappedCollection<T> {
match self {
WrappedCollection::NoWrapping(__self_0) =>
WrappedCollection::NoWrapping(::core::clone::Clone::clone(__self_0)),
WrappedCollection::Parentheses(__self_0) =>
WrappedCollection::Parentheses(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl<T: ::core::cmp::PartialEq> ::core::cmp::PartialEq for
WrappedCollection<T> {
#[inline]
fn eq(&self, other: &WrappedCollection<T>) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(WrappedCollection::NoWrapping(__self_0),
WrappedCollection::NoWrapping(__arg1_0)) =>
__self_0 == __arg1_0,
(WrappedCollection::Parentheses(__self_0),
WrappedCollection::Parentheses(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl<T: ::core::cmp::PartialOrd> ::core::cmp::PartialOrd for
WrappedCollection<T> {
#[inline]
fn partial_cmp(&self, other: &WrappedCollection<T>)
-> ::core::option::Option<::core::cmp::Ordering> {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match (self, other) {
(WrappedCollection::NoWrapping(__self_0),
WrappedCollection::NoWrapping(__arg1_0)) =>
::core::cmp::PartialOrd::partial_cmp(__self_0, __arg1_0),
(WrappedCollection::Parentheses(__self_0),
WrappedCollection::Parentheses(__arg1_0)) =>
::core::cmp::PartialOrd::partial_cmp(__self_0, __arg1_0),
_ =>
::core::cmp::PartialOrd::partial_cmp(&__self_discr,
&__arg1_discr),
}
}
}PartialOrd, #[automatically_derived]
impl<T: ::core::cmp::Eq> ::core::cmp::Eq for WrappedCollection<T> {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) { let _: ::core::cmp::AssertParamIsEq<T>; }
}Eq, #[automatically_derived]
impl<T: ::core::cmp::Ord> ::core::cmp::Ord for WrappedCollection<T> {
#[inline]
fn cmp(&self, other: &WrappedCollection<T>) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(WrappedCollection::NoWrapping(__self_0),
WrappedCollection::NoWrapping(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(WrappedCollection::Parentheses(__self_0),
WrappedCollection::Parentheses(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl<T: ::core::hash::Hash> ::core::hash::Hash for WrappedCollection<T> {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
WrappedCollection::NoWrapping(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
WrappedCollection::Parentheses(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
10287#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10288#[cfg_attr(feature = "visitor", derive(impl<T: sqlparser::ast::Visit> sqlparser::ast::Visit for WrappedCollection<T>
{
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::NoWrapping(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Parentheses(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl<T: sqlparser::ast::VisitMut> sqlparser::ast::VisitMut for
WrappedCollection<T> {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::NoWrapping(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Parentheses(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10289pub enum WrappedCollection<T> {
10290 NoWrapping(T),
10292 Parentheses(T),
10294}
10295
10296impl<T> Display for WrappedCollection<Vec<T>>
10297where
10298 T: Display,
10299{
10300 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10301 match self {
10302 WrappedCollection::NoWrapping(inner) => {
10303 f.write_fmt(format_args!("{0}", display_comma_separated(inner.as_slice())))write!(f, "{}", display_comma_separated(inner.as_slice()))
10304 }
10305 WrappedCollection::Parentheses(inner) => {
10306 f.write_fmt(format_args!("({0})", display_comma_separated(inner.as_slice())))write!(f, "({})", display_comma_separated(inner.as_slice()))
10307 }
10308 }
10309 }
10310}
10311
10312#[derive(#[automatically_derived]
impl ::core::fmt::Debug for UtilityOption {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "UtilityOption",
"name", &self.name, "arg", &&self.arg)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for UtilityOption {
#[inline]
fn clone(&self) -> UtilityOption {
UtilityOption {
name: ::core::clone::Clone::clone(&self.name),
arg: ::core::clone::Clone::clone(&self.arg),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for UtilityOption {
#[inline]
fn eq(&self, other: &UtilityOption) -> bool {
self.name == other.name && self.arg == other.arg
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for UtilityOption {
#[inline]
fn partial_cmp(&self, other: &UtilityOption)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for UtilityOption {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for UtilityOption {
#[inline]
fn cmp(&self, other: &UtilityOption) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.arg, &other.arg),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for UtilityOption {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.arg, state)
}
}Hash)]
10336#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10337#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for UtilityOption {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.arg, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for UtilityOption {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.arg, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10338pub struct UtilityOption {
10339 pub name: Ident,
10341 pub arg: Option<Expr>,
10343}
10344
10345impl Display for UtilityOption {
10346 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10347 if let Some(ref arg) = self.arg {
10348 f.write_fmt(format_args!("{0} {1}", self.name, arg))write!(f, "{} {}", self.name, arg)
10349 } else {
10350 f.write_fmt(format_args!("{0}", self.name))write!(f, "{}", self.name)
10351 }
10352 }
10353}
10354
10355#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowStatementOptions {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field5_finish(f,
"ShowStatementOptions", "show_in", &self.show_in, "starts_with",
&self.starts_with, "limit", &self.limit, "limit_from",
&self.limit_from, "filter_position", &&self.filter_position)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowStatementOptions {
#[inline]
fn clone(&self) -> ShowStatementOptions {
ShowStatementOptions {
show_in: ::core::clone::Clone::clone(&self.show_in),
starts_with: ::core::clone::Clone::clone(&self.starts_with),
limit: ::core::clone::Clone::clone(&self.limit),
limit_from: ::core::clone::Clone::clone(&self.limit_from),
filter_position: ::core::clone::Clone::clone(&self.filter_position),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowStatementOptions {
#[inline]
fn eq(&self, other: &ShowStatementOptions) -> bool {
self.show_in == other.show_in && self.starts_with == other.starts_with
&& self.limit == other.limit &&
self.limit_from == other.limit_from &&
self.filter_position == other.filter_position
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowStatementOptions {
#[inline]
fn partial_cmp(&self, other: &ShowStatementOptions)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowStatementOptions {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ShowStatementIn>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _: ::core::cmp::AssertParamIsEq<Option<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
let _:
::core::cmp::AssertParamIsEq<Option<ShowStatementFilterPosition>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowStatementOptions {
#[inline]
fn cmp(&self, other: &ShowStatementOptions) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.show_in, &other.show_in) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.starts_with,
&other.starts_with) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.limit, &other.limit) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.limit_from,
&other.limit_from) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.filter_position,
&other.filter_position),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowStatementOptions {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.show_in, state);
::core::hash::Hash::hash(&self.starts_with, state);
::core::hash::Hash::hash(&self.limit, state);
::core::hash::Hash::hash(&self.limit_from, state);
::core::hash::Hash::hash(&self.filter_position, state)
}
}Hash)]
10359#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10360#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowStatementOptions {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.show_in, visitor)?;
sqlparser::ast::Visit::visit(&self.starts_with, visitor)?;
sqlparser::ast::Visit::visit(&self.limit, visitor)?;
sqlparser::ast::Visit::visit(&self.limit_from, visitor)?;
sqlparser::ast::Visit::visit(&self.filter_position,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowStatementOptions {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.show_in,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.starts_with,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.limit, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.limit_from,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.filter_position,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10361pub struct ShowStatementOptions {
10362 pub show_in: Option<ShowStatementIn>,
10364 pub starts_with: Option<Value>,
10366 pub limit: Option<Expr>,
10368 pub limit_from: Option<Value>,
10370 pub filter_position: Option<ShowStatementFilterPosition>,
10372}
10373
10374impl Display for ShowStatementOptions {
10375 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10376 let (like_in_infix, like_in_suffix) = match &self.filter_position {
10377 Some(ShowStatementFilterPosition::Infix(filter)) => {
10378 (::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" {0}", filter))
})format!(" {filter}"), "".to_string())
10379 }
10380 Some(ShowStatementFilterPosition::Suffix(filter)) => {
10381 ("".to_string(), ::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" {0}", filter))
})format!(" {filter}"))
10382 }
10383 None => ("".to_string(), "".to_string()),
10384 };
10385 f.write_fmt(format_args!("{4}{0}{1}{2}{3}{5}",
match &self.show_in {
Some(i) =>
::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" {0}", i))
}),
None => String::new(),
},
match &self.starts_with {
Some(s) =>
::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" STARTS WITH {0}", s))
}),
None => String::new(),
},
match &self.limit {
Some(l) =>
::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" LIMIT {0}", l))
}),
None => String::new(),
},
match &self.limit_from {
Some(f) =>
::alloc::__export::must_use({
::alloc::fmt::format(format_args!(" FROM {0}", f))
}),
None => String::new(),
}, like_in_infix, like_in_suffix))write!(
10386 f,
10387 "{like_in_infix}{show_in}{starts_with}{limit}{from}{like_in_suffix}",
10388 show_in = match &self.show_in {
10389 Some(i) => format!(" {i}"),
10390 None => String::new(),
10391 },
10392 starts_with = match &self.starts_with {
10393 Some(s) => format!(" STARTS WITH {s}"),
10394 None => String::new(),
10395 },
10396 limit = match &self.limit {
10397 Some(l) => format!(" LIMIT {l}"),
10398 None => String::new(),
10399 },
10400 from = match &self.limit_from {
10401 Some(f) => format!(" FROM {f}"),
10402 None => String::new(),
10403 }
10404 )?;
10405 Ok(())
10406 }
10407}
10408
10409#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowStatementFilterPosition {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ShowStatementFilterPosition::Infix(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Infix",
&__self_0),
ShowStatementFilterPosition::Suffix(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Suffix",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowStatementFilterPosition {
#[inline]
fn clone(&self) -> ShowStatementFilterPosition {
match self {
ShowStatementFilterPosition::Infix(__self_0) =>
ShowStatementFilterPosition::Infix(::core::clone::Clone::clone(__self_0)),
ShowStatementFilterPosition::Suffix(__self_0) =>
ShowStatementFilterPosition::Suffix(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowStatementFilterPosition {
#[inline]
fn eq(&self, other: &ShowStatementFilterPosition) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(ShowStatementFilterPosition::Infix(__self_0),
ShowStatementFilterPosition::Infix(__arg1_0)) =>
__self_0 == __arg1_0,
(ShowStatementFilterPosition::Suffix(__self_0),
ShowStatementFilterPosition::Suffix(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowStatementFilterPosition {
#[inline]
fn partial_cmp(&self, other: &ShowStatementFilterPosition)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowStatementFilterPosition {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ShowStatementFilter>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowStatementFilterPosition {
#[inline]
fn cmp(&self, other: &ShowStatementFilterPosition)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(ShowStatementFilterPosition::Infix(__self_0),
ShowStatementFilterPosition::Infix(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(ShowStatementFilterPosition::Suffix(__self_0),
ShowStatementFilterPosition::Suffix(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowStatementFilterPosition {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
ShowStatementFilterPosition::Infix(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
ShowStatementFilterPosition::Suffix(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
10410#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10411#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowStatementFilterPosition {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Infix(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Suffix(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowStatementFilterPosition {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Infix(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Suffix(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10412pub enum ShowStatementFilterPosition {
10414 Infix(ShowStatementFilter), Suffix(ShowStatementFilter), }
10419
10420#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowStatementInParentType {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
ShowStatementInParentType::Account => "Account",
ShowStatementInParentType::Database => "Database",
ShowStatementInParentType::Schema => "Schema",
ShowStatementInParentType::Table => "Table",
ShowStatementInParentType::View => "View",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowStatementInParentType {
#[inline]
fn clone(&self) -> ShowStatementInParentType {
match self {
ShowStatementInParentType::Account =>
ShowStatementInParentType::Account,
ShowStatementInParentType::Database =>
ShowStatementInParentType::Database,
ShowStatementInParentType::Schema =>
ShowStatementInParentType::Schema,
ShowStatementInParentType::Table =>
ShowStatementInParentType::Table,
ShowStatementInParentType::View =>
ShowStatementInParentType::View,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowStatementInParentType {
#[inline]
fn eq(&self, other: &ShowStatementInParentType) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowStatementInParentType {
#[inline]
fn partial_cmp(&self, other: &ShowStatementInParentType)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowStatementInParentType {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowStatementInParentType {
#[inline]
fn cmp(&self, other: &ShowStatementInParentType)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowStatementInParentType {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10421#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10422#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowStatementInParentType {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Account => {}
Self::Database => {}
Self::Schema => {}
Self::Table => {}
Self::View => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowStatementInParentType {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Account => {}
Self::Database => {}
Self::Schema => {}
Self::Table => {}
Self::View => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10423pub enum ShowStatementInParentType {
10425 Account,
10427 Database,
10429 Schema,
10431 Table,
10433 View,
10435}
10436
10437impl fmt::Display for ShowStatementInParentType {
10438 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10439 match self {
10440 ShowStatementInParentType::Account => f.write_fmt(format_args!("ACCOUNT"))write!(f, "ACCOUNT"),
10441 ShowStatementInParentType::Database => f.write_fmt(format_args!("DATABASE"))write!(f, "DATABASE"),
10442 ShowStatementInParentType::Schema => f.write_fmt(format_args!("SCHEMA"))write!(f, "SCHEMA"),
10443 ShowStatementInParentType::Table => f.write_fmt(format_args!("TABLE"))write!(f, "TABLE"),
10444 ShowStatementInParentType::View => f.write_fmt(format_args!("VIEW"))write!(f, "VIEW"),
10445 }
10446 }
10447}
10448
10449#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowStatementIn {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f,
"ShowStatementIn", "clause", &self.clause, "parent_type",
&self.parent_type, "parent_name", &&self.parent_name)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowStatementIn {
#[inline]
fn clone(&self) -> ShowStatementIn {
ShowStatementIn {
clause: ::core::clone::Clone::clone(&self.clause),
parent_type: ::core::clone::Clone::clone(&self.parent_type),
parent_name: ::core::clone::Clone::clone(&self.parent_name),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowStatementIn {
#[inline]
fn eq(&self, other: &ShowStatementIn) -> bool {
self.clause == other.clause && self.parent_type == other.parent_type
&& self.parent_name == other.parent_name
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowStatementIn {
#[inline]
fn partial_cmp(&self, other: &ShowStatementIn)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowStatementIn {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ShowStatementInClause>;
let _:
::core::cmp::AssertParamIsEq<Option<ShowStatementInParentType>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowStatementIn {
#[inline]
fn cmp(&self, other: &ShowStatementIn) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.clause, &other.clause) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.parent_type,
&other.parent_type) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.parent_name,
&other.parent_name),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowStatementIn {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.clause, state);
::core::hash::Hash::hash(&self.parent_type, state);
::core::hash::Hash::hash(&self.parent_name, state)
}
}Hash)]
10450#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10451#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowStatementIn {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.clause, visitor)?;
sqlparser::ast::Visit::visit(&self.parent_type, visitor)?;
if let Some(value) = &self.parent_name {
visitor.pre_visit_relation(value)?;
sqlparser::ast::Visit::visit(value, visitor)?;
visitor.post_visit_relation(value)?;
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowStatementIn {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.clause, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.parent_type,
visitor)?;
if let Some(value) = &mut self.parent_name {
visitor.pre_visit_relation(value)?;
sqlparser::ast::VisitMut::visit(value, visitor)?;
visitor.post_visit_relation(value)?;
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10452pub struct ShowStatementIn {
10454 pub clause: ShowStatementInClause,
10456 pub parent_type: Option<ShowStatementInParentType>,
10458 #[cfg_attr(feature = "visitor", visit(with = "visit_relation"))]
10460 pub parent_name: Option<ObjectName>,
10461}
10462
10463impl fmt::Display for ShowStatementIn {
10464 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10465 f.write_fmt(format_args!("{0}", self.clause))write!(f, "{}", self.clause)?;
10466 if let Some(parent_type) = &self.parent_type {
10467 f.write_fmt(format_args!(" {0}", parent_type))write!(f, " {parent_type}")?;
10468 }
10469 if let Some(parent_name) = &self.parent_name {
10470 f.write_fmt(format_args!(" {0}", parent_name))write!(f, " {parent_name}")?;
10471 }
10472 Ok(())
10473 }
10474}
10475
10476#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowCharset {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "ShowCharset",
"is_shorthand", &self.is_shorthand, "filter", &&self.filter)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowCharset {
#[inline]
fn clone(&self) -> ShowCharset {
ShowCharset {
is_shorthand: ::core::clone::Clone::clone(&self.is_shorthand),
filter: ::core::clone::Clone::clone(&self.filter),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowCharset {
#[inline]
fn eq(&self, other: &ShowCharset) -> bool {
self.is_shorthand == other.is_shorthand && self.filter == other.filter
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowCharset {
#[inline]
fn partial_cmp(&self, other: &ShowCharset)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowCharset {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Option<ShowStatementFilter>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowCharset {
#[inline]
fn cmp(&self, other: &ShowCharset) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.is_shorthand, &other.is_shorthand) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.filter, &other.filter),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowCharset {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.is_shorthand, state);
::core::hash::Hash::hash(&self.filter, state)
}
}Hash)]
10478#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10479#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowCharset {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.is_shorthand, visitor)?;
sqlparser::ast::Visit::visit(&self.filter, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowCharset {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.is_shorthand,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.filter, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10480pub struct ShowCharset {
10481 pub is_shorthand: bool,
10484 pub filter: Option<ShowStatementFilter>,
10486}
10487
10488impl fmt::Display for ShowCharset {
10489 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10490 f.write_fmt(format_args!("SHOW"))write!(f, "SHOW")?;
10491 if self.is_shorthand {
10492 f.write_fmt(format_args!(" CHARSET"))write!(f, " CHARSET")?;
10493 } else {
10494 f.write_fmt(format_args!(" CHARACTER SET"))write!(f, " CHARACTER SET")?;
10495 }
10496 if let Some(filter) = &self.filter {
10497 f.write_fmt(format_args!(" {0}", filter))write!(f, " {filter}")?;
10498 }
10499 Ok(())
10500 }
10501}
10502
10503#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ShowObjects {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "ShowObjects",
"terse", &self.terse, "show_options", &&self.show_options)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ShowObjects {
#[inline]
fn clone(&self) -> ShowObjects {
ShowObjects {
terse: ::core::clone::Clone::clone(&self.terse),
show_options: ::core::clone::Clone::clone(&self.show_options),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ShowObjects {
#[inline]
fn eq(&self, other: &ShowObjects) -> bool {
self.terse == other.terse && self.show_options == other.show_options
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ShowObjects {
#[inline]
fn partial_cmp(&self, other: &ShowObjects)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ShowObjects {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<ShowStatementOptions>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ShowObjects {
#[inline]
fn cmp(&self, other: &ShowObjects) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.terse, &other.terse) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.show_options,
&other.show_options),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ShowObjects {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.terse, state);
::core::hash::Hash::hash(&self.show_options, state)
}
}Hash)]
10504#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10505#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ShowObjects {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.terse, visitor)?;
sqlparser::ast::Visit::visit(&self.show_options, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ShowObjects {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.terse, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.show_options,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10506pub struct ShowObjects {
10508 pub terse: bool,
10510 pub show_options: ShowStatementOptions,
10512}
10513
10514#[derive(#[automatically_derived]
impl ::core::fmt::Debug for JsonNullClause {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
JsonNullClause::NullOnNull => "NullOnNull",
JsonNullClause::AbsentOnNull => "AbsentOnNull",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for JsonNullClause {
#[inline]
fn clone(&self) -> JsonNullClause {
match self {
JsonNullClause::NullOnNull => JsonNullClause::NullOnNull,
JsonNullClause::AbsentOnNull => JsonNullClause::AbsentOnNull,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for JsonNullClause {
#[inline]
fn eq(&self, other: &JsonNullClause) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for JsonNullClause {
#[inline]
fn partial_cmp(&self, other: &JsonNullClause)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for JsonNullClause {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for JsonNullClause {
#[inline]
fn cmp(&self, other: &JsonNullClause) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for JsonNullClause {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10524#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10525#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for JsonNullClause {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::NullOnNull => {}
Self::AbsentOnNull => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for JsonNullClause {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::NullOnNull => {}
Self::AbsentOnNull => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10526pub enum JsonNullClause {
10527 NullOnNull,
10529 AbsentOnNull,
10531}
10532
10533impl Display for JsonNullClause {
10534 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10535 match self {
10536 JsonNullClause::NullOnNull => f.write_fmt(format_args!("NULL ON NULL"))write!(f, "NULL ON NULL"),
10537 JsonNullClause::AbsentOnNull => f.write_fmt(format_args!("ABSENT ON NULL"))write!(f, "ABSENT ON NULL"),
10538 }
10539 }
10540}
10541
10542#[derive(#[automatically_derived]
impl ::core::fmt::Debug for JsonReturningClause {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"JsonReturningClause", "data_type", &&self.data_type)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for JsonReturningClause {
#[inline]
fn clone(&self) -> JsonReturningClause {
JsonReturningClause {
data_type: ::core::clone::Clone::clone(&self.data_type),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for JsonReturningClause {
#[inline]
fn eq(&self, other: &JsonReturningClause) -> bool {
self.data_type == other.data_type
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for JsonReturningClause {
#[inline]
fn partial_cmp(&self, other: &JsonReturningClause)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for JsonReturningClause {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<DataType>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for JsonReturningClause {
#[inline]
fn cmp(&self, other: &JsonReturningClause) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.data_type, &other.data_type)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for JsonReturningClause {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.data_type, state)
}
}Hash)]
10549#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10550#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for JsonReturningClause {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.data_type, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for JsonReturningClause {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.data_type,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10551pub struct JsonReturningClause {
10552 pub data_type: DataType,
10554}
10555
10556impl Display for JsonReturningClause {
10557 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10558 f.write_fmt(format_args!("RETURNING {0}", self.data_type))write!(f, "RETURNING {}", self.data_type)
10559 }
10560}
10561
10562#[derive(#[automatically_derived]
impl ::core::fmt::Debug for RenameTable {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "RenameTable",
"old_name", &self.old_name, "new_name", &&self.new_name)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for RenameTable {
#[inline]
fn clone(&self) -> RenameTable {
RenameTable {
old_name: ::core::clone::Clone::clone(&self.old_name),
new_name: ::core::clone::Clone::clone(&self.new_name),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for RenameTable {
#[inline]
fn eq(&self, other: &RenameTable) -> bool {
self.old_name == other.old_name && self.new_name == other.new_name
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for RenameTable {
#[inline]
fn partial_cmp(&self, other: &RenameTable)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for RenameTable {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for RenameTable {
#[inline]
fn cmp(&self, other: &RenameTable) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.old_name, &other.old_name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.new_name, &other.new_name),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for RenameTable {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.old_name, state);
::core::hash::Hash::hash(&self.new_name, state)
}
}Hash)]
10564#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10565#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for RenameTable {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.old_name, visitor)?;
sqlparser::ast::Visit::visit(&self.new_name, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for RenameTable {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.old_name,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.new_name,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10566pub struct RenameTable {
10567 pub old_name: ObjectName,
10569 pub new_name: ObjectName,
10571}
10572
10573impl fmt::Display for RenameTable {
10574 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10575 f.write_fmt(format_args!("{0} TO {1}", self.old_name, self.new_name))write!(f, "{} TO {}", self.old_name, self.new_name)?;
10576 Ok(())
10577 }
10578}
10579
10580#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TableObject {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
TableObject::TableName(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"TableName", &__self_0),
TableObject::TableFunction(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"TableFunction", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TableObject {
#[inline]
fn clone(&self) -> TableObject {
match self {
TableObject::TableName(__self_0) =>
TableObject::TableName(::core::clone::Clone::clone(__self_0)),
TableObject::TableFunction(__self_0) =>
TableObject::TableFunction(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TableObject {
#[inline]
fn eq(&self, other: &TableObject) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(TableObject::TableName(__self_0),
TableObject::TableName(__arg1_0)) => __self_0 == __arg1_0,
(TableObject::TableFunction(__self_0),
TableObject::TableFunction(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TableObject {
#[inline]
fn partial_cmp(&self, other: &TableObject)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for TableObject {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Function>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for TableObject {
#[inline]
fn cmp(&self, other: &TableObject) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(TableObject::TableName(__self_0),
TableObject::TableName(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(TableObject::TableFunction(__self_0),
TableObject::TableFunction(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for TableObject {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
TableObject::TableName(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
TableObject::TableFunction(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
10582#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10583#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for TableObject {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::TableName(_0) => {
visitor.pre_visit_relation(_0)?;
sqlparser::ast::Visit::visit(_0, visitor)?;
visitor.post_visit_relation(_0)?;
}
Self::TableFunction(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for TableObject {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::TableName(_0) => {
visitor.pre_visit_relation(_0)?;
sqlparser::ast::VisitMut::visit(_0, visitor)?;
visitor.post_visit_relation(_0)?;
}
Self::TableFunction(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10584pub enum TableObject {
10585 TableName(#[cfg_attr(feature = "visitor", visit(with = "visit_relation"))] ObjectName),
10591
10592 TableFunction(Function),
10599}
10600
10601impl fmt::Display for TableObject {
10602 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10603 match self {
10604 Self::TableName(table_name) => f.write_fmt(format_args!("{0}", table_name))write!(f, "{table_name}"),
10605 Self::TableFunction(func) => f.write_fmt(format_args!("FUNCTION {0}", func))write!(f, "FUNCTION {func}"),
10606 }
10607 }
10608}
10609
10610#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionAuthorizationParam {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetSessionAuthorizationParam", "scope", &self.scope, "kind",
&&self.kind)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionAuthorizationParam {
#[inline]
fn clone(&self) -> SetSessionAuthorizationParam {
SetSessionAuthorizationParam {
scope: ::core::clone::Clone::clone(&self.scope),
kind: ::core::clone::Clone::clone(&self.kind),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionAuthorizationParam {
#[inline]
fn eq(&self, other: &SetSessionAuthorizationParam) -> bool {
self.scope == other.scope && self.kind == other.kind
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionAuthorizationParam {
#[inline]
fn partial_cmp(&self, other: &SetSessionAuthorizationParam)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionAuthorizationParam {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ContextModifier>;
let _: ::core::cmp::AssertParamIsEq<SetSessionAuthorizationParamKind>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionAuthorizationParam {
#[inline]
fn cmp(&self, other: &SetSessionAuthorizationParam)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.scope, &other.scope) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.kind, &other.kind),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionAuthorizationParam {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.scope, state);
::core::hash::Hash::hash(&self.kind, state)
}
}Hash)]
10612#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10613#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionAuthorizationParam {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.scope, visitor)?;
sqlparser::ast::Visit::visit(&self.kind, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionAuthorizationParam {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.scope, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.kind, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10614pub struct SetSessionAuthorizationParam {
10615 pub scope: ContextModifier,
10617 pub kind: SetSessionAuthorizationParamKind,
10619}
10620
10621impl fmt::Display for SetSessionAuthorizationParam {
10622 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10623 f.write_fmt(format_args!("{0}", self.kind))write!(f, "{}", self.kind)
10624 }
10625}
10626
10627#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionAuthorizationParamKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
SetSessionAuthorizationParamKind::Default =>
::core::fmt::Formatter::write_str(f, "Default"),
SetSessionAuthorizationParamKind::User(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "User",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionAuthorizationParamKind {
#[inline]
fn clone(&self) -> SetSessionAuthorizationParamKind {
match self {
SetSessionAuthorizationParamKind::Default =>
SetSessionAuthorizationParamKind::Default,
SetSessionAuthorizationParamKind::User(__self_0) =>
SetSessionAuthorizationParamKind::User(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionAuthorizationParamKind {
#[inline]
fn eq(&self, other: &SetSessionAuthorizationParamKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(SetSessionAuthorizationParamKind::User(__self_0),
SetSessionAuthorizationParamKind::User(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionAuthorizationParamKind {
#[inline]
fn partial_cmp(&self, other: &SetSessionAuthorizationParamKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionAuthorizationParamKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionAuthorizationParamKind {
#[inline]
fn cmp(&self, other: &SetSessionAuthorizationParamKind)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(SetSessionAuthorizationParamKind::User(__self_0),
SetSessionAuthorizationParamKind::User(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionAuthorizationParamKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
SetSessionAuthorizationParamKind::User(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
10629#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10630#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionAuthorizationParamKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Default => {}
Self::User(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionAuthorizationParamKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Default => {}
Self::User(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10631pub enum SetSessionAuthorizationParamKind {
10632 Default,
10634
10635 User(Ident),
10637}
10638
10639impl fmt::Display for SetSessionAuthorizationParamKind {
10640 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10641 match self {
10642 SetSessionAuthorizationParamKind::Default => f.write_fmt(format_args!("DEFAULT"))write!(f, "DEFAULT"),
10643 SetSessionAuthorizationParamKind::User(name) => f.write_fmt(format_args!("{0}", name))write!(f, "{}", name),
10644 }
10645 }
10646}
10647
10648#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionParamKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
SetSessionParamKind::Generic(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Generic", &__self_0),
SetSessionParamKind::IdentityInsert(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"IdentityInsert", &__self_0),
SetSessionParamKind::Offsets(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Offsets", &__self_0),
SetSessionParamKind::Statistics(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Statistics", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionParamKind {
#[inline]
fn clone(&self) -> SetSessionParamKind {
match self {
SetSessionParamKind::Generic(__self_0) =>
SetSessionParamKind::Generic(::core::clone::Clone::clone(__self_0)),
SetSessionParamKind::IdentityInsert(__self_0) =>
SetSessionParamKind::IdentityInsert(::core::clone::Clone::clone(__self_0)),
SetSessionParamKind::Offsets(__self_0) =>
SetSessionParamKind::Offsets(::core::clone::Clone::clone(__self_0)),
SetSessionParamKind::Statistics(__self_0) =>
SetSessionParamKind::Statistics(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionParamKind {
#[inline]
fn eq(&self, other: &SetSessionParamKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(SetSessionParamKind::Generic(__self_0),
SetSessionParamKind::Generic(__arg1_0)) =>
__self_0 == __arg1_0,
(SetSessionParamKind::IdentityInsert(__self_0),
SetSessionParamKind::IdentityInsert(__arg1_0)) =>
__self_0 == __arg1_0,
(SetSessionParamKind::Offsets(__self_0),
SetSessionParamKind::Offsets(__arg1_0)) =>
__self_0 == __arg1_0,
(SetSessionParamKind::Statistics(__self_0),
SetSessionParamKind::Statistics(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionParamKind {
#[inline]
fn partial_cmp(&self, other: &SetSessionParamKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionParamKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<SetSessionParamGeneric>;
let _: ::core::cmp::AssertParamIsEq<SetSessionParamIdentityInsert>;
let _: ::core::cmp::AssertParamIsEq<SetSessionParamOffsets>;
let _: ::core::cmp::AssertParamIsEq<SetSessionParamStatistics>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionParamKind {
#[inline]
fn cmp(&self, other: &SetSessionParamKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(SetSessionParamKind::Generic(__self_0),
SetSessionParamKind::Generic(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SetSessionParamKind::IdentityInsert(__self_0),
SetSessionParamKind::IdentityInsert(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SetSessionParamKind::Offsets(__self_0),
SetSessionParamKind::Offsets(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(SetSessionParamKind::Statistics(__self_0),
SetSessionParamKind::Statistics(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionParamKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
SetSessionParamKind::Generic(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SetSessionParamKind::IdentityInsert(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SetSessionParamKind::Offsets(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
SetSessionParamKind::Statistics(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
10649#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10650#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionParamKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Generic(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::IdentityInsert(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Offsets(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Statistics(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionParamKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Generic(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::IdentityInsert(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Offsets(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Statistics(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10651pub enum SetSessionParamKind {
10653 Generic(SetSessionParamGeneric),
10655 IdentityInsert(SetSessionParamIdentityInsert),
10657 Offsets(SetSessionParamOffsets),
10659 Statistics(SetSessionParamStatistics),
10661}
10662
10663impl fmt::Display for SetSessionParamKind {
10664 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10665 match self {
10666 SetSessionParamKind::Generic(x) => f.write_fmt(format_args!("{0}", x))write!(f, "{x}"),
10667 SetSessionParamKind::IdentityInsert(x) => f.write_fmt(format_args!("{0}", x))write!(f, "{x}"),
10668 SetSessionParamKind::Offsets(x) => f.write_fmt(format_args!("{0}", x))write!(f, "{x}"),
10669 SetSessionParamKind::Statistics(x) => f.write_fmt(format_args!("{0}", x))write!(f, "{x}"),
10670 }
10671 }
10672}
10673
10674#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionParamGeneric {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetSessionParamGeneric", "names", &self.names, "value",
&&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionParamGeneric {
#[inline]
fn clone(&self) -> SetSessionParamGeneric {
SetSessionParamGeneric {
names: ::core::clone::Clone::clone(&self.names),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionParamGeneric {
#[inline]
fn eq(&self, other: &SetSessionParamGeneric) -> bool {
self.names == other.names && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionParamGeneric {
#[inline]
fn partial_cmp(&self, other: &SetSessionParamGeneric)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionParamGeneric {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<String>>;
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionParamGeneric {
#[inline]
fn cmp(&self, other: &SetSessionParamGeneric) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.names, &other.names) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionParamGeneric {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.names, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
10675#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10676#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionParamGeneric {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.names, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionParamGeneric {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.names, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10677pub struct SetSessionParamGeneric {
10679 pub names: Vec<String>,
10681 pub value: String,
10683}
10684
10685impl fmt::Display for SetSessionParamGeneric {
10686 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10687 f.write_fmt(format_args!("{0} {1}", display_comma_separated(&self.names),
self.value))write!(f, "{} {}", display_comma_separated(&self.names), self.value)
10688 }
10689}
10690
10691#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionParamIdentityInsert {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetSessionParamIdentityInsert", "obj", &self.obj, "value",
&&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionParamIdentityInsert {
#[inline]
fn clone(&self) -> SetSessionParamIdentityInsert {
SetSessionParamIdentityInsert {
obj: ::core::clone::Clone::clone(&self.obj),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionParamIdentityInsert {
#[inline]
fn eq(&self, other: &SetSessionParamIdentityInsert) -> bool {
self.obj == other.obj && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionParamIdentityInsert {
#[inline]
fn partial_cmp(&self, other: &SetSessionParamIdentityInsert)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionParamIdentityInsert {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<SessionParamValue>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionParamIdentityInsert {
#[inline]
fn cmp(&self, other: &SetSessionParamIdentityInsert)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.obj, &other.obj) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionParamIdentityInsert {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.obj, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
10692#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10693#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionParamIdentityInsert {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.obj, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionParamIdentityInsert {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.obj, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10694pub struct SetSessionParamIdentityInsert {
10696 pub obj: ObjectName,
10698 pub value: SessionParamValue,
10700}
10701
10702impl fmt::Display for SetSessionParamIdentityInsert {
10703 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10704 f.write_fmt(format_args!("IDENTITY_INSERT {0} {1}", self.obj, self.value))write!(f, "IDENTITY_INSERT {} {}", self.obj, self.value)
10705 }
10706}
10707
10708#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionParamOffsets {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetSessionParamOffsets", "keywords", &self.keywords, "value",
&&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionParamOffsets {
#[inline]
fn clone(&self) -> SetSessionParamOffsets {
SetSessionParamOffsets {
keywords: ::core::clone::Clone::clone(&self.keywords),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionParamOffsets {
#[inline]
fn eq(&self, other: &SetSessionParamOffsets) -> bool {
self.keywords == other.keywords && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionParamOffsets {
#[inline]
fn partial_cmp(&self, other: &SetSessionParamOffsets)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionParamOffsets {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<String>>;
let _: ::core::cmp::AssertParamIsEq<SessionParamValue>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionParamOffsets {
#[inline]
fn cmp(&self, other: &SetSessionParamOffsets) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.keywords, &other.keywords) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionParamOffsets {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.keywords, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
10709#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10710#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionParamOffsets {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.keywords, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionParamOffsets {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.keywords,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10711pub struct SetSessionParamOffsets {
10713 pub keywords: Vec<String>,
10715 pub value: SessionParamValue,
10717}
10718
10719impl fmt::Display for SetSessionParamOffsets {
10720 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10721 f.write_fmt(format_args!("OFFSETS {0} {1}",
display_comma_separated(&self.keywords), self.value))write!(
10722 f,
10723 "OFFSETS {} {}",
10724 display_comma_separated(&self.keywords),
10725 self.value
10726 )
10727 }
10728}
10729
10730#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SetSessionParamStatistics {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"SetSessionParamStatistics", "topic", &self.topic, "value",
&&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SetSessionParamStatistics {
#[inline]
fn clone(&self) -> SetSessionParamStatistics {
SetSessionParamStatistics {
topic: ::core::clone::Clone::clone(&self.topic),
value: ::core::clone::Clone::clone(&self.value),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SetSessionParamStatistics {
#[inline]
fn eq(&self, other: &SetSessionParamStatistics) -> bool {
self.topic == other.topic && self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SetSessionParamStatistics {
#[inline]
fn partial_cmp(&self, other: &SetSessionParamStatistics)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SetSessionParamStatistics {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<SessionParamStatsTopic>;
let _: ::core::cmp::AssertParamIsEq<SessionParamValue>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SetSessionParamStatistics {
#[inline]
fn cmp(&self, other: &SetSessionParamStatistics)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.topic, &other.topic) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.value, &other.value),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SetSessionParamStatistics {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.topic, state);
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
10731#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10732#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SetSessionParamStatistics {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.topic, visitor)?;
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SetSessionParamStatistics {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.topic, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10733pub struct SetSessionParamStatistics {
10735 pub topic: SessionParamStatsTopic,
10737 pub value: SessionParamValue,
10739}
10740
10741impl fmt::Display for SetSessionParamStatistics {
10742 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10743 f.write_fmt(format_args!("STATISTICS {0} {1}", self.topic, self.value))write!(f, "STATISTICS {} {}", self.topic, self.value)
10744 }
10745}
10746
10747#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SessionParamStatsTopic {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
SessionParamStatsTopic::IO => "IO",
SessionParamStatsTopic::Profile => "Profile",
SessionParamStatsTopic::Time => "Time",
SessionParamStatsTopic::Xml => "Xml",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SessionParamStatsTopic {
#[inline]
fn clone(&self) -> SessionParamStatsTopic {
match self {
SessionParamStatsTopic::IO => SessionParamStatsTopic::IO,
SessionParamStatsTopic::Profile =>
SessionParamStatsTopic::Profile,
SessionParamStatsTopic::Time => SessionParamStatsTopic::Time,
SessionParamStatsTopic::Xml => SessionParamStatsTopic::Xml,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SessionParamStatsTopic {
#[inline]
fn eq(&self, other: &SessionParamStatsTopic) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SessionParamStatsTopic {
#[inline]
fn partial_cmp(&self, other: &SessionParamStatsTopic)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SessionParamStatsTopic {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SessionParamStatsTopic {
#[inline]
fn cmp(&self, other: &SessionParamStatsTopic) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SessionParamStatsTopic {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10748#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10749#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SessionParamStatsTopic {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IO => {}
Self::Profile => {}
Self::Time => {}
Self::Xml => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SessionParamStatsTopic {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IO => {}
Self::Profile => {}
Self::Time => {}
Self::Xml => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10750pub enum SessionParamStatsTopic {
10752 IO,
10754 Profile,
10756 Time,
10758 Xml,
10760}
10761
10762impl fmt::Display for SessionParamStatsTopic {
10763 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10764 match self {
10765 SessionParamStatsTopic::IO => f.write_fmt(format_args!("IO"))write!(f, "IO"),
10766 SessionParamStatsTopic::Profile => f.write_fmt(format_args!("PROFILE"))write!(f, "PROFILE"),
10767 SessionParamStatsTopic::Time => f.write_fmt(format_args!("TIME"))write!(f, "TIME"),
10768 SessionParamStatsTopic::Xml => f.write_fmt(format_args!("XML"))write!(f, "XML"),
10769 }
10770 }
10771}
10772
10773#[derive(#[automatically_derived]
impl ::core::fmt::Debug for SessionParamValue {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
SessionParamValue::On => "On",
SessionParamValue::Off => "Off",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for SessionParamValue {
#[inline]
fn clone(&self) -> SessionParamValue {
match self {
SessionParamValue::On => SessionParamValue::On,
SessionParamValue::Off => SessionParamValue::Off,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for SessionParamValue {
#[inline]
fn eq(&self, other: &SessionParamValue) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for SessionParamValue {
#[inline]
fn partial_cmp(&self, other: &SessionParamValue)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for SessionParamValue {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for SessionParamValue {
#[inline]
fn cmp(&self, other: &SessionParamValue) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for SessionParamValue {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10774#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10775#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for SessionParamValue {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::On => {} Self::Off => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for SessionParamValue {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::On => {} Self::Off => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10776pub enum SessionParamValue {
10778 On,
10780 Off,
10782}
10783
10784impl fmt::Display for SessionParamValue {
10785 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10786 match self {
10787 SessionParamValue::On => f.write_fmt(format_args!("ON"))write!(f, "ON"),
10788 SessionParamValue::Off => f.write_fmt(format_args!("OFF"))write!(f, "OFF"),
10789 }
10790 }
10791}
10792
10793#[derive(#[automatically_derived]
impl ::core::fmt::Debug for StorageSerializationPolicy {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
StorageSerializationPolicy::Compatible => "Compatible",
StorageSerializationPolicy::Optimized => "Optimized",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for StorageSerializationPolicy { }Copy, #[automatically_derived]
impl ::core::clone::Clone for StorageSerializationPolicy {
#[inline]
fn clone(&self) -> StorageSerializationPolicy { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for StorageSerializationPolicy {
#[inline]
fn eq(&self, other: &StorageSerializationPolicy) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for StorageSerializationPolicy {
#[inline]
fn partial_cmp(&self, other: &StorageSerializationPolicy)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for StorageSerializationPolicy {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for StorageSerializationPolicy {
#[inline]
fn cmp(&self, other: &StorageSerializationPolicy)
-> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for StorageSerializationPolicy {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10800#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10801#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for StorageSerializationPolicy {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Compatible => {} Self::Optimized => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for StorageSerializationPolicy {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Compatible => {} Self::Optimized => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10802pub enum StorageSerializationPolicy {
10803 Compatible,
10805 Optimized,
10807}
10808
10809impl Display for StorageSerializationPolicy {
10810 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10811 match self {
10812 StorageSerializationPolicy::Compatible => f.write_fmt(format_args!("COMPATIBLE"))write!(f, "COMPATIBLE"),
10813 StorageSerializationPolicy::Optimized => f.write_fmt(format_args!("OPTIMIZED"))write!(f, "OPTIMIZED"),
10814 }
10815 }
10816}
10817
10818#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CatalogSyncNamespaceMode {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CatalogSyncNamespaceMode::Nest => "Nest",
CatalogSyncNamespaceMode::Flatten => "Flatten",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for CatalogSyncNamespaceMode { }Copy, #[automatically_derived]
impl ::core::clone::Clone for CatalogSyncNamespaceMode {
#[inline]
fn clone(&self) -> CatalogSyncNamespaceMode { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CatalogSyncNamespaceMode {
#[inline]
fn eq(&self, other: &CatalogSyncNamespaceMode) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CatalogSyncNamespaceMode {
#[inline]
fn partial_cmp(&self, other: &CatalogSyncNamespaceMode)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CatalogSyncNamespaceMode {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CatalogSyncNamespaceMode {
#[inline]
fn cmp(&self, other: &CatalogSyncNamespaceMode) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CatalogSyncNamespaceMode {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10825#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10826#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CatalogSyncNamespaceMode {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Nest => {} Self::Flatten => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CatalogSyncNamespaceMode {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Nest => {} Self::Flatten => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10827pub enum CatalogSyncNamespaceMode {
10828 Nest,
10830 Flatten,
10832}
10833
10834impl Display for CatalogSyncNamespaceMode {
10835 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
10836 match self {
10837 CatalogSyncNamespaceMode::Nest => f.write_fmt(format_args!("NEST"))write!(f, "NEST"),
10838 CatalogSyncNamespaceMode::Flatten => f.write_fmt(format_args!("FLATTEN"))write!(f, "FLATTEN"),
10839 }
10840 }
10841}
10842
10843#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CopyIntoSnowflakeKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CopyIntoSnowflakeKind::Table => "Table",
CopyIntoSnowflakeKind::Location => "Location",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for CopyIntoSnowflakeKind { }Copy, #[automatically_derived]
impl ::core::clone::Clone for CopyIntoSnowflakeKind {
#[inline]
fn clone(&self) -> CopyIntoSnowflakeKind { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CopyIntoSnowflakeKind {
#[inline]
fn eq(&self, other: &CopyIntoSnowflakeKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CopyIntoSnowflakeKind {
#[inline]
fn partial_cmp(&self, other: &CopyIntoSnowflakeKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CopyIntoSnowflakeKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CopyIntoSnowflakeKind {
#[inline]
fn cmp(&self, other: &CopyIntoSnowflakeKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CopyIntoSnowflakeKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10845#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10846#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CopyIntoSnowflakeKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Table => {} Self::Location => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CopyIntoSnowflakeKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Table => {} Self::Location => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10847pub enum CopyIntoSnowflakeKind {
10848 Table,
10851 Location,
10854}
10855
10856#[derive(#[automatically_derived]
impl ::core::fmt::Debug for PrintStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"PrintStatement", "message", &&self.message)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for PrintStatement {
#[inline]
fn clone(&self) -> PrintStatement {
PrintStatement { message: ::core::clone::Clone::clone(&self.message) }
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for PrintStatement {
#[inline]
fn eq(&self, other: &PrintStatement) -> bool {
self.message == other.message
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for PrintStatement {
#[inline]
fn partial_cmp(&self, other: &PrintStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for PrintStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for PrintStatement {
#[inline]
fn cmp(&self, other: &PrintStatement) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.message, &other.message)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for PrintStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.message, state)
}
}Hash)]
10857#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10858#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for PrintStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.message, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for PrintStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.message,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10859pub struct PrintStatement {
10861 pub message: Box<Expr>,
10863}
10864
10865impl fmt::Display for PrintStatement {
10866 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10867 f.write_fmt(format_args!("PRINT {0}", self.message))write!(f, "PRINT {}", self.message)
10868 }
10869}
10870
10871#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ReturnStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"ReturnStatement", "value", &&self.value)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ReturnStatement {
#[inline]
fn clone(&self) -> ReturnStatement {
ReturnStatement { value: ::core::clone::Clone::clone(&self.value) }
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ReturnStatement {
#[inline]
fn eq(&self, other: &ReturnStatement) -> bool {
self.value == other.value
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ReturnStatement {
#[inline]
fn partial_cmp(&self, other: &ReturnStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ReturnStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<ReturnStatementValue>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ReturnStatement {
#[inline]
fn cmp(&self, other: &ReturnStatement) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.value, &other.value)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ReturnStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.value, state)
}
}Hash)]
10876#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10877#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ReturnStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ReturnStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10878pub struct ReturnStatement {
10879 pub value: Option<ReturnStatementValue>,
10881}
10882
10883impl fmt::Display for ReturnStatement {
10884 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10885 match &self.value {
10886 Some(ReturnStatementValue::Expr(expr)) => f.write_fmt(format_args!("RETURN {0}", expr))write!(f, "RETURN {expr}"),
10887 None => f.write_fmt(format_args!("RETURN"))write!(f, "RETURN"),
10888 }
10889 }
10890}
10891
10892#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ReturnStatementValue {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
ReturnStatementValue::Expr(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Expr",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ReturnStatementValue {
#[inline]
fn clone(&self) -> ReturnStatementValue {
match self {
ReturnStatementValue::Expr(__self_0) =>
ReturnStatementValue::Expr(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ReturnStatementValue {
#[inline]
fn eq(&self, other: &ReturnStatementValue) -> bool {
match (self, other) {
(ReturnStatementValue::Expr(__self_0),
ReturnStatementValue::Expr(__arg1_0)) => __self_0 == __arg1_0,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ReturnStatementValue {
#[inline]
fn partial_cmp(&self, other: &ReturnStatementValue)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ReturnStatementValue {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Expr>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ReturnStatementValue {
#[inline]
fn cmp(&self, other: &ReturnStatementValue) -> ::core::cmp::Ordering {
match (self, other) {
(ReturnStatementValue::Expr(__self_0),
ReturnStatementValue::Expr(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ReturnStatementValue {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
match self {
ReturnStatementValue::Expr(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
10894#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10895#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ReturnStatementValue {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ReturnStatementValue {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Expr(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10896pub enum ReturnStatementValue {
10897 Expr(Expr),
10899}
10900
10901#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OpenStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f, "OpenStatement",
"cursor_name", &&self.cursor_name)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OpenStatement {
#[inline]
fn clone(&self) -> OpenStatement {
OpenStatement {
cursor_name: ::core::clone::Clone::clone(&self.cursor_name),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OpenStatement {
#[inline]
fn eq(&self, other: &OpenStatement) -> bool {
self.cursor_name == other.cursor_name
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OpenStatement {
#[inline]
fn partial_cmp(&self, other: &OpenStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OpenStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OpenStatement {
#[inline]
fn cmp(&self, other: &OpenStatement) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.cursor_name, &other.cursor_name)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OpenStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.cursor_name, state)
}
}Hash)]
10903#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10904#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OpenStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.cursor_name, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OpenStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.cursor_name,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10905pub struct OpenStatement {
10906 pub cursor_name: Ident,
10908}
10909
10910impl fmt::Display for OpenStatement {
10911 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10912 f.write_fmt(format_args!("OPEN {0}", self.cursor_name))write!(f, "OPEN {}", self.cursor_name)
10913 }
10914}
10915
10916#[derive(#[automatically_derived]
impl ::core::fmt::Debug for NullInclusion {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
NullInclusion::IncludeNulls => "IncludeNulls",
NullInclusion::ExcludeNulls => "ExcludeNulls",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for NullInclusion {
#[inline]
fn clone(&self) -> NullInclusion {
match self {
NullInclusion::IncludeNulls => NullInclusion::IncludeNulls,
NullInclusion::ExcludeNulls => NullInclusion::ExcludeNulls,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for NullInclusion {
#[inline]
fn eq(&self, other: &NullInclusion) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for NullInclusion {
#[inline]
fn partial_cmp(&self, other: &NullInclusion)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for NullInclusion {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for NullInclusion {
#[inline]
fn cmp(&self, other: &NullInclusion) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for NullInclusion {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
10920#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10921#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for NullInclusion {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IncludeNulls => {}
Self::ExcludeNulls => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for NullInclusion {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::IncludeNulls => {}
Self::ExcludeNulls => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10922pub enum NullInclusion {
10923 IncludeNulls,
10925 ExcludeNulls,
10927}
10928
10929impl fmt::Display for NullInclusion {
10930 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10931 match self {
10932 NullInclusion::IncludeNulls => f.write_fmt(format_args!("INCLUDE NULLS"))write!(f, "INCLUDE NULLS"),
10933 NullInclusion::ExcludeNulls => f.write_fmt(format_args!("EXCLUDE NULLS"))write!(f, "EXCLUDE NULLS"),
10934 }
10935 }
10936}
10937
10938#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MemberOf {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "MemberOf",
"value", &self.value, "array", &&self.array)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for MemberOf {
#[inline]
fn clone(&self) -> MemberOf {
MemberOf {
value: ::core::clone::Clone::clone(&self.value),
array: ::core::clone::Clone::clone(&self.array),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MemberOf {
#[inline]
fn eq(&self, other: &MemberOf) -> bool {
self.value == other.value && self.array == other.array
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MemberOf {
#[inline]
fn partial_cmp(&self, other: &MemberOf)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MemberOf {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
let _: ::core::cmp::AssertParamIsEq<Box<Expr>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MemberOf {
#[inline]
fn cmp(&self, other: &MemberOf) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.value, &other.value) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.array, &other.array),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MemberOf {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.value, state);
::core::hash::Hash::hash(&self.array, state)
}
}Hash)]
10946#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10947#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MemberOf {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.value, visitor)?;
sqlparser::ast::Visit::visit(&self.array, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MemberOf {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.value, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.array, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10948pub struct MemberOf {
10949 pub value: Box<Expr>,
10951 pub array: Box<Expr>,
10953}
10954
10955impl fmt::Display for MemberOf {
10956 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10957 f.write_fmt(format_args!("{0} MEMBER OF({1})", self.value, self.array))write!(f, "{} MEMBER OF({})", self.value, self.array)
10958 }
10959}
10960
10961#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ExportData {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field3_finish(f, "ExportData",
"options", &self.options, "query", &self.query, "connection",
&&self.connection)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ExportData {
#[inline]
fn clone(&self) -> ExportData {
ExportData {
options: ::core::clone::Clone::clone(&self.options),
query: ::core::clone::Clone::clone(&self.query),
connection: ::core::clone::Clone::clone(&self.connection),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ExportData {
#[inline]
fn eq(&self, other: &ExportData) -> bool {
self.options == other.options && self.query == other.query &&
self.connection == other.connection
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ExportData {
#[inline]
fn partial_cmp(&self, other: &ExportData)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ExportData {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Vec<SqlOption>>;
let _: ::core::cmp::AssertParamIsEq<Box<Query>>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ExportData {
#[inline]
fn cmp(&self, other: &ExportData) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.options, &other.options) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.query, &other.query) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.connection, &other.connection),
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ExportData {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.options, state);
::core::hash::Hash::hash(&self.query, state);
::core::hash::Hash::hash(&self.connection, state)
}
}Hash)]
10962#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
10963#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ExportData {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.options, visitor)?;
sqlparser::ast::Visit::visit(&self.query, visitor)?;
sqlparser::ast::Visit::visit(&self.connection, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ExportData {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.options,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.query, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.connection,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
10964pub struct ExportData {
10966 pub options: Vec<SqlOption>,
10968 pub query: Box<Query>,
10970 pub connection: Option<ObjectName>,
10972}
10973
10974impl fmt::Display for ExportData {
10975 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
10976 if let Some(connection) = &self.connection {
10977 f.write_fmt(format_args!("EXPORT DATA WITH CONNECTION {2} OPTIONS({0}) AS {1}",
display_comma_separated(&self.options), self.query, connection))write!(
10978 f,
10979 "EXPORT DATA WITH CONNECTION {connection} OPTIONS({}) AS {}",
10980 display_comma_separated(&self.options),
10981 self.query
10982 )
10983 } else {
10984 f.write_fmt(format_args!("EXPORT DATA OPTIONS({0}) AS {1}",
display_comma_separated(&self.options), self.query))write!(
10985 f,
10986 "EXPORT DATA OPTIONS({}) AS {}",
10987 display_comma_separated(&self.options),
10988 self.query
10989 )
10990 }
10991 }
10992}
10993#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateUser {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["or_replace", "if_not_exists", "name", "options", "with_tags",
"tags"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.or_replace, &self.if_not_exists, &self.name,
&self.options, &self.with_tags, &&self.tags];
::core::fmt::Formatter::debug_struct_fields_finish(f, "CreateUser",
names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateUser {
#[inline]
fn clone(&self) -> CreateUser {
CreateUser {
or_replace: ::core::clone::Clone::clone(&self.or_replace),
if_not_exists: ::core::clone::Clone::clone(&self.if_not_exists),
name: ::core::clone::Clone::clone(&self.name),
options: ::core::clone::Clone::clone(&self.options),
with_tags: ::core::clone::Clone::clone(&self.with_tags),
tags: ::core::clone::Clone::clone(&self.tags),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateUser {
#[inline]
fn eq(&self, other: &CreateUser) -> bool {
self.or_replace == other.or_replace &&
self.if_not_exists == other.if_not_exists &&
self.with_tags == other.with_tags && self.name == other.name
&& self.options == other.options && self.tags == other.tags
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateUser {
#[inline]
fn partial_cmp(&self, other: &CreateUser)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateUser {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<KeyValueOptions>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateUser {
#[inline]
fn cmp(&self, other: &CreateUser) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.or_replace, &other.or_replace) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.if_not_exists,
&other.if_not_exists) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.options, &other.options) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.with_tags,
&other.with_tags) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.tags, &other.tags),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateUser {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.or_replace, state);
::core::hash::Hash::hash(&self.if_not_exists, state);
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.options, state);
::core::hash::Hash::hash(&self.with_tags, state);
::core::hash::Hash::hash(&self.tags, state)
}
}Hash)]
11002#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11003#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateUser {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.or_replace, visitor)?;
sqlparser::ast::Visit::visit(&self.if_not_exists, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.options, visitor)?;
sqlparser::ast::Visit::visit(&self.with_tags, visitor)?;
sqlparser::ast::Visit::visit(&self.tags, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateUser {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.or_replace,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.if_not_exists,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.options,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.with_tags,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.tags, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11004pub struct CreateUser {
11005 pub or_replace: bool,
11007 pub if_not_exists: bool,
11009 pub name: Ident,
11011 pub options: KeyValueOptions,
11013 pub with_tags: bool,
11015 pub tags: KeyValueOptions,
11017}
11018
11019impl fmt::Display for CreateUser {
11020 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11021 f.write_fmt(format_args!("CREATE"))write!(f, "CREATE")?;
11022 if self.or_replace {
11023 f.write_fmt(format_args!(" OR REPLACE"))write!(f, " OR REPLACE")?;
11024 }
11025 f.write_fmt(format_args!(" USER"))write!(f, " USER")?;
11026 if self.if_not_exists {
11027 f.write_fmt(format_args!(" IF NOT EXISTS"))write!(f, " IF NOT EXISTS")?;
11028 }
11029 f.write_fmt(format_args!(" {0}", self.name))write!(f, " {}", self.name)?;
11030 if !self.options.options.is_empty() {
11031 f.write_fmt(format_args!(" {0}", self.options))write!(f, " {}", self.options)?;
11032 }
11033 if !self.tags.options.is_empty() {
11034 if self.with_tags {
11035 f.write_fmt(format_args!(" WITH"))write!(f, " WITH")?;
11036 }
11037 f.write_fmt(format_args!(" TAG ({0})", self.tags))write!(f, " TAG ({})", self.tags)?;
11038 }
11039 Ok(())
11040 }
11041}
11042
11043#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUser {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["if_exists", "name", "rename_to", "reset_password",
"abort_all_queries", "add_role_delegation",
"remove_role_delegation", "enroll_mfa",
"set_default_mfa_method", "remove_mfa_method",
"modify_mfa_method", "add_mfa_method_otp", "set_policy",
"unset_policy", "set_tag", "unset_tag", "set_props",
"unset_props", "password"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.if_exists, &self.name, &self.rename_to,
&self.reset_password, &self.abort_all_queries,
&self.add_role_delegation, &self.remove_role_delegation,
&self.enroll_mfa, &self.set_default_mfa_method,
&self.remove_mfa_method, &self.modify_mfa_method,
&self.add_mfa_method_otp, &self.set_policy,
&self.unset_policy, &self.set_tag, &self.unset_tag,
&self.set_props, &self.unset_props, &&self.password];
::core::fmt::Formatter::debug_struct_fields_finish(f, "AlterUser",
names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUser {
#[inline]
fn clone(&self) -> AlterUser {
AlterUser {
if_exists: ::core::clone::Clone::clone(&self.if_exists),
name: ::core::clone::Clone::clone(&self.name),
rename_to: ::core::clone::Clone::clone(&self.rename_to),
reset_password: ::core::clone::Clone::clone(&self.reset_password),
abort_all_queries: ::core::clone::Clone::clone(&self.abort_all_queries),
add_role_delegation: ::core::clone::Clone::clone(&self.add_role_delegation),
remove_role_delegation: ::core::clone::Clone::clone(&self.remove_role_delegation),
enroll_mfa: ::core::clone::Clone::clone(&self.enroll_mfa),
set_default_mfa_method: ::core::clone::Clone::clone(&self.set_default_mfa_method),
remove_mfa_method: ::core::clone::Clone::clone(&self.remove_mfa_method),
modify_mfa_method: ::core::clone::Clone::clone(&self.modify_mfa_method),
add_mfa_method_otp: ::core::clone::Clone::clone(&self.add_mfa_method_otp),
set_policy: ::core::clone::Clone::clone(&self.set_policy),
unset_policy: ::core::clone::Clone::clone(&self.unset_policy),
set_tag: ::core::clone::Clone::clone(&self.set_tag),
unset_tag: ::core::clone::Clone::clone(&self.unset_tag),
set_props: ::core::clone::Clone::clone(&self.set_props),
unset_props: ::core::clone::Clone::clone(&self.unset_props),
password: ::core::clone::Clone::clone(&self.password),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUser {
#[inline]
fn eq(&self, other: &AlterUser) -> bool {
self.if_exists == other.if_exists &&
self.reset_password == other.reset_password &&
self.abort_all_queries == other.abort_all_queries &&
self.enroll_mfa == other.enroll_mfa &&
self.name == other.name && self.rename_to == other.rename_to
&& self.add_role_delegation == other.add_role_delegation &&
self.remove_role_delegation == other.remove_role_delegation
&&
self.set_default_mfa_method == other.set_default_mfa_method
&& self.remove_mfa_method == other.remove_mfa_method &&
self.modify_mfa_method == other.modify_mfa_method &&
self.add_mfa_method_otp == other.add_mfa_method_otp &&
self.set_policy == other.set_policy &&
self.unset_policy == other.unset_policy &&
self.set_tag == other.set_tag &&
self.unset_tag == other.unset_tag &&
self.set_props == other.set_props &&
self.unset_props == other.unset_props &&
self.password == other.password
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUser {
#[inline]
fn partial_cmp(&self, other: &AlterUser)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUser {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _:
::core::cmp::AssertParamIsEq<Option<AlterUserAddRoleDelegation>>;
let _:
::core::cmp::AssertParamIsEq<Option<AlterUserRemoveRoleDelegation>>;
let _: ::core::cmp::AssertParamIsEq<Option<MfaMethodKind>>;
let _: ::core::cmp::AssertParamIsEq<Option<MfaMethodKind>>;
let _: ::core::cmp::AssertParamIsEq<Option<AlterUserModifyMfaMethod>>;
let _: ::core::cmp::AssertParamIsEq<Option<AlterUserAddMfaMethodOtp>>;
let _: ::core::cmp::AssertParamIsEq<Option<AlterUserSetPolicy>>;
let _: ::core::cmp::AssertParamIsEq<Option<UserPolicyKind>>;
let _: ::core::cmp::AssertParamIsEq<KeyValueOptions>;
let _: ::core::cmp::AssertParamIsEq<Vec<String>>;
let _: ::core::cmp::AssertParamIsEq<Vec<String>>;
let _: ::core::cmp::AssertParamIsEq<Option<AlterUserPassword>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUser {
#[inline]
fn cmp(&self, other: &AlterUser) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.if_exists, &other.if_exists) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.rename_to,
&other.rename_to) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.reset_password,
&other.reset_password) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.abort_all_queries,
&other.abort_all_queries) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.add_role_delegation,
&other.add_role_delegation) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.remove_role_delegation,
&other.remove_role_delegation) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.enroll_mfa,
&other.enroll_mfa) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.set_default_mfa_method,
&other.set_default_mfa_method) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.remove_mfa_method,
&other.remove_mfa_method) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.modify_mfa_method,
&other.modify_mfa_method) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.add_mfa_method_otp,
&other.add_mfa_method_otp) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.set_policy,
&other.set_policy) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.unset_policy,
&other.unset_policy) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.set_tag, &other.set_tag) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.unset_tag,
&other.unset_tag) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.set_props,
&other.set_props) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.unset_props,
&other.unset_props) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.password, &other.password),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUser {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.if_exists, state);
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.rename_to, state);
::core::hash::Hash::hash(&self.reset_password, state);
::core::hash::Hash::hash(&self.abort_all_queries, state);
::core::hash::Hash::hash(&self.add_role_delegation, state);
::core::hash::Hash::hash(&self.remove_role_delegation, state);
::core::hash::Hash::hash(&self.enroll_mfa, state);
::core::hash::Hash::hash(&self.set_default_mfa_method, state);
::core::hash::Hash::hash(&self.remove_mfa_method, state);
::core::hash::Hash::hash(&self.modify_mfa_method, state);
::core::hash::Hash::hash(&self.add_mfa_method_otp, state);
::core::hash::Hash::hash(&self.set_policy, state);
::core::hash::Hash::hash(&self.unset_policy, state);
::core::hash::Hash::hash(&self.set_tag, state);
::core::hash::Hash::hash(&self.unset_tag, state);
::core::hash::Hash::hash(&self.set_props, state);
::core::hash::Hash::hash(&self.unset_props, state);
::core::hash::Hash::hash(&self.password, state)
}
}Hash)]
11055#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11056#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUser {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.if_exists, visitor)?;
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.rename_to, visitor)?;
sqlparser::ast::Visit::visit(&self.reset_password,
visitor)?;
sqlparser::ast::Visit::visit(&self.abort_all_queries,
visitor)?;
sqlparser::ast::Visit::visit(&self.add_role_delegation,
visitor)?;
sqlparser::ast::Visit::visit(&self.remove_role_delegation,
visitor)?;
sqlparser::ast::Visit::visit(&self.enroll_mfa, visitor)?;
sqlparser::ast::Visit::visit(&self.set_default_mfa_method,
visitor)?;
sqlparser::ast::Visit::visit(&self.remove_mfa_method,
visitor)?;
sqlparser::ast::Visit::visit(&self.modify_mfa_method,
visitor)?;
sqlparser::ast::Visit::visit(&self.add_mfa_method_otp,
visitor)?;
sqlparser::ast::Visit::visit(&self.set_policy, visitor)?;
sqlparser::ast::Visit::visit(&self.unset_policy, visitor)?;
sqlparser::ast::Visit::visit(&self.set_tag, visitor)?;
sqlparser::ast::Visit::visit(&self.unset_tag, visitor)?;
sqlparser::ast::Visit::visit(&self.set_props, visitor)?;
sqlparser::ast::Visit::visit(&self.unset_props, visitor)?;
sqlparser::ast::Visit::visit(&self.password, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUser {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.if_exists,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.rename_to,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.reset_password,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.abort_all_queries,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.add_role_delegation,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.remove_role_delegation,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.enroll_mfa,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.set_default_mfa_method,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.remove_mfa_method,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.modify_mfa_method,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.add_mfa_method_otp,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.set_policy,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.unset_policy,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.set_tag,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.unset_tag,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.set_props,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.unset_props,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.password,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11057pub struct AlterUser {
11058 pub if_exists: bool,
11060 pub name: Ident,
11062 pub rename_to: Option<Ident>,
11065 pub reset_password: bool,
11067 pub abort_all_queries: bool,
11069 pub add_role_delegation: Option<AlterUserAddRoleDelegation>,
11071 pub remove_role_delegation: Option<AlterUserRemoveRoleDelegation>,
11073 pub enroll_mfa: bool,
11075 pub set_default_mfa_method: Option<MfaMethodKind>,
11077 pub remove_mfa_method: Option<MfaMethodKind>,
11079 pub modify_mfa_method: Option<AlterUserModifyMfaMethod>,
11081 pub add_mfa_method_otp: Option<AlterUserAddMfaMethodOtp>,
11083 pub set_policy: Option<AlterUserSetPolicy>,
11085 pub unset_policy: Option<UserPolicyKind>,
11087 pub set_tag: KeyValueOptions,
11089 pub unset_tag: Vec<String>,
11091 pub set_props: KeyValueOptions,
11093 pub unset_props: Vec<String>,
11095 pub password: Option<AlterUserPassword>,
11097}
11098
11099#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUserAddRoleDelegation {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterUserAddRoleDelegation", "role", &self.role, "integration",
&&self.integration)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUserAddRoleDelegation {
#[inline]
fn clone(&self) -> AlterUserAddRoleDelegation {
AlterUserAddRoleDelegation {
role: ::core::clone::Clone::clone(&self.role),
integration: ::core::clone::Clone::clone(&self.integration),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUserAddRoleDelegation {
#[inline]
fn eq(&self, other: &AlterUserAddRoleDelegation) -> bool {
self.role == other.role && self.integration == other.integration
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUserAddRoleDelegation {
#[inline]
fn partial_cmp(&self, other: &AlterUserAddRoleDelegation)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUserAddRoleDelegation {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUserAddRoleDelegation {
#[inline]
fn cmp(&self, other: &AlterUserAddRoleDelegation)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.role, &other.role) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.integration, &other.integration),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUserAddRoleDelegation {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.role, state);
::core::hash::Hash::hash(&self.integration, state)
}
}Hash)]
11103#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11104#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUserAddRoleDelegation {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.role, visitor)?;
sqlparser::ast::Visit::visit(&self.integration, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUserAddRoleDelegation {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.role, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.integration,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11105pub struct AlterUserAddRoleDelegation {
11106 pub role: Ident,
11108 pub integration: Ident,
11110}
11111
11112#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUserRemoveRoleDelegation {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterUserRemoveRoleDelegation", "role", &self.role,
"integration", &&self.integration)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUserRemoveRoleDelegation {
#[inline]
fn clone(&self) -> AlterUserRemoveRoleDelegation {
AlterUserRemoveRoleDelegation {
role: ::core::clone::Clone::clone(&self.role),
integration: ::core::clone::Clone::clone(&self.integration),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUserRemoveRoleDelegation {
#[inline]
fn eq(&self, other: &AlterUserRemoveRoleDelegation) -> bool {
self.role == other.role && self.integration == other.integration
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUserRemoveRoleDelegation {
#[inline]
fn partial_cmp(&self, other: &AlterUserRemoveRoleDelegation)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUserRemoveRoleDelegation {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<Ident>>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUserRemoveRoleDelegation {
#[inline]
fn cmp(&self, other: &AlterUserRemoveRoleDelegation)
-> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.role, &other.role) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.integration, &other.integration),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUserRemoveRoleDelegation {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.role, state);
::core::hash::Hash::hash(&self.integration, state)
}
}Hash)]
11116#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11117#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUserRemoveRoleDelegation {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.role, visitor)?;
sqlparser::ast::Visit::visit(&self.integration, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUserRemoveRoleDelegation {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.role, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.integration,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11118pub struct AlterUserRemoveRoleDelegation {
11119 pub role: Option<Ident>,
11121 pub integration: Ident,
11123}
11124
11125#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUserAddMfaMethodOtp {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"AlterUserAddMfaMethodOtp", "count", &&self.count)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUserAddMfaMethodOtp {
#[inline]
fn clone(&self) -> AlterUserAddMfaMethodOtp {
AlterUserAddMfaMethodOtp {
count: ::core::clone::Clone::clone(&self.count),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUserAddMfaMethodOtp {
#[inline]
fn eq(&self, other: &AlterUserAddMfaMethodOtp) -> bool {
self.count == other.count
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUserAddMfaMethodOtp {
#[inline]
fn partial_cmp(&self, other: &AlterUserAddMfaMethodOtp)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUserAddMfaMethodOtp {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUserAddMfaMethodOtp {
#[inline]
fn cmp(&self, other: &AlterUserAddMfaMethodOtp) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.count, &other.count)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUserAddMfaMethodOtp {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.count, state)
}
}Hash)]
11129#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11130#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUserAddMfaMethodOtp {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.count, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUserAddMfaMethodOtp {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.count, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11131pub struct AlterUserAddMfaMethodOtp {
11132 pub count: Option<Value>,
11134}
11135
11136#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUserModifyMfaMethod {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterUserModifyMfaMethod", "method", &self.method, "comment",
&&self.comment)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUserModifyMfaMethod {
#[inline]
fn clone(&self) -> AlterUserModifyMfaMethod {
AlterUserModifyMfaMethod {
method: ::core::clone::Clone::clone(&self.method),
comment: ::core::clone::Clone::clone(&self.comment),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUserModifyMfaMethod {
#[inline]
fn eq(&self, other: &AlterUserModifyMfaMethod) -> bool {
self.method == other.method && self.comment == other.comment
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUserModifyMfaMethod {
#[inline]
fn partial_cmp(&self, other: &AlterUserModifyMfaMethod)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUserModifyMfaMethod {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<MfaMethodKind>;
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUserModifyMfaMethod {
#[inline]
fn cmp(&self, other: &AlterUserModifyMfaMethod) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.method, &other.method) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.comment, &other.comment),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUserModifyMfaMethod {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.method, state);
::core::hash::Hash::hash(&self.comment, state)
}
}Hash)]
11140#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11141#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUserModifyMfaMethod {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.method, visitor)?;
sqlparser::ast::Visit::visit(&self.comment, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUserModifyMfaMethod {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.method, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.comment,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11142pub struct AlterUserModifyMfaMethod {
11143 pub method: MfaMethodKind,
11145 pub comment: String,
11147}
11148
11149#[derive(#[automatically_derived]
impl ::core::fmt::Debug for MfaMethodKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
MfaMethodKind::PassKey => "PassKey",
MfaMethodKind::Totp => "Totp",
MfaMethodKind::Duo => "Duo",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for MfaMethodKind {
#[inline]
fn clone(&self) -> MfaMethodKind {
match self {
MfaMethodKind::PassKey => MfaMethodKind::PassKey,
MfaMethodKind::Totp => MfaMethodKind::Totp,
MfaMethodKind::Duo => MfaMethodKind::Duo,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for MfaMethodKind {
#[inline]
fn eq(&self, other: &MfaMethodKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for MfaMethodKind {
#[inline]
fn partial_cmp(&self, other: &MfaMethodKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for MfaMethodKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for MfaMethodKind {
#[inline]
fn cmp(&self, other: &MfaMethodKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for MfaMethodKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
11151#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11152#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for MfaMethodKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::PassKey => {}
Self::Totp => {}
Self::Duo => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for MfaMethodKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::PassKey => {}
Self::Totp => {}
Self::Duo => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11153pub enum MfaMethodKind {
11154 PassKey,
11156 Totp,
11158 Duo,
11160}
11161
11162impl fmt::Display for MfaMethodKind {
11163 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11164 match self {
11165 MfaMethodKind::PassKey => f.write_fmt(format_args!("PASSKEY"))write!(f, "PASSKEY"),
11166 MfaMethodKind::Totp => f.write_fmt(format_args!("TOTP"))write!(f, "TOTP"),
11167 MfaMethodKind::Duo => f.write_fmt(format_args!("DUO"))write!(f, "DUO"),
11168 }
11169 }
11170}
11171
11172#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUserSetPolicy {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterUserSetPolicy", "policy_kind", &self.policy_kind, "policy",
&&self.policy)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUserSetPolicy {
#[inline]
fn clone(&self) -> AlterUserSetPolicy {
AlterUserSetPolicy {
policy_kind: ::core::clone::Clone::clone(&self.policy_kind),
policy: ::core::clone::Clone::clone(&self.policy),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUserSetPolicy {
#[inline]
fn eq(&self, other: &AlterUserSetPolicy) -> bool {
self.policy_kind == other.policy_kind && self.policy == other.policy
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUserSetPolicy {
#[inline]
fn partial_cmp(&self, other: &AlterUserSetPolicy)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUserSetPolicy {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<UserPolicyKind>;
let _: ::core::cmp::AssertParamIsEq<Ident>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUserSetPolicy {
#[inline]
fn cmp(&self, other: &AlterUserSetPolicy) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.policy_kind, &other.policy_kind) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.policy, &other.policy),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUserSetPolicy {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.policy_kind, state);
::core::hash::Hash::hash(&self.policy, state)
}
}Hash)]
11176#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11177#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUserSetPolicy {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.policy_kind, visitor)?;
sqlparser::ast::Visit::visit(&self.policy, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUserSetPolicy {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.policy_kind,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.policy, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11178pub struct AlterUserSetPolicy {
11179 pub policy_kind: UserPolicyKind,
11181 pub policy: Ident,
11183}
11184
11185#[derive(#[automatically_derived]
impl ::core::fmt::Debug for UserPolicyKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
UserPolicyKind::Authentication => "Authentication",
UserPolicyKind::Password => "Password",
UserPolicyKind::Session => "Session",
})
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for UserPolicyKind {
#[inline]
fn clone(&self) -> UserPolicyKind {
match self {
UserPolicyKind::Authentication => UserPolicyKind::Authentication,
UserPolicyKind::Password => UserPolicyKind::Password,
UserPolicyKind::Session => UserPolicyKind::Session,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for UserPolicyKind {
#[inline]
fn eq(&self, other: &UserPolicyKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for UserPolicyKind {
#[inline]
fn partial_cmp(&self, other: &UserPolicyKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for UserPolicyKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for UserPolicyKind {
#[inline]
fn cmp(&self, other: &UserPolicyKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for UserPolicyKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
11187#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11188#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for UserPolicyKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Authentication => {}
Self::Password => {}
Self::Session => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for UserPolicyKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Authentication => {}
Self::Password => {}
Self::Session => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11189pub enum UserPolicyKind {
11190 Authentication,
11192 Password,
11194 Session,
11196}
11197
11198impl fmt::Display for UserPolicyKind {
11199 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11200 match self {
11201 UserPolicyKind::Authentication => f.write_fmt(format_args!("AUTHENTICATION"))write!(f, "AUTHENTICATION"),
11202 UserPolicyKind::Password => f.write_fmt(format_args!("PASSWORD"))write!(f, "PASSWORD"),
11203 UserPolicyKind::Session => f.write_fmt(format_args!("SESSION"))write!(f, "SESSION"),
11204 }
11205 }
11206}
11207
11208impl fmt::Display for AlterUser {
11209 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11210 f.write_fmt(format_args!("ALTER"))write!(f, "ALTER")?;
11211 f.write_fmt(format_args!(" USER"))write!(f, " USER")?;
11212 if self.if_exists {
11213 f.write_fmt(format_args!(" IF EXISTS"))write!(f, " IF EXISTS")?;
11214 }
11215 f.write_fmt(format_args!(" {0}", self.name))write!(f, " {}", self.name)?;
11216 if let Some(new_name) = &self.rename_to {
11217 f.write_fmt(format_args!(" RENAME TO {0}", new_name))write!(f, " RENAME TO {new_name}")?;
11218 }
11219 if self.reset_password {
11220 f.write_fmt(format_args!(" RESET PASSWORD"))write!(f, " RESET PASSWORD")?;
11221 }
11222 if self.abort_all_queries {
11223 f.write_fmt(format_args!(" ABORT ALL QUERIES"))write!(f, " ABORT ALL QUERIES")?;
11224 }
11225 if let Some(role_delegation) = &self.add_role_delegation {
11226 let role = &role_delegation.role;
11227 let integration = &role_delegation.integration;
11228 f.write_fmt(format_args!(" ADD DELEGATED AUTHORIZATION OF ROLE {0} TO SECURITY INTEGRATION {1}",
role, integration))write!(
11229 f,
11230 " ADD DELEGATED AUTHORIZATION OF ROLE {role} TO SECURITY INTEGRATION {integration}"
11231 )?;
11232 }
11233 if let Some(role_delegation) = &self.remove_role_delegation {
11234 f.write_fmt(format_args!(" REMOVE DELEGATED"))write!(f, " REMOVE DELEGATED")?;
11235 match &role_delegation.role {
11236 Some(role) => f.write_fmt(format_args!(" AUTHORIZATION OF ROLE {0}", role))write!(f, " AUTHORIZATION OF ROLE {role}")?,
11237 None => f.write_fmt(format_args!(" AUTHORIZATIONS"))write!(f, " AUTHORIZATIONS")?,
11238 }
11239 let integration = &role_delegation.integration;
11240 f.write_fmt(format_args!(" FROM SECURITY INTEGRATION {0}", integration))write!(f, " FROM SECURITY INTEGRATION {integration}")?;
11241 }
11242 if self.enroll_mfa {
11243 f.write_fmt(format_args!(" ENROLL MFA"))write!(f, " ENROLL MFA")?;
11244 }
11245 if let Some(method) = &self.set_default_mfa_method {
11246 f.write_fmt(format_args!(" SET DEFAULT_MFA_METHOD {0}", method))write!(f, " SET DEFAULT_MFA_METHOD {method}")?
11247 }
11248 if let Some(method) = &self.remove_mfa_method {
11249 f.write_fmt(format_args!(" REMOVE MFA METHOD {0}", method))write!(f, " REMOVE MFA METHOD {method}")?;
11250 }
11251 if let Some(modify) = &self.modify_mfa_method {
11252 let method = &modify.method;
11253 let comment = &modify.comment;
11254 f.write_fmt(format_args!(" MODIFY MFA METHOD {1} SET COMMENT \'{0}\'",
value::escape_single_quote_string(comment), method))write!(
11255 f,
11256 " MODIFY MFA METHOD {method} SET COMMENT '{}'",
11257 value::escape_single_quote_string(comment)
11258 )?;
11259 }
11260 if let Some(add_mfa_method_otp) = &self.add_mfa_method_otp {
11261 f.write_fmt(format_args!(" ADD MFA METHOD OTP"))write!(f, " ADD MFA METHOD OTP")?;
11262 if let Some(count) = &add_mfa_method_otp.count {
11263 f.write_fmt(format_args!(" COUNT = {0}", count))write!(f, " COUNT = {count}")?;
11264 }
11265 }
11266 if let Some(policy) = &self.set_policy {
11267 let policy_kind = &policy.policy_kind;
11268 let name = &policy.policy;
11269 f.write_fmt(format_args!(" SET {0} POLICY {1}", policy_kind, name))write!(f, " SET {policy_kind} POLICY {name}")?;
11270 }
11271 if let Some(policy_kind) = &self.unset_policy {
11272 f.write_fmt(format_args!(" UNSET {0} POLICY", policy_kind))write!(f, " UNSET {policy_kind} POLICY")?;
11273 }
11274 if !self.set_tag.options.is_empty() {
11275 f.write_fmt(format_args!(" SET TAG {0}", self.set_tag))write!(f, " SET TAG {}", self.set_tag)?;
11276 }
11277 if !self.unset_tag.is_empty() {
11278 f.write_fmt(format_args!(" UNSET TAG {0}",
display_comma_separated(&self.unset_tag)))write!(f, " UNSET TAG {}", display_comma_separated(&self.unset_tag))?;
11279 }
11280 let has_props = !self.set_props.options.is_empty();
11281 if has_props {
11282 f.write_fmt(format_args!(" SET"))write!(f, " SET")?;
11283 f.write_fmt(format_args!(" {0}", &self.set_props))write!(f, " {}", &self.set_props)?;
11284 }
11285 if !self.unset_props.is_empty() {
11286 f.write_fmt(format_args!(" UNSET {0}",
display_comma_separated(&self.unset_props)))write!(f, " UNSET {}", display_comma_separated(&self.unset_props))?;
11287 }
11288 if let Some(password) = &self.password {
11289 f.write_fmt(format_args!(" {0}", password))write!(f, " {}", password)?;
11290 }
11291 Ok(())
11292 }
11293}
11294
11295#[derive(#[automatically_derived]
impl ::core::fmt::Debug for AlterUserPassword {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"AlterUserPassword", "encrypted", &self.encrypted, "password",
&&self.password)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for AlterUserPassword {
#[inline]
fn clone(&self) -> AlterUserPassword {
AlterUserPassword {
encrypted: ::core::clone::Clone::clone(&self.encrypted),
password: ::core::clone::Clone::clone(&self.password),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for AlterUserPassword {
#[inline]
fn eq(&self, other: &AlterUserPassword) -> bool {
self.encrypted == other.encrypted && self.password == other.password
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for AlterUserPassword {
#[inline]
fn partial_cmp(&self, other: &AlterUserPassword)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for AlterUserPassword {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Option<String>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for AlterUserPassword {
#[inline]
fn cmp(&self, other: &AlterUserPassword) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.encrypted, &other.encrypted) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.password, &other.password),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for AlterUserPassword {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.encrypted, state);
::core::hash::Hash::hash(&self.password, state)
}
}Hash)]
11299#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11300#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for AlterUserPassword {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.encrypted, visitor)?;
sqlparser::ast::Visit::visit(&self.password, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for AlterUserPassword {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.encrypted,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.password,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11301pub struct AlterUserPassword {
11302 pub encrypted: bool,
11304 pub password: Option<String>,
11306}
11307
11308impl Display for AlterUserPassword {
11309 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11310 if self.encrypted {
11311 f.write_fmt(format_args!("ENCRYPTED "))write!(f, "ENCRYPTED ")?;
11312 }
11313 f.write_fmt(format_args!("PASSWORD"))write!(f, "PASSWORD")?;
11314 match &self.password {
11315 None => f.write_fmt(format_args!(" NULL"))write!(f, " NULL")?,
11316 Some(password) => f.write_fmt(format_args!(" \'{0}\'",
value::escape_single_quote_string(password)))write!(f, " '{}'", value::escape_single_quote_string(password))?,
11317 }
11318 Ok(())
11319 }
11320}
11321
11322#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateTableLikeKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
CreateTableLikeKind::Parenthesized(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"Parenthesized", &__self_0),
CreateTableLikeKind::Plain(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f, "Plain",
&__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateTableLikeKind {
#[inline]
fn clone(&self) -> CreateTableLikeKind {
match self {
CreateTableLikeKind::Parenthesized(__self_0) =>
CreateTableLikeKind::Parenthesized(::core::clone::Clone::clone(__self_0)),
CreateTableLikeKind::Plain(__self_0) =>
CreateTableLikeKind::Plain(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateTableLikeKind {
#[inline]
fn eq(&self, other: &CreateTableLikeKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(CreateTableLikeKind::Parenthesized(__self_0),
CreateTableLikeKind::Parenthesized(__arg1_0)) =>
__self_0 == __arg1_0,
(CreateTableLikeKind::Plain(__self_0),
CreateTableLikeKind::Plain(__arg1_0)) =>
__self_0 == __arg1_0,
_ => unsafe { ::core::intrinsics::unreachable() }
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateTableLikeKind {
#[inline]
fn partial_cmp(&self, other: &CreateTableLikeKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateTableLikeKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<CreateTableLike>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateTableLikeKind {
#[inline]
fn cmp(&self, other: &CreateTableLikeKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(CreateTableLikeKind::Parenthesized(__self_0),
CreateTableLikeKind::Parenthesized(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
(CreateTableLikeKind::Plain(__self_0),
CreateTableLikeKind::Plain(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => unsafe { ::core::intrinsics::unreachable() }
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateTableLikeKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
CreateTableLikeKind::Parenthesized(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
CreateTableLikeKind::Plain(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
}
}
}Hash)]
11327#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11328#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateTableLikeKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Parenthesized(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
Self::Plain(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateTableLikeKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Parenthesized(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
Self::Plain(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11329pub enum CreateTableLikeKind {
11330 Parenthesized(CreateTableLike),
11335 Plain(CreateTableLike),
11341}
11342
11343#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateTableLikeDefaults {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
CreateTableLikeDefaults::Including => "Including",
CreateTableLikeDefaults::Excluding => "Excluding",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for CreateTableLikeDefaults { }Copy, #[automatically_derived]
impl ::core::clone::Clone for CreateTableLikeDefaults {
#[inline]
fn clone(&self) -> CreateTableLikeDefaults { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateTableLikeDefaults {
#[inline]
fn eq(&self, other: &CreateTableLikeDefaults) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateTableLikeDefaults {
#[inline]
fn partial_cmp(&self, other: &CreateTableLikeDefaults)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateTableLikeDefaults {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateTableLikeDefaults {
#[inline]
fn cmp(&self, other: &CreateTableLikeDefaults) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateTableLikeDefaults {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
11344#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11345#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateTableLikeDefaults {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Including => {} Self::Excluding => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateTableLikeDefaults {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::Including => {} Self::Excluding => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11346pub enum CreateTableLikeDefaults {
11348 Including,
11350 Excluding,
11352}
11353
11354impl fmt::Display for CreateTableLikeDefaults {
11355 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11356 match self {
11357 CreateTableLikeDefaults::Including => f.write_fmt(format_args!("INCLUDING DEFAULTS"))write!(f, "INCLUDING DEFAULTS"),
11358 CreateTableLikeDefaults::Excluding => f.write_fmt(format_args!("EXCLUDING DEFAULTS"))write!(f, "EXCLUDING DEFAULTS"),
11359 }
11360 }
11361}
11362
11363#[derive(#[automatically_derived]
impl ::core::fmt::Debug for CreateTableLike {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f,
"CreateTableLike", "name", &self.name, "defaults",
&&self.defaults)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for CreateTableLike {
#[inline]
fn clone(&self) -> CreateTableLike {
CreateTableLike {
name: ::core::clone::Clone::clone(&self.name),
defaults: ::core::clone::Clone::clone(&self.defaults),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for CreateTableLike {
#[inline]
fn eq(&self, other: &CreateTableLike) -> bool {
self.name == other.name && self.defaults == other.defaults
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for CreateTableLike {
#[inline]
fn partial_cmp(&self, other: &CreateTableLike)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for CreateTableLike {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
let _: ::core::cmp::AssertParamIsEq<Option<CreateTableLikeDefaults>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for CreateTableLike {
#[inline]
fn cmp(&self, other: &CreateTableLike) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.name, &other.name) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.defaults, &other.defaults),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for CreateTableLike {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.name, state);
::core::hash::Hash::hash(&self.defaults, state)
}
}Hash)]
11364#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11365#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for CreateTableLike {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.name, visitor)?;
sqlparser::ast::Visit::visit(&self.defaults, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for CreateTableLike {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.name, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.defaults,
visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11366pub struct CreateTableLike {
11368 pub name: ObjectName,
11370 pub defaults: Option<CreateTableLikeDefaults>,
11372}
11373
11374impl fmt::Display for CreateTableLike {
11375 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11376 f.write_fmt(format_args!("LIKE {0}", self.name))write!(f, "LIKE {}", self.name)?;
11377 if let Some(defaults) = &self.defaults {
11378 f.write_fmt(format_args!(" {0}", defaults))write!(f, " {defaults}")?;
11379 }
11380 Ok(())
11381 }
11382}
11383
11384#[derive(#[automatically_derived]
impl ::core::fmt::Debug for RefreshModeKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
RefreshModeKind::Auto => "Auto",
RefreshModeKind::Full => "Full",
RefreshModeKind::Incremental => "Incremental",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for RefreshModeKind { }Copy, #[automatically_derived]
impl ::core::clone::Clone for RefreshModeKind {
#[inline]
fn clone(&self) -> RefreshModeKind { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for RefreshModeKind {
#[inline]
fn eq(&self, other: &RefreshModeKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for RefreshModeKind {
#[inline]
fn partial_cmp(&self, other: &RefreshModeKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for RefreshModeKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for RefreshModeKind {
#[inline]
fn cmp(&self, other: &RefreshModeKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for RefreshModeKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
11388#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11389#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for RefreshModeKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Auto => {}
Self::Full => {}
Self::Incremental => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for RefreshModeKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::Auto => {}
Self::Full => {}
Self::Incremental => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11390pub enum RefreshModeKind {
11391 Auto,
11393 Full,
11395 Incremental,
11397}
11398
11399impl fmt::Display for RefreshModeKind {
11400 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11401 match self {
11402 RefreshModeKind::Auto => f.write_fmt(format_args!("AUTO"))write!(f, "AUTO"),
11403 RefreshModeKind::Full => f.write_fmt(format_args!("FULL"))write!(f, "FULL"),
11404 RefreshModeKind::Incremental => f.write_fmt(format_args!("INCREMENTAL"))write!(f, "INCREMENTAL"),
11405 }
11406 }
11407}
11408
11409#[derive(#[automatically_derived]
impl ::core::fmt::Debug for InitializeKind {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::write_str(f,
match self {
InitializeKind::OnCreate => "OnCreate",
InitializeKind::OnSchedule => "OnSchedule",
})
}
}Debug, #[automatically_derived]
impl ::core::marker::Copy for InitializeKind { }Copy, #[automatically_derived]
impl ::core::clone::Clone for InitializeKind {
#[inline]
fn clone(&self) -> InitializeKind { *self }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for InitializeKind {
#[inline]
fn eq(&self, other: &InitializeKind) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for InitializeKind {
#[inline]
fn partial_cmp(&self, other: &InitializeKind)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for InitializeKind {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for InitializeKind {
#[inline]
fn cmp(&self, other: &InitializeKind) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for InitializeKind {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state)
}
}Hash)]
11413#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11414#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for InitializeKind {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::OnCreate => {} Self::OnSchedule => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for InitializeKind {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self { Self::OnCreate => {} Self::OnSchedule => {} }
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11415pub enum InitializeKind {
11416 OnCreate,
11418 OnSchedule,
11420}
11421
11422impl fmt::Display for InitializeKind {
11423 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11424 match self {
11425 InitializeKind::OnCreate => f.write_fmt(format_args!("ON_CREATE"))write!(f, "ON_CREATE"),
11426 InitializeKind::OnSchedule => f.write_fmt(format_args!("ON_SCHEDULE"))write!(f, "ON_SCHEDULE"),
11427 }
11428 }
11429}
11430
11431#[derive(#[automatically_derived]
impl ::core::fmt::Debug for VacuumStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
let names: &'static _ =
&["full", "sort_only", "delete_only", "reindex", "recluster",
"table_name", "threshold", "boost"];
let values: &[&dyn ::core::fmt::Debug] =
&[&self.full, &self.sort_only, &self.delete_only, &self.reindex,
&self.recluster, &self.table_name, &self.threshold,
&&self.boost];
::core::fmt::Formatter::debug_struct_fields_finish(f,
"VacuumStatement", names, values)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for VacuumStatement {
#[inline]
fn clone(&self) -> VacuumStatement {
VacuumStatement {
full: ::core::clone::Clone::clone(&self.full),
sort_only: ::core::clone::Clone::clone(&self.sort_only),
delete_only: ::core::clone::Clone::clone(&self.delete_only),
reindex: ::core::clone::Clone::clone(&self.reindex),
recluster: ::core::clone::Clone::clone(&self.recluster),
table_name: ::core::clone::Clone::clone(&self.table_name),
threshold: ::core::clone::Clone::clone(&self.threshold),
boost: ::core::clone::Clone::clone(&self.boost),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for VacuumStatement {
#[inline]
fn eq(&self, other: &VacuumStatement) -> bool {
self.full == other.full && self.sort_only == other.sort_only &&
self.delete_only == other.delete_only &&
self.reindex == other.reindex &&
self.recluster == other.recluster &&
self.boost == other.boost &&
self.table_name == other.table_name &&
self.threshold == other.threshold
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for VacuumStatement {
#[inline]
fn partial_cmp(&self, other: &VacuumStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for VacuumStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<bool>;
let _: ::core::cmp::AssertParamIsEq<Option<ObjectName>>;
let _: ::core::cmp::AssertParamIsEq<Option<Value>>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for VacuumStatement {
#[inline]
fn cmp(&self, other: &VacuumStatement) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.full, &other.full) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.sort_only, &other.sort_only)
{
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.delete_only,
&other.delete_only) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.reindex, &other.reindex) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.recluster,
&other.recluster) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.table_name,
&other.table_name) {
::core::cmp::Ordering::Equal =>
match ::core::cmp::Ord::cmp(&self.threshold,
&other.threshold) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.boost, &other.boost),
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for VacuumStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.full, state);
::core::hash::Hash::hash(&self.sort_only, state);
::core::hash::Hash::hash(&self.delete_only, state);
::core::hash::Hash::hash(&self.reindex, state);
::core::hash::Hash::hash(&self.recluster, state);
::core::hash::Hash::hash(&self.table_name, state);
::core::hash::Hash::hash(&self.threshold, state);
::core::hash::Hash::hash(&self.boost, state)
}
}Hash)]
11438#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11439#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for VacuumStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.full, visitor)?;
sqlparser::ast::Visit::visit(&self.sort_only, visitor)?;
sqlparser::ast::Visit::visit(&self.delete_only, visitor)?;
sqlparser::ast::Visit::visit(&self.reindex, visitor)?;
sqlparser::ast::Visit::visit(&self.recluster, visitor)?;
sqlparser::ast::Visit::visit(&self.table_name, visitor)?;
sqlparser::ast::Visit::visit(&self.threshold, visitor)?;
sqlparser::ast::Visit::visit(&self.boost, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for VacuumStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.full, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.sort_only,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.delete_only,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.reindex,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.recluster,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.table_name,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.threshold,
visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.boost, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11440pub struct VacuumStatement {
11441 pub full: bool,
11443 pub sort_only: bool,
11445 pub delete_only: bool,
11447 pub reindex: bool,
11449 pub recluster: bool,
11451 pub table_name: Option<ObjectName>,
11453 pub threshold: Option<Value>,
11455 pub boost: bool,
11457}
11458
11459impl fmt::Display for VacuumStatement {
11460 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11461 f.write_fmt(format_args!("VACUUM{0}{1}{2}{3}{4}",
if self.full { " FULL" } else { "" },
if self.sort_only { " SORT ONLY" } else { "" },
if self.delete_only { " DELETE ONLY" } else { "" },
if self.reindex { " REINDEX" } else { "" },
if self.recluster { " RECLUSTER" } else { "" }))write!(
11462 f,
11463 "VACUUM{}{}{}{}{}",
11464 if self.full { " FULL" } else { "" },
11465 if self.sort_only { " SORT ONLY" } else { "" },
11466 if self.delete_only { " DELETE ONLY" } else { "" },
11467 if self.reindex { " REINDEX" } else { "" },
11468 if self.recluster { " RECLUSTER" } else { "" },
11469 )?;
11470 if let Some(table_name) = &self.table_name {
11471 f.write_fmt(format_args!(" {0}", table_name))write!(f, " {table_name}")?;
11472 }
11473 if let Some(threshold) = &self.threshold {
11474 f.write_fmt(format_args!(" TO {0} PERCENT", threshold))write!(f, " TO {threshold} PERCENT")?;
11475 }
11476 if self.boost {
11477 f.write_fmt(format_args!(" BOOST"))write!(f, " BOOST")?;
11478 }
11479 Ok(())
11480 }
11481}
11482
11483#[derive(#[automatically_derived]
impl ::core::fmt::Debug for Reset {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
Reset::ALL => ::core::fmt::Formatter::write_str(f, "ALL"),
Reset::ConfigurationParameter(__self_0) =>
::core::fmt::Formatter::debug_tuple_field1_finish(f,
"ConfigurationParameter", &__self_0),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for Reset {
#[inline]
fn clone(&self) -> Reset {
match self {
Reset::ALL => Reset::ALL,
Reset::ConfigurationParameter(__self_0) =>
Reset::ConfigurationParameter(::core::clone::Clone::clone(__self_0)),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for Reset {
#[inline]
fn eq(&self, other: &Reset) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(Reset::ConfigurationParameter(__self_0),
Reset::ConfigurationParameter(__arg1_0)) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for Reset {
#[inline]
fn partial_cmp(&self, other: &Reset)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for Reset {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<ObjectName>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for Reset {
#[inline]
fn cmp(&self, other: &Reset) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(Reset::ConfigurationParameter(__self_0),
Reset::ConfigurationParameter(__arg1_0)) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for Reset {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
Reset::ConfigurationParameter(__self_0) =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
11485#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11486#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for Reset {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ALL => {}
Self::ConfigurationParameter(_0) => {
sqlparser::ast::Visit::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for Reset {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::ALL => {}
Self::ConfigurationParameter(_0) => {
sqlparser::ast::VisitMut::visit(_0, visitor)?;
}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11487pub enum Reset {
11488 ALL,
11490
11491 ConfigurationParameter(ObjectName),
11493}
11494
11495#[derive(#[automatically_derived]
impl ::core::fmt::Debug for ResetStatement {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field1_finish(f,
"ResetStatement", "reset", &&self.reset)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for ResetStatement {
#[inline]
fn clone(&self) -> ResetStatement {
ResetStatement { reset: ::core::clone::Clone::clone(&self.reset) }
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for ResetStatement {
#[inline]
fn eq(&self, other: &ResetStatement) -> bool { self.reset == other.reset }
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for ResetStatement {
#[inline]
fn partial_cmp(&self, other: &ResetStatement)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for ResetStatement {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<Reset>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for ResetStatement {
#[inline]
fn cmp(&self, other: &ResetStatement) -> ::core::cmp::Ordering {
::core::cmp::Ord::cmp(&self.reset, &other.reset)
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for ResetStatement {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.reset, state)
}
}Hash)]
11500#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11501#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for ResetStatement {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.reset, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for ResetStatement {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.reset, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11502pub struct ResetStatement {
11503 pub reset: Reset,
11505}
11506
11507#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OptimizerHint {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
::core::fmt::Formatter::debug_struct_field2_finish(f, "OptimizerHint",
"text", &self.text, "style", &&self.style)
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OptimizerHint {
#[inline]
fn clone(&self) -> OptimizerHint {
OptimizerHint {
text: ::core::clone::Clone::clone(&self.text),
style: ::core::clone::Clone::clone(&self.style),
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OptimizerHint {
#[inline]
fn eq(&self, other: &OptimizerHint) -> bool {
self.text == other.text && self.style == other.style
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OptimizerHint {
#[inline]
fn partial_cmp(&self, other: &OptimizerHint)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OptimizerHint {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
let _: ::core::cmp::AssertParamIsEq<OptimizerHintStyle>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OptimizerHint {
#[inline]
fn cmp(&self, other: &OptimizerHint) -> ::core::cmp::Ordering {
match ::core::cmp::Ord::cmp(&self.text, &other.text) {
::core::cmp::Ordering::Equal =>
::core::cmp::Ord::cmp(&self.style, &other.style),
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OptimizerHint {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
::core::hash::Hash::hash(&self.text, state);
::core::hash::Hash::hash(&self.style, state)
}
}Hash)]
11513#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11514#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OptimizerHint {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::Visit::visit(&self.text, visitor)?;
sqlparser::ast::Visit::visit(&self.style, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OptimizerHint {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
sqlparser::ast::VisitMut::visit(&mut self.text, visitor)?;
sqlparser::ast::VisitMut::visit(&mut self.style, visitor)?;
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11515pub struct OptimizerHint {
11516 pub text: String,
11518 pub style: OptimizerHintStyle,
11523}
11524
11525#[derive(#[automatically_derived]
impl ::core::fmt::Debug for OptimizerHintStyle {
#[inline]
fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
match self {
OptimizerHintStyle::SingleLine { prefix: __self_0 } =>
::core::fmt::Formatter::debug_struct_field1_finish(f,
"SingleLine", "prefix", &__self_0),
OptimizerHintStyle::MultiLine =>
::core::fmt::Formatter::write_str(f, "MultiLine"),
}
}
}Debug, #[automatically_derived]
impl ::core::clone::Clone for OptimizerHintStyle {
#[inline]
fn clone(&self) -> OptimizerHintStyle {
match self {
OptimizerHintStyle::SingleLine { prefix: __self_0 } =>
OptimizerHintStyle::SingleLine {
prefix: ::core::clone::Clone::clone(__self_0),
},
OptimizerHintStyle::MultiLine => OptimizerHintStyle::MultiLine,
}
}
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for OptimizerHintStyle {
#[inline]
fn eq(&self, other: &OptimizerHintStyle) -> bool {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
__self_discr == __arg1_discr &&
match (self, other) {
(OptimizerHintStyle::SingleLine { prefix: __self_0 },
OptimizerHintStyle::SingleLine { prefix: __arg1_0 }) =>
__self_0 == __arg1_0,
_ => true,
}
}
}PartialEq, #[automatically_derived]
impl ::core::cmp::PartialOrd for OptimizerHintStyle {
#[inline]
fn partial_cmp(&self, other: &OptimizerHintStyle)
-> ::core::option::Option<::core::cmp::Ordering> {
::core::option::Option::Some(::core::cmp::Ord::cmp(self, other))
}
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Eq for OptimizerHintStyle {
#[inline]
#[doc(hidden)]
#[coverage(off)]
fn assert_fields_are_eq(&self) {
let _: ::core::cmp::AssertParamIsEq<String>;
}
}Eq, #[automatically_derived]
impl ::core::cmp::Ord for OptimizerHintStyle {
#[inline]
fn cmp(&self, other: &OptimizerHintStyle) -> ::core::cmp::Ordering {
let __self_discr = ::core::intrinsics::discriminant_value(self);
let __arg1_discr = ::core::intrinsics::discriminant_value(other);
match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
::core::cmp::Ordering::Equal =>
match (self, other) {
(OptimizerHintStyle::SingleLine { prefix: __self_0 },
OptimizerHintStyle::SingleLine { prefix: __arg1_0 }) =>
::core::cmp::Ord::cmp(__self_0, __arg1_0),
_ => ::core::cmp::Ordering::Equal,
},
cmp => cmp,
}
}
}Ord, #[automatically_derived]
impl ::core::hash::Hash for OptimizerHintStyle {
#[inline]
fn hash<__H: ::core::hash::Hasher>(&self, state: &mut __H) {
let __self_discr = ::core::intrinsics::discriminant_value(self);
::core::hash::Hash::hash(&__self_discr, state);
match self {
OptimizerHintStyle::SingleLine { prefix: __self_0 } =>
::core::hash::Hash::hash(__self_0, state),
_ => {}
}
}
}Hash)]
11527#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
11528#[cfg_attr(feature = "visitor", derive(impl sqlparser::ast::Visit for OptimizerHintStyle {
fn visit<V: sqlparser::ast::Visitor>(&self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::SingleLine { prefix } => {
sqlparser::ast::Visit::visit(prefix, visitor)?;
}
Self::MultiLine => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}Visit, impl sqlparser::ast::VisitMut for OptimizerHintStyle {
fn visit<V: sqlparser::ast::VisitorMut>(&mut self, visitor: &mut V)
-> ::std::ops::ControlFlow<V::Break> {
::recursive::__impl::stacker::maybe_grow(::recursive::get_minimum_stack_size(),
::recursive::get_stack_allocation_size(),
move || -> ::std::ops::ControlFlow<V::Break>
{
{
match self {
Self::SingleLine { prefix } => {
sqlparser::ast::VisitMut::visit(prefix, visitor)?;
}
Self::MultiLine => {}
}
::std::ops::ControlFlow::Continue(())
}
})
}
}VisitMut))]
11529pub enum OptimizerHintStyle {
11530 SingleLine {
11533 prefix: String,
11535 },
11536 MultiLine,
11539}
11540
11541impl fmt::Display for OptimizerHint {
11542 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
11543 match &self.style {
11544 OptimizerHintStyle::SingleLine { prefix } => {
11545 f.write_str(prefix)?;
11546 f.write_str("+")?;
11547 f.write_str(&self.text)
11548 }
11549 OptimizerHintStyle::MultiLine => {
11550 f.write_str("/*+")?;
11551 f.write_str(&self.text)?;
11552 f.write_str("*/")
11553 }
11554 }
11555 }
11556}
11557
11558impl fmt::Display for ResetStatement {
11559 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
11560 match &self.reset {
11561 Reset::ALL => f.write_fmt(format_args!("RESET ALL"))write!(f, "RESET ALL"),
11562 Reset::ConfigurationParameter(param) => f.write_fmt(format_args!("RESET {0}", param))write!(f, "RESET {}", param),
11563 }
11564 }
11565}
11566
11567impl From<Set> for Statement {
11568 fn from(s: Set) -> Self {
11569 Self::Set(s)
11570 }
11571}
11572
11573impl From<Query> for Statement {
11574 fn from(q: Query) -> Self {
11575 Box::new(q).into()
11576 }
11577}
11578
11579impl From<Box<Query>> for Statement {
11580 fn from(q: Box<Query>) -> Self {
11581 Self::Query(q)
11582 }
11583}
11584
11585impl From<Insert> for Statement {
11586 fn from(i: Insert) -> Self {
11587 Self::Insert(i)
11588 }
11589}
11590
11591impl From<Update> for Statement {
11592 fn from(u: Update) -> Self {
11593 Self::Update(u)
11594 }
11595}
11596
11597impl From<CreateView> for Statement {
11598 fn from(cv: CreateView) -> Self {
11599 Self::CreateView(cv)
11600 }
11601}
11602
11603impl From<CreateRole> for Statement {
11604 fn from(cr: CreateRole) -> Self {
11605 Self::CreateRole(cr)
11606 }
11607}
11608
11609impl From<AlterTable> for Statement {
11610 fn from(at: AlterTable) -> Self {
11611 Self::AlterTable(at)
11612 }
11613}
11614
11615impl From<DropFunction> for Statement {
11616 fn from(df: DropFunction) -> Self {
11617 Self::DropFunction(df)
11618 }
11619}
11620
11621impl From<CreateExtension> for Statement {
11622 fn from(ce: CreateExtension) -> Self {
11623 Self::CreateExtension(ce)
11624 }
11625}
11626
11627impl From<DropExtension> for Statement {
11628 fn from(de: DropExtension) -> Self {
11629 Self::DropExtension(de)
11630 }
11631}
11632
11633impl From<CaseStatement> for Statement {
11634 fn from(c: CaseStatement) -> Self {
11635 Self::Case(c)
11636 }
11637}
11638
11639impl From<IfStatement> for Statement {
11640 fn from(i: IfStatement) -> Self {
11641 Self::If(i)
11642 }
11643}
11644
11645impl From<WhileStatement> for Statement {
11646 fn from(w: WhileStatement) -> Self {
11647 Self::While(w)
11648 }
11649}
11650
11651impl From<RaiseStatement> for Statement {
11652 fn from(r: RaiseStatement) -> Self {
11653 Self::Raise(r)
11654 }
11655}
11656
11657impl From<Function> for Statement {
11658 fn from(f: Function) -> Self {
11659 Self::Call(f)
11660 }
11661}
11662
11663impl From<OpenStatement> for Statement {
11664 fn from(o: OpenStatement) -> Self {
11665 Self::Open(o)
11666 }
11667}
11668
11669impl From<Delete> for Statement {
11670 fn from(d: Delete) -> Self {
11671 Self::Delete(d)
11672 }
11673}
11674
11675impl From<CreateTable> for Statement {
11676 fn from(c: CreateTable) -> Self {
11677 Self::CreateTable(c)
11678 }
11679}
11680
11681impl From<CreateIndex> for Statement {
11682 fn from(c: CreateIndex) -> Self {
11683 Self::CreateIndex(c)
11684 }
11685}
11686
11687impl From<CreateServerStatement> for Statement {
11688 fn from(c: CreateServerStatement) -> Self {
11689 Self::CreateServer(c)
11690 }
11691}
11692
11693impl From<CreateConnector> for Statement {
11694 fn from(c: CreateConnector) -> Self {
11695 Self::CreateConnector(c)
11696 }
11697}
11698
11699impl From<CreateOperator> for Statement {
11700 fn from(c: CreateOperator) -> Self {
11701 Self::CreateOperator(c)
11702 }
11703}
11704
11705impl From<CreateOperatorFamily> for Statement {
11706 fn from(c: CreateOperatorFamily) -> Self {
11707 Self::CreateOperatorFamily(c)
11708 }
11709}
11710
11711impl From<CreateOperatorClass> for Statement {
11712 fn from(c: CreateOperatorClass) -> Self {
11713 Self::CreateOperatorClass(c)
11714 }
11715}
11716
11717impl From<AlterSchema> for Statement {
11718 fn from(a: AlterSchema) -> Self {
11719 Self::AlterSchema(a)
11720 }
11721}
11722
11723impl From<AlterType> for Statement {
11724 fn from(a: AlterType) -> Self {
11725 Self::AlterType(a)
11726 }
11727}
11728
11729impl From<AlterOperator> for Statement {
11730 fn from(a: AlterOperator) -> Self {
11731 Self::AlterOperator(a)
11732 }
11733}
11734
11735impl From<AlterOperatorFamily> for Statement {
11736 fn from(a: AlterOperatorFamily) -> Self {
11737 Self::AlterOperatorFamily(a)
11738 }
11739}
11740
11741impl From<AlterOperatorClass> for Statement {
11742 fn from(a: AlterOperatorClass) -> Self {
11743 Self::AlterOperatorClass(a)
11744 }
11745}
11746
11747impl From<Merge> for Statement {
11748 fn from(m: Merge) -> Self {
11749 Self::Merge(m)
11750 }
11751}
11752
11753impl From<AlterUser> for Statement {
11754 fn from(a: AlterUser) -> Self {
11755 Self::AlterUser(a)
11756 }
11757}
11758
11759impl From<DropDomain> for Statement {
11760 fn from(d: DropDomain) -> Self {
11761 Self::DropDomain(d)
11762 }
11763}
11764
11765impl From<ShowCharset> for Statement {
11766 fn from(s: ShowCharset) -> Self {
11767 Self::ShowCharset(s)
11768 }
11769}
11770
11771impl From<ShowObjects> for Statement {
11772 fn from(s: ShowObjects) -> Self {
11773 Self::ShowObjects(s)
11774 }
11775}
11776
11777impl From<Use> for Statement {
11778 fn from(u: Use) -> Self {
11779 Self::Use(u)
11780 }
11781}
11782
11783impl From<CreateFunction> for Statement {
11784 fn from(c: CreateFunction) -> Self {
11785 Self::CreateFunction(c)
11786 }
11787}
11788
11789impl From<CreateTrigger> for Statement {
11790 fn from(c: CreateTrigger) -> Self {
11791 Self::CreateTrigger(c)
11792 }
11793}
11794
11795impl From<DropTrigger> for Statement {
11796 fn from(d: DropTrigger) -> Self {
11797 Self::DropTrigger(d)
11798 }
11799}
11800
11801impl From<DropOperator> for Statement {
11802 fn from(d: DropOperator) -> Self {
11803 Self::DropOperator(d)
11804 }
11805}
11806
11807impl From<DropOperatorFamily> for Statement {
11808 fn from(d: DropOperatorFamily) -> Self {
11809 Self::DropOperatorFamily(d)
11810 }
11811}
11812
11813impl From<DropOperatorClass> for Statement {
11814 fn from(d: DropOperatorClass) -> Self {
11815 Self::DropOperatorClass(d)
11816 }
11817}
11818
11819impl From<DenyStatement> for Statement {
11820 fn from(d: DenyStatement) -> Self {
11821 Self::Deny(d)
11822 }
11823}
11824
11825impl From<CreateDomain> for Statement {
11826 fn from(c: CreateDomain) -> Self {
11827 Self::CreateDomain(c)
11828 }
11829}
11830
11831impl From<RenameTable> for Statement {
11832 fn from(r: RenameTable) -> Self {
11833 ::alloc::boxed::box_assume_init_into_vec_unsafe(::alloc::intrinsics::write_box_via_move(::alloc::boxed::Box::new_uninit(),
[r]))vec![r].into()
11834 }
11835}
11836
11837impl From<Vec<RenameTable>> for Statement {
11838 fn from(r: Vec<RenameTable>) -> Self {
11839 Self::RenameTable(r)
11840 }
11841}
11842
11843impl From<PrintStatement> for Statement {
11844 fn from(p: PrintStatement) -> Self {
11845 Self::Print(p)
11846 }
11847}
11848
11849impl From<ReturnStatement> for Statement {
11850 fn from(r: ReturnStatement) -> Self {
11851 Self::Return(r)
11852 }
11853}
11854
11855impl From<ExportData> for Statement {
11856 fn from(e: ExportData) -> Self {
11857 Self::ExportData(e)
11858 }
11859}
11860
11861impl From<CreateUser> for Statement {
11862 fn from(c: CreateUser) -> Self {
11863 Self::CreateUser(c)
11864 }
11865}
11866
11867impl From<VacuumStatement> for Statement {
11868 fn from(v: VacuumStatement) -> Self {
11869 Self::Vacuum(v)
11870 }
11871}
11872
11873impl From<ResetStatement> for Statement {
11874 fn from(r: ResetStatement) -> Self {
11875 Self::Reset(r)
11876 }
11877}
11878
11879#[cfg(test)]
11880mod tests {
11881 use crate::tokenizer::Location;
11882
11883 use super::*;
11884
11885 #[test]
11886 fn test_window_frame_default() {
11887 let window_frame = WindowFrame::default();
11888 assert_eq!(WindowFrameBound::Preceding(None), window_frame.start_bound);
11889 }
11890
11891 #[test]
11892 fn test_grouping_sets_display() {
11893 let grouping_sets = Expr::GroupingSets(vec![
11895 vec![Expr::Identifier(Ident::new("a"))],
11896 vec![Expr::Identifier(Ident::new("b"))],
11897 ]);
11898 assert_eq!("GROUPING SETS ((a), (b))", format!("{grouping_sets}"));
11899
11900 let grouping_sets = Expr::GroupingSets(vec![vec![
11902 Expr::Identifier(Ident::new("a")),
11903 Expr::Identifier(Ident::new("b")),
11904 ]]);
11905 assert_eq!("GROUPING SETS ((a, b))", format!("{grouping_sets}"));
11906
11907 let grouping_sets = Expr::GroupingSets(vec![
11909 vec![
11910 Expr::Identifier(Ident::new("a")),
11911 Expr::Identifier(Ident::new("b")),
11912 ],
11913 vec![
11914 Expr::Identifier(Ident::new("c")),
11915 Expr::Identifier(Ident::new("d")),
11916 ],
11917 ]);
11918 assert_eq!("GROUPING SETS ((a, b), (c, d))", format!("{grouping_sets}"));
11919 }
11920
11921 #[test]
11922 fn test_rollup_display() {
11923 let rollup = Expr::Rollup(vec![vec![Expr::Identifier(Ident::new("a"))]]);
11924 assert_eq!("ROLLUP (a)", format!("{rollup}"));
11925
11926 let rollup = Expr::Rollup(vec![vec![
11927 Expr::Identifier(Ident::new("a")),
11928 Expr::Identifier(Ident::new("b")),
11929 ]]);
11930 assert_eq!("ROLLUP ((a, b))", format!("{rollup}"));
11931
11932 let rollup = Expr::Rollup(vec![
11933 vec![Expr::Identifier(Ident::new("a"))],
11934 vec![Expr::Identifier(Ident::new("b"))],
11935 ]);
11936 assert_eq!("ROLLUP (a, b)", format!("{rollup}"));
11937
11938 let rollup = Expr::Rollup(vec![
11939 vec![Expr::Identifier(Ident::new("a"))],
11940 vec![
11941 Expr::Identifier(Ident::new("b")),
11942 Expr::Identifier(Ident::new("c")),
11943 ],
11944 vec![Expr::Identifier(Ident::new("d"))],
11945 ]);
11946 assert_eq!("ROLLUP (a, (b, c), d)", format!("{rollup}"));
11947 }
11948
11949 #[test]
11950 fn test_cube_display() {
11951 let cube = Expr::Cube(vec![vec![Expr::Identifier(Ident::new("a"))]]);
11952 assert_eq!("CUBE (a)", format!("{cube}"));
11953
11954 let cube = Expr::Cube(vec![vec![
11955 Expr::Identifier(Ident::new("a")),
11956 Expr::Identifier(Ident::new("b")),
11957 ]]);
11958 assert_eq!("CUBE ((a, b))", format!("{cube}"));
11959
11960 let cube = Expr::Cube(vec![
11961 vec![Expr::Identifier(Ident::new("a"))],
11962 vec![Expr::Identifier(Ident::new("b"))],
11963 ]);
11964 assert_eq!("CUBE (a, b)", format!("{cube}"));
11965
11966 let cube = Expr::Cube(vec![
11967 vec![Expr::Identifier(Ident::new("a"))],
11968 vec![
11969 Expr::Identifier(Ident::new("b")),
11970 Expr::Identifier(Ident::new("c")),
11971 ],
11972 vec![Expr::Identifier(Ident::new("d"))],
11973 ]);
11974 assert_eq!("CUBE (a, (b, c), d)", format!("{cube}"));
11975 }
11976
11977 #[test]
11978 fn test_interval_display() {
11979 let interval = Expr::Interval(Interval {
11980 value: Box::new(Expr::Value(
11981 Value::SingleQuotedString(String::from("123:45.67")).with_empty_span(),
11982 )),
11983 leading_field: Some(DateTimeField::Minute),
11984 leading_precision: Some(10),
11985 last_field: Some(DateTimeField::Second),
11986 fractional_seconds_precision: Some(9),
11987 });
11988 assert_eq!(
11989 "INTERVAL '123:45.67' MINUTE (10) TO SECOND (9)",
11990 format!("{interval}"),
11991 );
11992
11993 let interval = Expr::Interval(Interval {
11994 value: Box::new(Expr::Value(
11995 Value::SingleQuotedString(String::from("5")).with_empty_span(),
11996 )),
11997 leading_field: Some(DateTimeField::Second),
11998 leading_precision: Some(1),
11999 last_field: None,
12000 fractional_seconds_precision: Some(3),
12001 });
12002 assert_eq!("INTERVAL '5' SECOND (1, 3)", format!("{interval}"));
12003 }
12004
12005 #[test]
12006 fn test_one_or_many_with_parens_deref() {
12007 use core::ops::Index;
12008
12009 let one = OneOrManyWithParens::One("a");
12010
12011 assert_eq!(one.deref(), &["a"]);
12012 assert_eq!(<OneOrManyWithParens<_> as Deref>::deref(&one), &["a"]);
12013
12014 assert_eq!(one[0], "a");
12015 assert_eq!(one.index(0), &"a");
12016 assert_eq!(
12017 <<OneOrManyWithParens<_> as Deref>::Target as Index<usize>>::index(&one, 0),
12018 &"a"
12019 );
12020
12021 assert_eq!(one.len(), 1);
12022 assert_eq!(<OneOrManyWithParens<_> as Deref>::Target::len(&one), 1);
12023
12024 let many1 = OneOrManyWithParens::Many(vec!["b"]);
12025
12026 assert_eq!(many1.deref(), &["b"]);
12027 assert_eq!(<OneOrManyWithParens<_> as Deref>::deref(&many1), &["b"]);
12028
12029 assert_eq!(many1[0], "b");
12030 assert_eq!(many1.index(0), &"b");
12031 assert_eq!(
12032 <<OneOrManyWithParens<_> as Deref>::Target as Index<usize>>::index(&many1, 0),
12033 &"b"
12034 );
12035
12036 assert_eq!(many1.len(), 1);
12037 assert_eq!(<OneOrManyWithParens<_> as Deref>::Target::len(&many1), 1);
12038
12039 let many2 = OneOrManyWithParens::Many(vec!["c", "d"]);
12040
12041 assert_eq!(many2.deref(), &["c", "d"]);
12042 assert_eq!(
12043 <OneOrManyWithParens<_> as Deref>::deref(&many2),
12044 &["c", "d"]
12045 );
12046
12047 assert_eq!(many2[0], "c");
12048 assert_eq!(many2.index(0), &"c");
12049 assert_eq!(
12050 <<OneOrManyWithParens<_> as Deref>::Target as Index<usize>>::index(&many2, 0),
12051 &"c"
12052 );
12053
12054 assert_eq!(many2[1], "d");
12055 assert_eq!(many2.index(1), &"d");
12056 assert_eq!(
12057 <<OneOrManyWithParens<_> as Deref>::Target as Index<usize>>::index(&many2, 1),
12058 &"d"
12059 );
12060
12061 assert_eq!(many2.len(), 2);
12062 assert_eq!(<OneOrManyWithParens<_> as Deref>::Target::len(&many2), 2);
12063 }
12064
12065 #[test]
12066 fn test_one_or_many_with_parens_as_ref() {
12067 let one = OneOrManyWithParens::One("a");
12068
12069 assert_eq!(one.as_ref(), &["a"]);
12070 assert_eq!(<OneOrManyWithParens<_> as AsRef<_>>::as_ref(&one), &["a"]);
12071
12072 let many1 = OneOrManyWithParens::Many(vec!["b"]);
12073
12074 assert_eq!(many1.as_ref(), &["b"]);
12075 assert_eq!(<OneOrManyWithParens<_> as AsRef<_>>::as_ref(&many1), &["b"]);
12076
12077 let many2 = OneOrManyWithParens::Many(vec!["c", "d"]);
12078
12079 assert_eq!(many2.as_ref(), &["c", "d"]);
12080 assert_eq!(
12081 <OneOrManyWithParens<_> as AsRef<_>>::as_ref(&many2),
12082 &["c", "d"]
12083 );
12084 }
12085
12086 #[test]
12087 fn test_one_or_many_with_parens_ref_into_iter() {
12088 let one = OneOrManyWithParens::One("a");
12089
12090 assert_eq!(Vec::from_iter(&one), vec![&"a"]);
12091
12092 let many1 = OneOrManyWithParens::Many(vec!["b"]);
12093
12094 assert_eq!(Vec::from_iter(&many1), vec![&"b"]);
12095
12096 let many2 = OneOrManyWithParens::Many(vec!["c", "d"]);
12097
12098 assert_eq!(Vec::from_iter(&many2), vec![&"c", &"d"]);
12099 }
12100
12101 #[test]
12102 fn test_one_or_many_with_parens_value_into_iter() {
12103 use core::iter::once;
12104
12105 fn test_steps<I>(ours: OneOrManyWithParens<usize>, inner: I, n: usize)
12107 where
12108 I: IntoIterator<Item = usize, IntoIter: DoubleEndedIterator + Clone> + Clone,
12109 {
12110 fn checks<I>(ours: OneOrManyWithParensIntoIter<usize>, inner: I)
12111 where
12112 I: Iterator<Item = usize> + Clone + DoubleEndedIterator,
12113 {
12114 assert_eq!(ours.size_hint(), inner.size_hint());
12115 assert_eq!(ours.clone().count(), inner.clone().count());
12116
12117 assert_eq!(
12118 ours.clone().fold(1, |a, v| a + v),
12119 inner.clone().fold(1, |a, v| a + v)
12120 );
12121
12122 assert_eq!(Vec::from_iter(ours.clone()), Vec::from_iter(inner.clone()));
12123 assert_eq!(
12124 Vec::from_iter(ours.clone().rev()),
12125 Vec::from_iter(inner.clone().rev())
12126 );
12127 }
12128
12129 let mut ours_next = ours.clone().into_iter();
12130 let mut inner_next = inner.clone().into_iter();
12131
12132 for _ in 0..n {
12133 checks(ours_next.clone(), inner_next.clone());
12134
12135 assert_eq!(ours_next.next(), inner_next.next());
12136 }
12137
12138 let mut ours_next_back = ours.clone().into_iter();
12139 let mut inner_next_back = inner.clone().into_iter();
12140
12141 for _ in 0..n {
12142 checks(ours_next_back.clone(), inner_next_back.clone());
12143
12144 assert_eq!(ours_next_back.next_back(), inner_next_back.next_back());
12145 }
12146
12147 let mut ours_mixed = ours.clone().into_iter();
12148 let mut inner_mixed = inner.clone().into_iter();
12149
12150 for i in 0..n {
12151 checks(ours_mixed.clone(), inner_mixed.clone());
12152
12153 if i % 2 == 0 {
12154 assert_eq!(ours_mixed.next_back(), inner_mixed.next_back());
12155 } else {
12156 assert_eq!(ours_mixed.next(), inner_mixed.next());
12157 }
12158 }
12159
12160 let mut ours_mixed2 = ours.into_iter();
12161 let mut inner_mixed2 = inner.into_iter();
12162
12163 for i in 0..n {
12164 checks(ours_mixed2.clone(), inner_mixed2.clone());
12165
12166 if i % 2 == 0 {
12167 assert_eq!(ours_mixed2.next(), inner_mixed2.next());
12168 } else {
12169 assert_eq!(ours_mixed2.next_back(), inner_mixed2.next_back());
12170 }
12171 }
12172 }
12173
12174 test_steps(OneOrManyWithParens::One(1), once(1), 3);
12175 test_steps(OneOrManyWithParens::Many(vec![2]), vec![2], 3);
12176 test_steps(OneOrManyWithParens::Many(vec![3, 4]), vec![3, 4], 4);
12177 }
12178
12179 #[test]
12182 fn test_ident_ord() {
12183 let mut a = Ident::with_span(Span::new(Location::new(1, 1), Location::new(1, 1)), "a");
12184 let mut b = Ident::with_span(Span::new(Location::new(2, 2), Location::new(2, 2)), "b");
12185
12186 assert!(a < b);
12187 std::mem::swap(&mut a.span, &mut b.span);
12188 assert!(a < b);
12189 }
12190}