mirror of
https://github.com/apache/datafusion-sqlparser-rs.git
synced 2025-10-11 14:32:04 +00:00
Add support for Snowflake LIST and REMOVE (#1639)
This commit is contained in:
parent
17e22f0a60
commit
4c6af0ae4f
6 changed files with 97 additions and 5 deletions
|
@ -23,7 +23,7 @@ use alloc::{
|
|||
string::{String, ToString},
|
||||
vec::Vec,
|
||||
};
|
||||
use helpers::attached_token::AttachedToken;
|
||||
use helpers::{attached_token::AttachedToken, stmt_data_loading::FileStagingCommand};
|
||||
|
||||
use core::ops::Deref;
|
||||
use core::{
|
||||
|
@ -3420,6 +3420,12 @@ pub enum Statement {
|
|||
///
|
||||
/// See Mysql <https://dev.mysql.com/doc/refman/9.1/en/rename-table.html>
|
||||
RenameTable(Vec<RenameTable>),
|
||||
/// Snowflake `LIST`
|
||||
/// See: <https://docs.snowflake.com/en/sql-reference/sql/list>
|
||||
List(FileStagingCommand),
|
||||
/// Snowflake `REMOVE`
|
||||
/// See: <https://docs.snowflake.com/en/sql-reference/sql/remove>
|
||||
Remove(FileStagingCommand),
|
||||
}
|
||||
|
||||
impl fmt::Display for Statement {
|
||||
|
@ -4980,6 +4986,8 @@ impl fmt::Display for Statement {
|
|||
Statement::RenameTable(rename_tables) => {
|
||||
write!(f, "RENAME TABLE {}", display_comma_separated(rename_tables))
|
||||
}
|
||||
Statement::List(command) => write!(f, "LIST {command}"),
|
||||
Statement::Remove(command) => write!(f, "REMOVE {command}"),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue