I am having an issue when using a property in yaml.
The following was defined in the yaml
- property:
name: datetime
value: timestamp
dbms: oracle,h2
- property:
name: datetime
value: datetime
dbms: mssql
- property:
name: datetime
value: TIMESTAMP WITHOUT TIME ZONE
dbms: postgresql
When using it in a changeset, liquibase gives the following error
- column:
remarks: Date created
name: CREATED_DATE
type: ${datetime)
If I change it to hard code the time for postgres, it ran ok
Caused by: liquibase.exception.LiquibaseException: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1
at liquibase.changelog.ChangeLogIterator.run(ChangeLogIterator.java:124) ~[liquibase-core-4.5.0.jar:?]
at liquibase.changelog.DatabaseChangeLog.validate(DatabaseChangeLog.java:292) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Liquibase.lambda$update$1(Liquibase.java:231) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Scope.lambda$child$0(Scope.java:177) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Scope.child(Scope.java:186) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Scope.child(Scope.java:176) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Scope.child(Scope.java:155) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Liquibase.runInScope(Liquibase.java:2404) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Liquibase.update(Liquibase.java:211) ~[liquibase-core-4.5.0.jar:?]
at liquibase.Liquibase.update(Liquibase.java:197) ~[liquibase-core-4.5.0.jar:?]
at liquibase.integration.spring.SpringLiquibase.performUpdate(SpringLiquibase.java:314) ~[liquibase-core-4.5.0.jar:?]
at liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:269) ~[liquibase-core-4.5.0.jar:?]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1863) ~[spring-beans-5.3.13.jar:5.3.13]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1800) ~[spring-beans-5.3.13.jar:5.3.13]
... 18 more