We're updating the issue view to help you get more done. 

SQLite autoincrement error : SQL error or missing database (near "AUTOINCREMENT": syntax error)

Description

I have a migration in yaml like this one :

 

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 databaseChangeLog: - changeSet: id: 4 author: bthomas changes: - createTable: tableName: batch_search columns: - column: name: id type: integer autoIncrement: true constraints: nullable: false primaryKey: true

When I run it with SQLite, I have the error :

 

1 java.lang.RuntimeException: liquibase.exception.MigrationFailedException: Migration failed for change set liquibase/changelog/changes/003-batch-query.yml::4::bthomas:Reason: liquibase.exception.DatabaseException: [SQLITE_ERROR] SQL error or missing database (near "AUTOINCREMENT": syntax error) [Failed SQL: CREATE TABLE batch_search_query (id BIGINT AUTOINCREMENT NOT NULL, search_id BIGINT NOT NULL, "query" VARCHAR(4096) NOT NULL)]

It seems that the problem is the BIGINT type that should be INTEGER : https://www.liquibase.org/documentation/changes/add_auto_increment.html

Tell me if I've missed something.

Environment

openjdk version "1.8.0_191" on ubuntu 16.0.4

Status

Assignee

Unassigned

Reporter

Bruno Thomas

Labels

None

Components

Affects versions

3.6.3

Priority

Major