I tried to configure data dictionary to fix a warning that popped up on SonarCloud: The Data Dictionary is not configured for PLSQL analyzer which prevents rule(s) S3641, S3921, S3618, S3651 to raise issues. See https://sonarcloud.io/documentation/analysis/languages/plsql/
But the scanner looks for Oracle sys.all_tab_columns table in postgres db after adding config in pipeline.
-
ALM used: Bitbucket Cloud
-
CI system used: Bitbucket Cloud
-
Scanner command used when applicable (private details masked): NA
-
Languages of the repository: js, pgsql
-
Repo: private
-
Pipeline config snippet:
EXTRA_ARGS: -Dsonar.plsql.jdbc.url=${CONN_URL} -Dsonar.plsql.jdbc.user=${DB_USER} -Dsonar.plsql.jdbc.password=${DB_PASS} -Dsonar.plsql.jdbc.driver.class=org.postgresql.Driver -Dsonar.plsql.jdbc.driver.path=driverjar/postgresql-42.2.23.jar
(CONN_URL: jdbc:postgresql://hostname:port/db. And, driverjar/** is a Bitbucket pipeline artifact for DriverManager jar) -
Error observed:
ERROR: Error during SonarScanner execution java.lang.IllegalStateException: SQLException occurred while loading the Data Dictionary. ... Caused by: org.postgresql.util.PSQLException: ERROR: relation "sys.all_tab_columns" does not exist Position: 184 ...
-
Workaround tried and failed: added -Dsonar.plsql.defaultSchema=public (and information_schema) in extra_args
Someone please help me understand what’s going wrong here.