[Android] Do not use "IF NOT EXISTS" with Virtual tables
Jean-Baptiste Kempf
git at videolan.org
Sat Mar 14 16:07:29 CET 2015
vlc-ports/android | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sat Mar 14 16:06:58 2015 +0100| [3befc17f509eb6657eff0dc9ece5f078b97d3025] | committer: Jean-Baptiste Kempf
Do not use "IF NOT EXISTS" with Virtual tables
Explodes with 4.0.x
See https://stackoverflow.com/questions/19849068/near-not-syntax-error-while-compiling-create-virtual-table-if-not-exists
> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=3befc17f509eb6657eff0dc9ece5f078b97d3025
---
vlc-android/src/org/videolan/vlc/MediaDatabase.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vlc-android/src/org/videolan/vlc/MediaDatabase.java b/vlc-android/src/org/videolan/vlc/MediaDatabase.java
index d171d53..5673e66 100644
--- a/vlc-android/src/org/videolan/vlc/MediaDatabase.java
+++ b/vlc-android/src/org/videolan/vlc/MediaDatabase.java
@@ -195,7 +195,7 @@ public class MediaDatabase {
+ ");";
db.execSQL(query);
db.execSQL("PRAGMA recursive_triggers='ON'"); //Needed for delete trigger
- query = "CREATE VIRTUAL TABLE IF NOT EXISTS "
+ query = "CREATE VIRTUAL TABLE "
+ MEDIA_VIRTUAL_TABLE_NAME + " USING FTS3 ("
+ MEDIA_LOCATION + ", "
+ MEDIA_TITLE + ", "
More information about the Android
mailing list