-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Description
Search first
- I searched and no similar issues were found
Description
I am using the open source version of Liquibase against Databricks and found a bug - it seems Liquibase attempts to describe all the tables in the schema which is being deployed into, and it does not wrap the object names in back ticks (`) to escape special characters - In the schema below, I have a table name that contains a dash which is not allowed unless it is wrapped in backticks - see the error message below.
Starting Liquibase at 13:42:10 using Java 21.0.7 (version 4.33.0 #8744 built at 2025-07-08 20:43+0000)
Liquibase Version: 4.33.0
Liquibase Open Source 4.33.0 by Liquibase
ERROR: Exception Details
ERROR: Exception Primary Class: ErrorException
ERROR: Exception Primary Reason: [Databricks]JDBCDriver ERROR processing query/statement. Error Code: 0, SQL state: 42602, Query: DESCRIBE T***, Error message from Server: org.apache.hive.service.cli.HiveSQLException: Error running query: [INVALID_IDENTIFIER] org.apache.spark.sql.catalyst.parser.ParseException:
[INVALID_IDENTIFIER] The unquoted identifier mantel-ai-gateway_payload is invalid and must be back quoted as: mantel-ai-gateway_payload
.
Unquoted identifiers can only contain ASCII letters ('a' - 'z', 'A' - 'Z'), digits ('0' - '9'), and underbar ('_').
Unquoted identifiers must also not start with a digit.
Different data sources and meta stores may impose additional restrictions on valid identifiers. SQLSTATE: 42602 (line 1, pos 51)
== SQL ==
DESCRIBE TABLE EXTENDED development.daves_db.mantel-ai-gateway_payload
Steps To Reproduce
Perform a liquibase validate command
Expected/Desired Behavior
This should work, irrespective of what the Databricks objeect name is
Liquibase Version
4.33.0
Database Vendor & Version
Databricks
Liquibase Integration
No response
Liquibase Extensions
liquibase-databricks
OS and/or Infrastructure Type/Provider
No response
Additional Context
No response
Are you willing to submit a PR?
- I'm willing to submit a PR (Thank you!)
Metadata
Metadata
Assignees
Labels
Type
Projects
Status