Open SamPriyadarshi opened 12 months ago
I am seeing a similar issue with a procedure definition. The procedure definition executes on its own in BigQuery but fails when run using Liquibase. I can't share it because it contains sensitive information but I'm wondering how this is happening.
The error message in my case is this:
Caused by: liquibase.exception.DatabaseException: [Simba][BigQueryJDBCDriver](100032) Error executing query job. Message: Syntax error: Expected ";" but got end of script at [64:11]
This corresponds to an IF
block ending in END IF;
where the semicolon is the character at 64:11 – so it is a strange error message!
When creating Stored Procedures containing CASE statements like below, Liquibase throws liquibase.exception.DatabaseException and fails with EXEC_JOB_EXECUTION_ERR
Sample Stored Procedure
Note: All the referenced tables, udfs are already in place.
Tested by removing CASE statement with below and after that the creation of stored procedure succeeds.
if(epvid_vers_id like '%-%', null, `project.dataset.sp.udf_std_str_to_str`(epvid_vers_id)) as version_id
Version Details
JDBC Simba Driver Version: 1.3.3.1004 Liquibase BigQuery Version: 4.17.0
Output
Steps to Reproduce
liquibase update
Expected Behavior
The stored procedure would've have been created.
Actual Behavior
Liquibase is throwing exception mentioned above.
Community Note