Failed to run stored procedure whithin changeset for VoltDB

Hi.

I recently started developing an extension that adds support for VoltDB(https://github.com/diorman/liquibase-voltdb). So far it only supports changes using plain SQL.

I’m currently having a bad time trying to run a stored procedure. I’ve tried taking approaches from following threads but none of them seem to work in my case

https://forum.liquibase.org/topic/can-i-run-stored-procedures-from-change-log

https://forum.liquibase.org/topic/cannot-execute-oracle-stored-procedure

https://forum.liquibase.org/topic/liquibase-call-procedure-without-database-specification

My current guess is that the procedure call is being interpreted as a SQL statement instead of a callable statement. Here’s an example of a procedure call using JDBC in VoltDB https://github.com/VoltDB/voltdb/blob/master/examples/voter/client/voter/JDBCBenchmark.java#L350-L362

What I’m trying to do:



Am I missing something in the extension to support this? I just ran out of ideas

Thank you in advance

Diorman Colmenares

Hi,
I know I am late by 5 years but my guess is that the below piece of code might help whosoever is trying to make a liquibase-voltdb extension:

JdbcConnection connection = (JdbcConnection)database.getConnection(); //DB Connection
CallableStatement procedurecall = connection.getUnderlyingConnection().prepareCall(this.getClassCall()); // Class call from appchangelog
//Make a bundle of procedure (jar)
procedurecall.setBytes(1, Files.readAllBytes(Paths.get(this.getJarFile()))); // the voltdb procedure jar

Hopefully, it should work.