From 4d2770bd7ae19208616982f1a5fcbef121acdb37 Mon Sep 17 00:00:00 2001 From: Wesley Willard Date: Fri, 3 Jan 2025 13:57:19 -0600 Subject: [PATCH] DAT-18828 Add another escape --- .../snapshot/jvm/BigQueryPrimaryKeySnapshotGenerator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/liquibase/ext/bigquery/snapshot/jvm/BigQueryPrimaryKeySnapshotGenerator.java b/src/main/java/liquibase/ext/bigquery/snapshot/jvm/BigQueryPrimaryKeySnapshotGenerator.java index c991ece5..20ebab44 100644 --- a/src/main/java/liquibase/ext/bigquery/snapshot/jvm/BigQueryPrimaryKeySnapshotGenerator.java +++ b/src/main/java/liquibase/ext/bigquery/snapshot/jvm/BigQueryPrimaryKeySnapshotGenerator.java @@ -44,7 +44,7 @@ protected DatabaseObject snapshotObject(DatabaseObject example, DatabaseSnapshot PrimaryKey returnKey = null; String keyColumnUsageStatement = String.format("SELECT * FROM %s.INFORMATION_SCHEMA.KEY_COLUMN_USAGE WHERE CONSTRAINT_NAME = ?", - example.getSchema().getName()); + database.escapeObjectName(example.getSchema().getName(), Schema.class)); Executor executor = Scope.getCurrentScope().getSingleton(ExecutorService.class).getExecutor("jdbc", database); List> maps = executor.queryForList(new RawParameterizedSqlStatement(keyColumnUsageStatement, example.getName())); String columnName;