mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-07-07 17:04:59 +00:00
Update to ASF header / add when missing (#1437)
This commit is contained in:
parent
fb42425d51
commit
9934f3d931
64 changed files with 1006 additions and 427 deletions
19
CHANGELOG.md
19
CHANGELOG.md
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# Changelog
|
# Changelog
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
|
|
||||||
|
|
17
Cargo.toml
17
Cargo.toml
|
@ -1,3 +1,20 @@
|
||||||
|
# Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
# or more contributor license agreements. See the NOTICE file
|
||||||
|
# distributed with this work for additional information
|
||||||
|
# regarding copyright ownership. The ASF licenses this file
|
||||||
|
# to you under the Apache License, Version 2.0 (the
|
||||||
|
# "License"); you may not use this file except in compliance
|
||||||
|
# with the License. You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing,
|
||||||
|
# software distributed under the License is distributed on an
|
||||||
|
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
# KIND, either express or implied. See the License for the
|
||||||
|
# specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "sqlparser"
|
name = "sqlparser"
|
||||||
description = "Extensible SQL Lexer and Parser with support for ANSI SQL:2011"
|
description = "Extensible SQL Lexer and Parser with support for ANSI SQL:2011"
|
||||||
|
|
21
HEADER
21
HEADER
|
@ -1,11 +1,16 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
19
SECURITY.md
19
SECURITY.md
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# Security Policy
|
# Security Policy
|
||||||
|
|
||||||
## Reporting a Vulnerability
|
## Reporting a Vulnerability
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
# Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
# or more contributor license agreements. See the NOTICE file
|
||||||
|
# distributed with this work for additional information
|
||||||
|
# regarding copyright ownership. The ASF licenses this file
|
||||||
|
# to you under the Apache License, Version 2.0 (the
|
||||||
|
# "License"); you may not use this file except in compliance
|
||||||
|
# with the License. You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing,
|
||||||
|
# software distributed under the License is distributed on an
|
||||||
|
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
# KIND, either express or implied. See the License for the
|
||||||
|
# specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "sqlparser_derive"
|
name = "sqlparser_derive"
|
||||||
description = "proc macro for sqlparser"
|
description = "proc macro for sqlparser"
|
||||||
|
|
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# SQL Parser Derive Macro
|
# SQL Parser Derive Macro
|
||||||
|
|
||||||
## Visit
|
## Visit
|
||||||
|
|
|
@ -1,31 +1,53 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use proc_macro2::TokenStream;
|
use proc_macro2::TokenStream;
|
||||||
use quote::{format_ident, quote, quote_spanned, ToTokens};
|
use quote::{format_ident, quote, quote_spanned, ToTokens};
|
||||||
use syn::spanned::Spanned;
|
use syn::spanned::Spanned;
|
||||||
use syn::{
|
use syn::{
|
||||||
parse::{Parse, ParseStream},
|
parse::{Parse, ParseStream},
|
||||||
parse_macro_input, parse_quote, Attribute, Data, DeriveInput,
|
parse_macro_input, parse_quote, Attribute, Data, DeriveInput, Fields, GenericParam, Generics,
|
||||||
Fields, GenericParam, Generics, Ident, Index, LitStr, Meta, Token
|
Ident, Index, LitStr, Meta, Token,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/// Implementation of `[#derive(Visit)]`
|
/// Implementation of `[#derive(Visit)]`
|
||||||
#[proc_macro_derive(VisitMut, attributes(visit))]
|
#[proc_macro_derive(VisitMut, attributes(visit))]
|
||||||
pub fn derive_visit_mut(input: proc_macro::TokenStream) -> proc_macro::TokenStream {
|
pub fn derive_visit_mut(input: proc_macro::TokenStream) -> proc_macro::TokenStream {
|
||||||
derive_visit(input, &VisitType {
|
derive_visit(
|
||||||
|
input,
|
||||||
|
&VisitType {
|
||||||
visit_trait: quote!(VisitMut),
|
visit_trait: quote!(VisitMut),
|
||||||
visitor_trait: quote!(VisitorMut),
|
visitor_trait: quote!(VisitorMut),
|
||||||
modifier: Some(quote!(mut)),
|
modifier: Some(quote!(mut)),
|
||||||
})
|
},
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Implementation of `[#derive(Visit)]`
|
/// Implementation of `[#derive(Visit)]`
|
||||||
#[proc_macro_derive(Visit, attributes(visit))]
|
#[proc_macro_derive(Visit, attributes(visit))]
|
||||||
pub fn derive_visit_immutable(input: proc_macro::TokenStream) -> proc_macro::TokenStream {
|
pub fn derive_visit_immutable(input: proc_macro::TokenStream) -> proc_macro::TokenStream {
|
||||||
derive_visit(input, &VisitType {
|
derive_visit(
|
||||||
|
input,
|
||||||
|
&VisitType {
|
||||||
visit_trait: quote!(Visit),
|
visit_trait: quote!(Visit),
|
||||||
visitor_trait: quote!(Visitor),
|
visitor_trait: quote!(Visitor),
|
||||||
modifier: None,
|
modifier: None,
|
||||||
})
|
},
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
struct VisitType {
|
struct VisitType {
|
||||||
|
@ -34,15 +56,16 @@ struct VisitType {
|
||||||
modifier: Option<TokenStream>,
|
modifier: Option<TokenStream>,
|
||||||
}
|
}
|
||||||
|
|
||||||
fn derive_visit(
|
fn derive_visit(input: proc_macro::TokenStream, visit_type: &VisitType) -> proc_macro::TokenStream {
|
||||||
input: proc_macro::TokenStream,
|
|
||||||
visit_type: &VisitType,
|
|
||||||
) -> proc_macro::TokenStream {
|
|
||||||
// Parse the input tokens into a syntax tree.
|
// Parse the input tokens into a syntax tree.
|
||||||
let input = parse_macro_input!(input as DeriveInput);
|
let input = parse_macro_input!(input as DeriveInput);
|
||||||
let name = input.ident;
|
let name = input.ident;
|
||||||
|
|
||||||
let VisitType { visit_trait, visitor_trait, modifier } = visit_type;
|
let VisitType {
|
||||||
|
visit_trait,
|
||||||
|
visitor_trait,
|
||||||
|
modifier,
|
||||||
|
} = visit_type;
|
||||||
|
|
||||||
let attributes = Attributes::parse(&input.attrs);
|
let attributes = Attributes::parse(&input.attrs);
|
||||||
// Add a bound `T: Visit` to every type parameter T.
|
// Add a bound `T: Visit` to every type parameter T.
|
||||||
|
@ -87,7 +110,10 @@ impl Parse for WithIdent {
|
||||||
let mut result = WithIdent { with: None };
|
let mut result = WithIdent { with: None };
|
||||||
let ident = input.parse::<Ident>()?;
|
let ident = input.parse::<Ident>()?;
|
||||||
if ident != "with" {
|
if ident != "with" {
|
||||||
return Err(syn::Error::new(ident.span(), "Expected identifier to be `with`"));
|
return Err(syn::Error::new(
|
||||||
|
ident.span(),
|
||||||
|
"Expected identifier to be `with`",
|
||||||
|
));
|
||||||
}
|
}
|
||||||
input.parse::<Token!(=)>()?;
|
input.parse::<Token!(=)>()?;
|
||||||
let s = input.parse::<LitStr>()?;
|
let s = input.parse::<LitStr>()?;
|
||||||
|
@ -134,14 +160,23 @@ impl Attributes {
|
||||||
fn add_trait_bounds(mut generics: Generics, VisitType { visit_trait, .. }: &VisitType) -> Generics {
|
fn add_trait_bounds(mut generics: Generics, VisitType { visit_trait, .. }: &VisitType) -> Generics {
|
||||||
for param in &mut generics.params {
|
for param in &mut generics.params {
|
||||||
if let GenericParam::Type(ref mut type_param) = *param {
|
if let GenericParam::Type(ref mut type_param) = *param {
|
||||||
type_param.bounds.push(parse_quote!(sqlparser::ast::#visit_trait));
|
type_param
|
||||||
|
.bounds
|
||||||
|
.push(parse_quote!(sqlparser::ast::#visit_trait));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
generics
|
generics
|
||||||
}
|
}
|
||||||
|
|
||||||
// Generate the body of the visit implementation for the given type
|
// Generate the body of the visit implementation for the given type
|
||||||
fn visit_children(data: &Data, VisitType{visit_trait, modifier, ..}: &VisitType) -> TokenStream {
|
fn visit_children(
|
||||||
|
data: &Data,
|
||||||
|
VisitType {
|
||||||
|
visit_trait,
|
||||||
|
modifier,
|
||||||
|
..
|
||||||
|
}: &VisitType,
|
||||||
|
) -> TokenStream {
|
||||||
match data {
|
match data {
|
||||||
Data::Struct(data) => match &data.fields {
|
Data::Struct(data) => match &data.fields {
|
||||||
Fields::Named(fields) => {
|
Fields::Named(fields) => {
|
||||||
|
|
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# Benchmarking
|
# Benchmarking
|
||||||
|
|
||||||
Run `cargo bench` in the project `sqlparser_bench` execute the queries.
|
Run `cargo bench` in the project `sqlparser_bench` execute the queries.
|
||||||
|
|
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# Writing a Custom SQL Parser
|
# Writing a Custom SQL Parser
|
||||||
|
|
||||||
I have explored many different ways of building this library to make it easy to extend it for custom SQL dialects. Most of my attempts ended in failure but I have now found a workable solution. It is not without downsides but this seems to be the most pragmatic solution.
|
I have explored many different ways of building this library to make it easy to extend it for custom SQL dialects. Most of my attempts ended in failure but I have now found a workable solution. It is not without downsides but this seems to be the most pragmatic solution.
|
||||||
|
|
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# Fuzzing
|
# Fuzzing
|
||||||
|
|
||||||
## Installing `honggfuzz`
|
## Installing `honggfuzz`
|
||||||
|
|
|
@ -1,3 +1,22 @@
|
||||||
|
<!---
|
||||||
|
Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
or more contributor license agreements. See the NOTICE file
|
||||||
|
distributed with this work for additional information
|
||||||
|
regarding copyright ownership. The ASF licenses this file
|
||||||
|
to you under the Apache License, Version 2.0 (the
|
||||||
|
"License"); you may not use this file except in compliance
|
||||||
|
with the License. You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing,
|
||||||
|
software distributed under the License is distributed on an
|
||||||
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
KIND, either express or implied. See the License for the
|
||||||
|
specific language governing permissions and limitations
|
||||||
|
under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
# Releasing
|
# Releasing
|
||||||
|
|
||||||
## Prerequisites
|
## Prerequisites
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
# Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
# or more contributor license agreements. See the NOTICE file
|
||||||
|
# distributed with this work for additional information
|
||||||
|
# regarding copyright ownership. The ASF licenses this file
|
||||||
|
# to you under the Apache License, Version 2.0 (the
|
||||||
|
# "License"); you may not use this file except in compliance
|
||||||
|
# with the License. You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing,
|
||||||
|
# software distributed under the License is distributed on an
|
||||||
|
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
# KIND, either express or implied. See the License for the
|
||||||
|
# specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "fuzz"
|
name = "fuzz"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use honggfuzz::fuzz;
|
use honggfuzz::fuzz;
|
||||||
use sqlparser::dialect::GenericDialect;
|
use sqlparser::dialect::GenericDialect;
|
||||||
use sqlparser::parser::Parser;
|
use sqlparser::parser::Parser;
|
||||||
|
|
17
rustfmt.toml
17
rustfmt.toml
|
@ -1 +1,18 @@
|
||||||
|
# Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
# or more contributor license agreements. See the NOTICE file
|
||||||
|
# distributed with this work for additional information
|
||||||
|
# regarding copyright ownership. The ASF licenses this file
|
||||||
|
# to you under the Apache License, Version 2.0 (the
|
||||||
|
# "License"); you may not use this file except in compliance
|
||||||
|
# with the License. You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing,
|
||||||
|
# software distributed under the License is distributed on an
|
||||||
|
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
# KIND, either express or implied. See the License for the
|
||||||
|
# specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
|
||||||
# We use rustfmt's default settings to format the source code
|
# We use rustfmt's default settings to format the source code
|
|
@ -1,3 +1,20 @@
|
||||||
|
# Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
# or more contributor license agreements. See the NOTICE file
|
||||||
|
# distributed with this work for additional information
|
||||||
|
# regarding copyright ownership. The ASF licenses this file
|
||||||
|
# to you under the Apache License, Version 2.0 (the
|
||||||
|
# "License"); you may not use this file except in compliance
|
||||||
|
# with the License. You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing,
|
||||||
|
# software distributed under the License is distributed on an
|
||||||
|
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
# KIND, either express or implied. See the License for the
|
||||||
|
# specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
|
||||||
[package]
|
[package]
|
||||||
name = "sqlparser_bench"
|
name = "sqlparser_bench"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use criterion::{criterion_group, criterion_main, Criterion};
|
use criterion::{criterion_group, criterion_main, Criterion};
|
||||||
use sqlparser::dialect::GenericDialect;
|
use sqlparser::dialect::GenericDialect;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use alloc::{boxed::Box, format, string::String, vec::Vec};
|
use alloc::{boxed::Box, format, string::String, vec::Vec};
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! AST types specific to GRANT/REVOKE/ROLE variants of [`Statement`](crate::ast::Statement)
|
//! AST types specific to GRANT/REVOKE/ROLE variants of [`Statement`](crate::ast::Statement)
|
||||||
//! (commonly referred to as Data Control Language, or DCL)
|
//! (commonly referred to as Data Control Language, or DCL)
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! AST types specific to CREATE/ALTER variants of [`Statement`](crate::ast::Statement)
|
//! AST types specific to CREATE/ALTER variants of [`Statement`](crate::ast::Statement)
|
||||||
//! (commonly referred to as Data Definition Language, or DDL)
|
//! (commonly referred to as Data Definition Language, or DDL)
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use alloc::{boxed::Box, string::String, vec::Vec};
|
use alloc::{boxed::Box, string::String, vec::Vec};
|
||||||
|
|
|
@ -1,2 +1,18 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
pub mod stmt_create_table;
|
pub mod stmt_create_table;
|
||||||
pub mod stmt_data_loading;
|
pub mod stmt_data_loading;
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use alloc::{boxed::Box, format, string::String, vec, vec::Vec};
|
use alloc::{boxed::Box, format, string::String, vec, vec::Vec};
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! AST types specific to loading and unloading syntax, like one available in Snowflake which
|
//! AST types specific to loading and unloading syntax, like one available in Snowflake which
|
||||||
//! contains: STAGE ddl operations, PUT upload or COPY INTO
|
//! contains: STAGE ddl operations, PUT upload or COPY INTO
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! SQL Abstract Syntax Tree (AST) types
|
//! SQL Abstract Syntax Tree (AST) types
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use core::fmt;
|
use core::fmt;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use alloc::{boxed::Box, vec::Vec};
|
use alloc::{boxed::Box, vec::Vec};
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! SQL Abstract Syntax Tree (AST) for triggers.
|
//! SQL Abstract Syntax Tree (AST) for triggers.
|
||||||
use super::*;
|
use super::*;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use alloc::string::String;
|
use alloc::string::String;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! Recursive visitors for ast Nodes. See [`Visitor`] for more details.
|
//! Recursive visitors for ast Nodes. See [`Visitor`] for more details.
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
/// A [`Dialect`] for [Databricks SQL](https://www.databricks.com/)
|
/// A [`Dialect`] for [Databricks SQL](https://www.databricks.com/)
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
mod ansi;
|
mod ansi;
|
||||||
mod bigquery;
|
mod bigquery;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use alloc::boxed::Box;
|
use alloc::boxed::Box;
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
// you may not use this file except in compliance with the License.
|
// you may not use this file except in compliance with the License.
|
||||||
// You may obtain a copy of the License at
|
// You may obtain a copy of the License at
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
use core::iter::Peekable;
|
use core::iter::Peekable;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[cfg(not(feature = "std"))]
|
#[cfg(not(feature = "std"))]
|
||||||
use crate::alloc::string::ToString;
|
use crate::alloc::string::ToString;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use crate::ast::Statement;
|
use crate::ast::Statement;
|
||||||
use crate::dialect::Dialect;
|
use crate::dialect::Dialect;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! This module defines
|
//! This module defines
|
||||||
//! 1) a list of constants for every keyword
|
//! 1) a list of constants for every keyword
|
||||||
|
|
21
src/lib.rs
21
src/lib.rs
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! # SQL Parser for Rust
|
//! # SQL Parser for Rust
|
||||||
//!
|
//!
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
/// This module contains internal utilities used for testing the library.
|
/// This module contains internal utilities used for testing the library.
|
||||||
/// While technically public, the library's users are not supposed to rely
|
/// While technically public, the library's users are not supposed to rely
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! SQL Tokenizer
|
//! SQL Tokenizer
|
||||||
//!
|
//!
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
mod test_utils;
|
mod test_utils;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax specific to ClickHouse.
|
//! Test SQL syntax specific to ClickHouse.
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax, which all sqlparser dialects must parse in the same way.
|
//! Test SQL syntax, which all sqlparser dialects must parse in the same way.
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
//! Test the ability for dialects to override parsing
|
//! Test the ability for dialects to override parsing
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,20 @@
|
||||||
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
|
// or more contributor license agreements. See the NOTICE file
|
||||||
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing,
|
||||||
|
// software distributed under the License is distributed on an
|
||||||
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
|
// KIND, either express or implied. See the License for the
|
||||||
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
use sqlparser::ast::*;
|
use sqlparser::ast::*;
|
||||||
use sqlparser::dialect::{DatabricksDialect, GenericDialect};
|
use sqlparser::dialect::{DatabricksDialect, GenericDialect};
|
||||||
use sqlparser::parser::ParserError;
|
use sqlparser::parser::ParserError;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
mod test_utils;
|
mod test_utils;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax specific to Microsoft's T-SQL. The parser based on the
|
//! Test SQL syntax specific to Microsoft's T-SQL. The parser based on the
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax specific to MySQL. The parser based on the generic dialect
|
//! Test SQL syntax specific to MySQL. The parser based on the generic dialect
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax specific to PostgreSQL. The parser based on the
|
//! Test SQL syntax specific to PostgreSQL. The parser based on the
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
mod test_utils;
|
mod test_utils;
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax specific to Snowflake. The parser based on the
|
//! Test SQL syntax specific to Snowflake. The parser based on the
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
#![warn(clippy::all)]
|
#![warn(clippy::all)]
|
||||||
//! Test SQL syntax specific to SQLite. The parser based on the
|
//! Test SQL syntax specific to SQLite. The parser based on the
|
||||||
|
|
|
@ -1,14 +1,19 @@
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
// Licensed to the Apache Software Foundation (ASF) under one
|
||||||
// you may not use this file except in compliance with the License.
|
// or more contributor license agreements. See the NOTICE file
|
||||||
// You may obtain a copy of the License at
|
// distributed with this work for additional information
|
||||||
|
// regarding copyright ownership. The ASF licenses this file
|
||||||
|
// to you under the Apache License, Version 2.0 (the
|
||||||
|
// "License"); you may not use this file except in compliance
|
||||||
|
// with the License. You may obtain a copy of the License at
|
||||||
//
|
//
|
||||||
// http://www.apache.org/licenses/LICENSE-2.0
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
//
|
//
|
||||||
// Unless required by applicable law or agreed to in writing, software
|
// Unless required by applicable law or agreed to in writing,
|
||||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
// software distributed under the License is distributed on an
|
||||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||||
// See the License for the specific language governing permissions and
|
// KIND, either express or implied. See the License for the
|
||||||
// limitations under the License.
|
// specific language governing permissions and limitations
|
||||||
|
// under the License.
|
||||||
|
|
||||||
// Re-export everything from `src/test_utils.rs`.
|
// Re-export everything from `src/test_utils.rs`.
|
||||||
pub use sqlparser::test_utils::*;
|
pub use sqlparser::test_utils::*;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue