Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

  1. ,
    Expert tip

    activity.OnCreate is executed every time the app launches or the screen is rotated, so, putting your DB initialization inside it will cause the DB to be called too many times causing the exception. Try to use the MyDatabase.onCreate method for this.

Solutions on the web

via GitHub by ojacquemart
, 1 year ago
UNIQUE constraint failed: station._id (code 1555)
via GitHub by gsczechowski
, 2 years ago
NOT NULL constraint failed: ShoppingLists.HouseholdID (code 1299)
via GitHub by tobiasschuerg
, 1 year ago
UNIQUE constraint failed: jobs._id (code 1555) ################################################################# Error Code : 1555 (SQLITE_CONSTRAINT_PRIMARYKEY) Caused By : Abort due to constraint violation. (UNIQUE constraint failed: jobs._id (code 1555)) #################################################################
via Stack Overflow by Ephraim Schmitt
, 1 year ago
PRIMARY KEY must be unique (code 19)
via GitHub by alxndrsn
, 11 months ago
UNIQUE constraint failed: wo_message._id (code 1555) 03-06 08:38:32.542 7222 30495 W MedicGateway: ################################################################# 03-06 08:38:32.542 7222 30495 W MedicGateway: Error Code : 1555
android.database.sqlite.SQLiteConstraintException: UNIQUE constraint failed: station._id (code 1555)	at android.database.sqlite.SQLiteConnection.nativeExecuteForLastInsertedRowId(Native Method)	at android.database.sqlite.SQLiteConnection.executeForLastInsertedRowId(SQLiteConnection.java:782)	at android.database.sqlite.SQLiteSession.executeForLastInsertedRowId(SQLiteSession.java:788)	at android.database.sqlite.SQLiteStatement.executeInsert(SQLiteStatement.java:86)	at android.database.sqlite.SQLiteDatabase.insertWithOnConflict(SQLiteDatabase.java:1471)	at android.database.sqlite.SQLiteDatabase.insertOrThrow(SQLiteDatabase.java:1367)	at com.vlille.checker.db.StationEntityManager.create(StationEntityManager.java:42)	at com.vlille.checker.db.StationEntityManager.create(StationEntityManager.java:15)	at org.droidparts.persist.sql.AbstractEntityManager$1.call(AbstractEntityManager.java:111)	at org.droidparts.persist.sql.AbstractEntityManager$1.call(AbstractEntityManager.java:102)	at org.droidparts.inner.PersistUtils.executeInTransaction(PersistUtils.java:155)	at org.droidparts.persist.sql.AbstractEntityManager.executeInTransaction(AbstractEntityManager.java:148)	at org.droidparts.persist.sql.AbstractEntityManager.cud(AbstractEntityManager.java:127)	at org.droidparts.persist.sql.AbstractEntityManager.create(AbstractEntityManager.java:90)	at com.vlille.checker.db.DBUpdater.update(DBUpdater.java:33)	at com.vlille.checker.ui.async.DBUpdaterAsyncTask.doInBackground(DBUpdaterAsyncTask.java:32)	at com.vlille.checker.ui.async.DBUpdaterAsyncTask.doInBackground(DBUpdaterAsyncTask.java:12)	at android.os.AsyncTask$2.call(AsyncTask.java:288)	at java.util.concurrent.FutureTask.run(FutureTask.java:237)	at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)	at java.lang.Thread.run(Thread.java:818)