Liquibase 4.0.0 failing against HANA

Hello.
I am trying to run liquibase 4.0.0 through maven against SAP HANA DB, but i am getting the below error. If i try to run the create table command generated by liquibase directly on HANA it works. Can you please help me and let me know whats wrong.

Error setting up or running Liquibase:
[ERROR] liquibase.exception.DatabaseException: SAP DBTech JDBC: [258]: insufficient privilege: Detailed info for this error can be found with guid β€˜48524ACC91C0BC419A4DEABBE73B42E6’ [Failed SQL: (258) CREATE TABLE DATABASECHANGELOGLOCK (ID INTEGER NOT NULL, LOCKED BOOLEAN NOT NULL, LOCKGRANTED TIMESTAMP, LOCKEDBY NVARCHAR(255), CONSTRAINT PK_DATABASECHANGELOGLOCK PRIMARY KEY (ID))]

My liquibase.properties file contains the changelogFile, SAP HANA jdbc url, username, password, driver and classpath to ngdbc driver of HANA.

Do i need to give any privileges explicitly ?

1 Like

Hey @DEEPAK!

The user you specified in your lb properties file does need permissions to create the DATABASECHANGELOGLOCK table.

Hello @ronak,
As specified earlier, I used the same user to create the databasechangeloglock table on hana directly and it works, where as when I run mvn liquibase:update it fails. So, I am pretty confused.

P.S: I ran the statement which was generated by liquibase itself on HANA directly

Hi @DEEPAK,

I hear you, but how do we know that the maven process is using the same user? I don’t have access to the same information you do and I am trying to rule that out as a possible issue.

Mainly I am looking for what db user maven is using, and how you ran it manually to confirm it is the same user with the same credentials.

Does the DATABASECHANGELOGLOCK table exists when you get the error? It should if you ran it manually first. Does the error appear if you run manually liquibase and then try again using maven?

Thanks for your patience.

Ronak