You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datafusion.apache.org by gi...@apache.org on 2026/09/07 04:46:46 UTC
(datafusion-sqlparser-rs) branch gh-readonly-queue/main/pr-2478-bd0f36fcfb17f2744352bc493d14e17d596fc21a created (now eb614226)
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a change to branch gh-readonly-queue/main/pr-2478-bd0f36fcfb17f2744352bc493d14e17d596fc21a
in repository https://gitbox.apache.org/repos/asf/datafusion-sqlparser-rs.git
at eb614226 Databricks: enable query and nested type syntax (#2478)
This branch includes the following new commits:
new eb614226 Databricks: enable query and nested type syntax (#2478)
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org
(datafusion-sqlparser-rs) 01/01: Databricks: enable query and nested type syntax (#2478)
Posted by gi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a commit to branch gh-readonly-queue/main/pr-2478-bd0f36fcfb17f2744352bc493d14e17d596fc21a
in repository https://gitbox.apache.org/repos/asf/datafusion-sqlparser-rs.git
commit eb6142261b4ecfab9d1c5da03e4fc9615e3aab13
Author: Ethan Vieira <et...@gmail.com>
AuthorDate: Mon Sep 7 04:46:22 2026 +0000
Databricks: enable query and nested type syntax (#2478)
Co-authored-by: evieira <et...@tryg.dk>
---
src/dialect/databricks.rs | 20 ++++++++++++++++++++
tests/sqlparser_common.rs | 2 +-
tests/sqlparser_databricks.rs | 12 ++++++++++++
3 files changed, 33 insertions(+), 1 deletion(-)
diff --git a/src/dialect/databricks.rs b/src/dialect/databricks.rs
index 3bc187a7..00ab6e94 100644
--- a/src/dialect/databricks.rs
+++ b/src/dialect/databricks.rs
@@ -113,4 +113,24 @@ impl Dialect for DatabricksDialect {
fn supports_select_item_multi_column_alias(&self) -> bool {
true
}
+
+ fn supports_map_literal_with_angle_brackets(&self) -> bool {
+ true
+ }
+
+ fn supports_string_literal_backslash_escape(&self) -> bool {
+ true
+ }
+
+ fn supports_select_wildcard_replace(&self) -> bool {
+ true
+ }
+
+ fn supports_from_first_select(&self) -> bool {
+ true
+ }
+
+ fn supports_pipe_operator(&self) -> bool {
+ true
+ }
}
diff --git a/tests/sqlparser_common.rs b/tests/sqlparser_common.rs
index 108ec431..29b060a8 100644
--- a/tests/sqlparser_common.rs
+++ b/tests/sqlparser_common.rs
@@ -17585,7 +17585,7 @@ fn parse_pipeline_operator_negative_tests() {
// Test that CALL with invalid function syntax fails
assert!(dialects
- .parse_sql_statements("SELECT * FROM users |> CALL 123invalid")
+ .parse_sql_statements("SELECT * FROM users |> CALL 123 invalid")
.is_err());
// Test that CALL with malformed arguments fails
diff --git a/tests/sqlparser_databricks.rs b/tests/sqlparser_databricks.rs
index 7c582546..62068ef5 100644
--- a/tests/sqlparser_databricks.rs
+++ b/tests/sqlparser_databricks.rs
@@ -737,3 +737,15 @@ fn parse_cte_without_as() {
.parse_sql_statements("WITH cte (SELECT 1) SELECT * FROM cte")
.is_err());
}
+
+#[test]
+fn parse_databricks_query_entry_points() {
+ databricks().verified_stmt("CREATE TABLE t (attrs MAP<STRING, ARRAY<INT>>)");
+ databricks().one_statement_parses_to(r#"SELECT 'it\'s'"#, "SELECT 'it''s'");
+ databricks().verified_stmt("SELECT * REPLACE (upper(name) AS name) FROM source");
+ databricks().verified_stmt(
+ "CREATE VIEW cross_product AS FROM main.raw.left_table, main.raw.right_table",
+ );
+ databricks()
+ .verified_stmt("CREATE VIEW filtered AS FROM main.raw.source |> WHERE id > 0 |> SELECT id");
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org