vendredi 16 octobre 2015

android.database.sqlite.SQLiteException: near "(": syntax error (code 1):

I want to create table in DB, but I get SQLiteException:

This is my SQL-request for creating table:

String SQL_CREATE_TEMP_CATALOG_CAR_TABLE  = "CREATE TABLE temp_dn_catalog_car (\n"+
        "  catalog_car_id INTEGER PRIMARY KEY AUTOINCREMENT(11) NOT NULL, \n"+
        "  model_id INTEGER KEY(11) NOT NULL, \n"+
        "  generation_id INTEGER KEY(11) NOT NULL, \n"+
        "  body_type_id INTEGER KEY(11) NOT NULL, \n"+
        "  modification_id INTEGER KEY(11) NOT NULL, \n"+
        "  begin_year INTEGER(11) NOT NULL, \n"+
        "  end_year INTEGER(11) NOT NULL);\n";

Aucun commentaire:

Enregistrer un commentaire