org.springframework.beans.factory.BeanCreationException:在类路径资源 [org/springframework/boot/autoconfigure/liquibase/LiquibaseAutoConfiguration$LiquibaseConfiguration.class] 中创建名为“liquibase”的 bean 时出错:liquibase.exception.MigrationFailedException:迁移失败对于变更集 liquibase/db.changelog-1.0.xml::1.0.0::bohdan.taran: 原因:liquibase.exception.DatabaseException:错误:“)”处或附近的语法错误
<changeSet id="1.0.0" author="bohdan.taran">
<createTable tableName="users">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<column name="username" type="VARCHAR(100)">
<constraints nullable="false" unique="true"/>
</column>
<column name="email" type="VARCHAR(255)">
<constraints nullable="false" unique="true"/>
</column>
<column name="first_name" type="VARCHAR(100)">
<constraints nullable="false"/>
</column>
<column name="last_name" type="VARCHAR(100)">
<constraints nullable="false"/>
</column>
<column name="password" type="VARCHAR(255)">
<constraints nullable="false"/>
</column>
<column name="created" type="TIMESTAMP" defaultValue="CURRENT_TIMESTAMP()">
<constraints nullable="false"/>
</column>
<column name="updated" type="TIMESTAMP" defaultValue="CURRENT_TIMESTAMP()">
<constraints nullable="false"/>
</column>
<column name="status" type="VARCHAR(25)" defaultValue="ACTIVE">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
我在我的代码中找不到这个问题
CURRENT_TIMESTAMP 不是函数,不要使用 ()