From 39b8a990bcf272a145adeb3b4fba8b8290f34b64 Mon Sep 17 00:00:00 2001 From: lukasz-jarocki-sonarsource Date: Thu, 3 Oct 2024 16:49:58 +0200 Subject: [PATCH] SONAR-23279 fixed an issue where the mapping for the jdbc column type was missing for selected database vendors --- .../testFixtures/java/org/sonar/db/AbstractDbTester.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/server/sonar-db-core/src/testFixtures/java/org/sonar/db/AbstractDbTester.java b/server/sonar-db-core/src/testFixtures/java/org/sonar/db/AbstractDbTester.java index e728f3ca7ff..783c296128b 100644 --- a/server/sonar-db-core/src/testFixtures/java/org/sonar/db/AbstractDbTester.java +++ b/server/sonar-db-core/src/testFixtures/java/org/sonar/db/AbstractDbTester.java @@ -63,6 +63,7 @@ import static com.google.common.collect.Lists.asList; import static java.sql.Types.BIGINT; import static java.sql.Types.BIT; import static java.sql.Types.BOOLEAN; +import static java.sql.Types.DECIMAL; import static java.sql.Types.DOUBLE; import static java.sql.Types.INTEGER; import static java.sql.Types.NUMERIC; @@ -76,10 +77,12 @@ public class AbstractDbTester extends ExternalResource { private static final Pattern INDEX_NAME_PATTERN = Pattern.compile("COALESCE\\(([\\w_]*),"); - private static final Map POSTGRES_TYPE_SUBSTITUTION = Map.of(BOOLEAN, BIT); + private static final Map POSTGRES_TYPE_SUBSTITUTION = Map.of(BOOLEAN, BIT, + DOUBLE, NUMERIC); private static final Map MSSQL_TYPE_SUBSTITUTION = Map.of( BOOLEAN, BIT, - VARCHAR, NVARCHAR); + VARCHAR, NVARCHAR, + DOUBLE, DECIMAL); private static final Map ORACLE_TYPE_SUBSTITUTION = Map.of( BOOLEAN, NUMERIC, -- 2.39.5