Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

liquibase:dropAll maven goal showing SAP DBTech JDBC: Invalid parameter index: 1 #187

Open
Saschl opened this issue Jan 11, 2024 · 1 comment

Comments

@Saschl
Copy link

Saschl commented Jan 11, 2024

When executing the "liquibase:dropAll" maven goal the execution does not succeed and throws the following error.

With previous versions of liquibase (i.e. 4.21) the command is working properly. Hana driver version is 2.19.16.

om.sap.db.jdbc.exceptions.JDBCDriverException: SAP DBTech JDBC: Invalid parameter index: 1
    at com.sap.db.jdbc.exceptions.SQLExceptionSapDB._newInstance (SQLExceptionSapDB.java:209)
    at com.sap.db.jdbc.exceptions.SQLExceptionSapDB.newInstance (SQLExceptionSapDB.java:26)
    at com.sap.db.jdbc.PreparedStatementSapDB._getParameterConverter (PreparedStatementSapDB.java:3150)
    at com.sap.db.jdbc.PreparedStatementSapDB._setObject (PreparedStatementSapDB.java:2878)
    at com.sap.db.jdbc.PreparedStatementSapDB.setObject (PreparedStatementSapDB.java:837)
    at liquibase.snapshot.ResultSetCache$ResultSetExtractor.executeAndExtract (ResultSetCache.java:247)
    at liquibase.snapshot.ResultSetCache$ResultSetExtractor.executeAndExtract (ResultSetCache.java:233)
    at liquibase.ext.hana.snapshot.ResultSetExtractorHana.fastFetchQuery (ResultSetExtractorHana.java:67)
    at liquibase.snapshot.ResultSetCache$SingleResultSetExtractor.fastFetch (ResultSetCache.java:336)
    at liquibase.ext.hana.snapshot.UniqueConstraintSnapshotGeneratorHana.listConstraints (UniqueConstraintSnapshotGeneratorHana.java:43)
    at liquibase.snapshot.jvm.UniqueConstraintSnapshotGenerator.addTo (UniqueConstraintSnapshotGenerator.java:116)
    at liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot (JdbcSnapshotGenerator.java:78)
    at liquibase.snapshot.SnapshotGeneratorChain.snapshot (SnapshotGeneratorChain.java:49)
    at liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot (JdbcSnapshotGenerator.java:68)
    at liquibase.snapshot.SnapshotGeneratorChain.snapshot (SnapshotGeneratorChain.java:49)
    at liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot (JdbcSnapshotGenerator.java:68)
    at liquibase.snapshot.SnapshotGeneratorChain.snapshot (SnapshotGeneratorChain.java:49)
    at liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot (JdbcSnapshotGenerator.java:68)
    at liquibase.snapshot.SnapshotGeneratorChain.snapshot (SnapshotGeneratorChain.java:49)
    at liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot (JdbcSnapshotGenerator.java:68)
    at liquibase.snapshot.SnapshotGeneratorChain.snapshot (SnapshotGeneratorChain.java:49)
    at liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot (JdbcSnapshotGenerator.java:68)
    at liquibase.snapshot.SnapshotGeneratorChain.snapshot (SnapshotGeneratorChain.java:49)
    at liquibase.snapshot.DatabaseSnapshot.include (DatabaseSnapshot.java:313)
    at liquibase.snapshot.DatabaseSnapshot.init (DatabaseSnapshot.java:106)
    at liquibase.snapshot.DatabaseSnapshot.<init> (DatabaseSnapshot.java:59)
    at liquibase.snapshot.JdbcDatabaseSnapshot.<init> (JdbcDatabaseSnapshot.java:34)
    at liquibase.snapshot.SnapshotGeneratorFactory.createSnapshot (SnapshotGeneratorFactory.java:215)
    at liquibase.snapshot.SnapshotGeneratorFactory.createSnapshot (SnapshotGeneratorFactory.java:244)
    at liquibase.snapshot.SnapshotGeneratorFactory.createSnapshot (SnapshotGeneratorFactory.java:228)
    at liquibase.changelog.StandardChangeLogHistoryService.destroy (StandardChangeLogHistoryService.java:472)
    at liquibase.database.AbstractJdbcDatabase.dropDatabaseObjects (AbstractJdbcDatabase.java:843)
    at liquibase.command.core.DropAllCommandStep.run (DropAllCommandStep.java:65)
    at liquibase.command.CommandScope.execute (CommandScope.java:217)
    at liquibase.Liquibase.dropAll (Liquibase.java:1009)
    at liquibase.Liquibase.dropAll (Liquibase.java:994)
    at org.liquibase.maven.plugins.LiquibaseDropAll.performLiquibaseTask (LiquibaseDropAll.java:40)
    at org.liquibase.maven.plugins.AbstractLiquibaseMojo.lambda$execute$1 (AbstractLiquibaseMojo.java:862)
    at liquibase.Scope.lambda$child$0 (Scope.java:186)
    at liquibase.Scope.child (Scope.java:195)
    at liquibase.Scope.child (Scope.java:185)
    at liquibase.Scope.child (Scope.java:164)
    at org.liquibase.maven.plugins.AbstractLiquibaseMojo.lambda$execute$2 (AbstractLiquibaseMojo.java:862)
    at liquibase.Scope.lambda$child$0 (Scope.java:186)
    at liquibase.Scope.child (Scope.java:195)
    at liquibase.Scope.child (Scope.java:185)
    at liquibase.Scope.child (Scope.java:164)
    at org.liquibase.maven.plugins.AbstractLiquibaseMojo.lambda$execute$3 (AbstractLiquibaseMojo.java:779)
    at liquibase.Scope.lambda$child$0 (Scope.java:186)
    at liquibase.Scope.child (Scope.java:195)
    at liquibase.Scope.child (Scope.java:185)
    at liquibase.Scope.child (Scope.java:164)
    at org.liquibase.maven.plugins.AbstractLiquibaseMojo.execute (AbstractLiquibaseMojo.java:715)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:126)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:328)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
    at org.apache.maven.lifecycle.internal.MojoExecutor.access$000 (MojoExecutor.java:75)
    at org.apache.maven.lifecycle.internal.MojoExecutor$1.run (MojoExecutor.java:162)
    at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute (DefaultMojosExecutionStrategy.java:39)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:159)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:105)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:73)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:53)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:118)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)
    at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)
    at org.apache.maven.cli.MavenCli.execute (MavenCli.java:906)
    at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)
    at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)
    at jdk.internal.reflect.DirectMethodHandleAccessor.invoke (DirectMethodHandleAccessor.java:103)
    at java.lang.reflect.Method.invoke (Method.java:580)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:283)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:226)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:407)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:348)
    at org.codehaus.classworlds.Launcher.main (Launcher.java:47)
@tunahan
Copy link

tunahan commented Apr 4, 2024

I also have same tech stack with @Saschl. And I can confirm that I also get this error. Additionally, this error is also thrown during execution of following command.
mvn liquibase:generateChangeLog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants