I have a table like this:
private void Crea_TabellaIconePers(SQLiteDatabase db) {
String sqlFoto = "CREATE TABLE IF NOT EXISTS {0} " +
"({1} INTEGER, " +
"{2} BLOB, " +
"{3} TEXT);";
db.execSQL(MessageFormat.format(sqlFoto,
Tab_Icone_pers.TABLE_NAME,
Tab_Icone_pers._ID,
Tab_Icone_pers.ICONA,
Tab_Icone_pers.ID_PASSWORD));
}
I want to convert the first INTEGER field to INTEGER PRIMARY KEY AUTOINCREMENT can it be done with the onUpgrade () method? I have read some documentation about, but have not found anything that talks about this.