The documentation on the Liquibase website says that I can use the full connection string in the --url
parameter such as
jdbc:postgresql://host:port/database?user=user&password=secret
yet when I run any command such as
liquibase history --url='jdbc:postgresql://host:port/database?user=user&password=secret'
I get the following error:
Unexpected error running Liquibase: Connection could not be created to jdbc:postgresql://host:5432/database?user=user with driver org.postgresql.Driver. The server requested password-based authentication, but no password was provided.
For more information, please use the --log-level flag
'password' is not recognized as an internal or external command,
operable program or batch file.
It looks like the &
makes Liquibase split the connection string into two commands. It works if I provide the --user
and --password
parameters separately : liquibase history --url='jdbc:postgresql://host:port/database --user='user' --password='secret'
.
Am I doing something wrong? I'm running this in PowerShell.