From 1c6afc7909f34147339f79087efc01af94c5f00a Mon Sep 17 00:00:00 2001 From: Eric House Date: Tue, 28 Jun 2022 08:59:04 -0700 Subject: [PATCH] avoid caught exception with better sql statement --- .../app/src/main/java/org/eehouse/android/xw4/DBHelper.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/DBHelper.java b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/DBHelper.java index a25e33b5b..f9537fe26 100644 --- a/xwords4/android/app/src/main/java/org/eehouse/android/xw4/DBHelper.java +++ b/xwords4/android/app/src/main/java/org/eehouse/android/xw4/DBHelper.java @@ -367,7 +367,7 @@ public class DBHelper extends SQLiteOpenHelper { } langCodeToISOCode( db, TABLE_NAMES.DICTINFO, LANGCODE, ISOCODE ); try { - db.execSQL( "DROP TABLE " + TABLE_NAMES._OBITS + ";" ); + db.execSQL( "DROP TABLE IF EXISTS " + TABLE_NAMES._OBITS + ";" ); } catch ( SQLiteException ex ) { Log.ex( TAG, ex ); }