I execute an insert without any problem but when I run another insert I should mark error because inside that table there is a primary key and then the error remains but in the android monitor although I do the log.e (blah blah blah); it is as if the exception were thrown.
public long insertarTipo(List<Tipo> tipo) {
long n = 1;
this.openWriteableDB();
db.beginTransaction();
try {
if (tipo.size() > 0) {
ContentValues tt = new ContentValues();
n = db.insert("Tipo", null, tt);
}
}
db.setTransactionSuccessful();
} catch (Exception e) {
Log.e(Errors.ERROR_TAG, e.getMessage(), e);
} finally {
db.endTransaction();
}
return n;
}