From 9bf225ef7b82b5eacee1907155a8a8bbb6aa7f42 Mon Sep 17 00:00:00 2001 From: Vasu Nori Date: Wed, 7 Jul 2010 16:38:28 -0700 Subject: [PATCH] documentation about not using journal_mode if using WAL apps should not setting journal_mode if the application is using a connection pool for readers by calling the method SQLiteDatabase.enableWriteAheadLogging() Change-Id: I9ddb32638171c6277ca94381a1b5d4b39b92b386 --- .../java/android/database/sqlite/SQLiteDatabase.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/core/java/android/database/sqlite/SQLiteDatabase.java b/core/java/android/database/sqlite/SQLiteDatabase.java index fa79a9e56440c..3c5a0290f3dc0 100644 --- a/core/java/android/database/sqlite/SQLiteDatabase.java +++ b/core/java/android/database/sqlite/SQLiteDatabase.java @@ -1837,6 +1837,12 @@ public class SQLiteDatabase extends SQLiteClosable { * Instead, you're encouraged to use {@link #insert(String, String, ContentValues)}, * {@link #update(String, ContentValues, String, String[])}, et al, when possible. *

+ *

+ * When using {@link #enableWriteAheadLogging()}, journal_mode is + * automatically managed by this class. So, do not set journal_mode + * using "PRAGMA journal_mode'" statement if your app is using + * {@link #enableWriteAheadLogging()} + *

* * @param sql the SQL statement to be executed. Multiple statements separated by semicolons are * not supported. @@ -1904,6 +1910,12 @@ public class SQLiteDatabase extends SQLiteClosable { *
  • PRAGMA that returns no data
  • * *

    + *

    + * When using {@link #enableWriteAheadLogging()}, journal_mode is + * automatically managed by this class. So, do not set journal_mode + * using "PRAGMA journal_mode'" statement if your app is using + * {@link #enableWriteAheadLogging()} + *

    * * @param sql the SQL statement to be executed. Multiple statements separated by semicolons are * not supported.