How To Get Errors Details From Android.database.sqlexception?
I have a database in my android app with two separate columns that have a UNIQUE constraint. When entering data and an SQLException exception is thrown I want to know which field's
Solution 1:
The class java.lang.SQLException
on which android.database.SQLException
is based has methods int getErrorCode()
and String getSQLState()
which should be able to help you get details.
Post a Comment for "How To Get Errors Details From Android.database.sqlexception?"