Best code examples for SQLiteDatabase endTransaction method (android.database.sqlite.SQLiteDatabase.endTransaction)

These code examples were ranked by Codota’s semantic indexing as the best open source examples for SQLiteDatabase endTransaction method.
You can now enable Codota on your own code to easily search and navigate your Java codebase.

SQLiteDatabase endTransaction examples from Open Source projects
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful
129:	db.beginTransaction(); 
-
131:	persistableResource.store(db, items); 
132:	db.setTransactionSuccessful(); 
-
134:	db.endTransaction(); 
Full Snippet Info
9
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful, update
126:	db.beginTransaction(); 
-
129:	int count = db.update("tests", values, newSelection, selectionArgs); 
130:	db.setTransactionSuccessful(); 
-
134:	db.endTransaction(); 
Full Snippet Info
8
CodeRank
This code example shows how to use the following methods: beginTransaction, delete, endTransaction, setTransactionSuccessful
281:	db.beginTransaction(); 
282:	db.delete(TABLE, COLUMN_USERID + "='" + userId + "'", null); 
283:	db.setTransactionSuccessful(); 
-
285:	db.endTransaction(); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: close, beginTransaction, endTransaction, getVersion, setTransactionSuccessful
121:	int version = db.getVersion(); 
-
123:	db.beginTransaction(); 
-
126:	onCreate(db); 
-
128:	onUpgrade(db, version, mNewVersion); 
-
130:	db.setVersion(mNewVersion); 
131:	db.setTransactionSuccessful(); 
-
133:	db.endTransaction(); 
-
152:	db.close(); 
Full Snippet Info
8
CodeRank
This code example shows how to use the following methods: close, beginTransaction, compileStatement, endTransaction, isOpen
31:	} 
-
34:	return (db != null && db.isOpen()); 
-
40:	db.close(); 
-
79:	db.beginTransaction(); 
-
87:	db.endTransaction(); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, inTransaction
600:	assertThat(database.inTransaction()).isFalse(); 
601:	database.beginTransaction(); 
602:	assertThat(database.inTransaction()).isTrue(); 
603:	database.endTransaction(); 
604:	assertThat(database.inTransaction()).isFalse(); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful
49:	db.beginTransaction(); 
50:	createTables(db); 
51:	initTables(db); 
52:	db.setTransactionSuccessful(); 
53:	db.endTransaction(); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
21:	db.beginTransaction(); 
-
23:	db.execSQL(DbConstants.CREATE_IMAGE_SDCARD_CACHE_TABLE_SQL.toString()); 
24:	db.execSQL(DbConstants.CREATE_IMAGE_SDCARD_CACHE_TABLE_INDEX_SQL.toString()); 
-
26:	db.execSQL(DbConstants.CREATE_HTTP_CACHE_TABLE_SQL.toString()); 
27:	db.execSQL(DbConstants.CREATE_HTTP_CACHE_TABLE_INDEX_SQL.toString()); 
28:	db.execSQL(DbConstants.CREATE_HTTP_CACHE_TABLE_UNIQUE_INDEX.toString()); 
29:	db.setTransactionSuccessful(); 
-
31:	db.endTransaction(); 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, query, setTransactionSuccessful
80:	db.beginTransaction(); 
-
90:	db.setTransactionSuccessful(); 
-
92:	db.endTransaction(); 
-
134:	Cursor cursor = db.query("CalendarMetaData", sCalendarMetaDataProjection, 
Full Snippet Info
7
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful
15:	db.beginTransaction(); 
-
18:	db.setTransactionSuccessful(); 
-
24:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, isReadOnly, setTransactionSuccessful
43:	if(!db.isReadOnly()){ 
-
46:	db.execSQL("create table if not exists bookmark(" 
-
56:	db.execSQL("create table if not exists tmpdir(" 
-
65:	db.beginTransaction(); 
-
67:	db.setTransactionSuccessful(); 
-
69:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, delete, endTransaction, setTransactionSuccessful
131:	database.beginTransaction(); 
-
134:	database.delete(TABLE_NAME, String.format("%s = ?", WALLPAPER_ID), new String[] { id }); 
135:	database.setTransactionSuccessful(); 
-
138:	database.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransactionWithListener, endTransaction, execSQL
93:	mDb.execSQL("PRAGMA cache_size=6000"); 
94:	mDb.execSQL("PRAGMA synchronous=OFF"); 
95:	mDb.execSQL("PRAGMA count_changes=OFF"); 
96:	mDb.beginTransactionWithListener(this); 
-
104:	mDb.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful
94:	db.beginTransaction(); 
-
97:	db.setTransactionSuccessful(); 
-
100:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful
341:	db.beginTransaction(); 
-
361:	db.setTransactionSuccessful(); 
-
364:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, delete, endTransaction, setTransactionSuccessful
178:	mDb.beginTransaction(); 
-
180:	mDb.delete(DATABASE_TABLE_RELATION, KEY_NOTEID + "=" + id, null); 
181:	mDb.delete(DATABASE_TABLE_NOTE, KEY_ROWID + "=" + id, null); 
182:	mDb.setTransactionSuccessful(); 
-
184:	mDb.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, endTransaction, update
388:	db.beginTransaction(); 
-
391:	updated = db.update(mName, t.toContentValues(mTable), whereClause, whereArgs); 
-
394:	db.endTransaction(); 
-
396:	db.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction
202:	db.beginTransaction(); 
-
220:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful
121:	db.beginTransaction(); 
-
124:	db.setTransactionSuccessful(); 
-
126:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, delete, endTransaction, setTransactionSuccessful
57:	database.beginTransaction(); 
58:	database.delete(table, whereClause, whereArgs); 
59:	database.setTransactionSuccessful(); 
-
61:	database.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, insert, setTransactionSuccessful
179:	db.beginTransaction(); 
-
181:	long rowId = db.insert(getTableName(uri), BaseColumns._ID, initialValues); 
-
183:	db.setTransactionSuccessful(); 
184:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, compileStatement, endTransaction
132:	SQLiteStatement sqlStatement = db.compileStatement(sql); 
-
137:	db.beginTransaction(); 
-
150:	db.endTransaction(); 
-
152:	db.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, endTransaction, insert
70:	mDB.beginTransaction();//开始事务 
-
77:	mDB.insert(TABLE_NAME, "_id", values); 
-
82:	mDB.endTransaction();//由事务的标志决定是提交事务,还是回滚事务. 
83:	mDB.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
187:	db.beginTransaction(); 
-
189:	db.execSQL("drop table if exists " + table); 
190:	db.setTransactionSuccessful(); 
-
192:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
111:	db.execSQL("VACUUM;"); 
-
126:	db.beginTransaction(); 
-
128:	db.execSQL(sqlStatement); 
129:	db.setTransactionSuccessful(); 
-
134:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, replace, setTransactionSuccessful
168:	DB.beginTransaction(); 
-
173:	DB.replace(TABLENAME, null, values); 
174:	DB.setTransactionSuccessful(); 
-
176:	DB.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransactionWithListener, endTransaction
93:	mDb.beginTransactionWithListener(this); 
-
101:	mDb.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
74:	db.beginTransaction(); 
-
76:	db.execSQL("CREATE TABLE pictures (" 
-
84:	db.setTransactionSuccessful(); 
-
88:	db.endTransaction(); 
-
103:	db.beginTransaction(); 
-
106:	db.execSQL("DROP TABLE IF EXISTS apod"); 
107:	db.execSQL("DROP TABLE IF EXISTS pictures"); 
108:	db.setTransactionSuccessful(); 
-
112:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, delete, endTransaction, setTransactionSuccessful
297:	db.beginTransaction(); 
-
311:	db.beginTransaction(); 
312:	result = db 
-
314:	db.setTransactionSuccessful(); 
-
316:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
121:	db.execSQL("VACUUM;"); 
-
136:	db.beginTransaction(); 
-
138:	db.execSQL(sqlStatement); 
139:	db.setTransactionSuccessful(); 
-
144:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, endTransaction, update
59:	mDB.beginTransaction();//开始事务 
-
61:	mDB.update(TABLE_NAME, values, "_id = '"+id+"'", null); 
-
66:	mDB.endTransaction();//由事务的标志决定是提交事务,还是回滚事务. 
-
185:	mDB.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
203:	db.execSQL("CREATE TABLE favorites (" + 
-
224:	db.execSQL("CREATE TABLE gestures (" + 
-
348:	db.beginTransaction(); 
-
351:	db.execSQL("ALTER TABLE favorites " + 
-
353:	db.setTransactionSuccessful(); 
-
359:	db.endTransaction(); 
-
369:	db.beginTransaction(); 
-
371:	db.execSQL("CREATE TABLE gestures (" + 
-
381:	db.setTransactionSuccessful(); 
-
387:	db.endTransaction(); 
-
393:	db.execSQL("DROP TABLE IF EXISTS " + TABLE_FAVORITES); 
394:	db.execSQL("DROP TABLE IF EXISTS " + TABLE_GESTURES); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
33:	db.beginTransaction(); 
-
49:	db.execSQL(createSql.toString()); 
50:	db.setTransactionSuccessful(); 
-
52:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, setTransactionSuccessful, update
260:	database.beginTransaction(); 
-
264:	database.update(TABLE_WATCHLIST, values, KEY_WATCHLIST_SYMBOL + "=?", new String[] { symbol2 }); 
-
268:	database.update(TABLE_WATCHLIST, values, KEY_WATCHLIST_SYMBOL + "=?", new String[] { symbol1 }); 
-
270:	database.setTransactionSuccessful(); 
-
273:	database.endTransaction(); 
Full Snippet Info
5
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
281:	db.beginTransaction(); 
282:	db.execSQL(CREATE_TABLE); 
283:	db.setTransactionSuccessful(); 
-
295:	db.endTransaction(); 
-
309:	db.beginTransaction(); 
310:	db.execSQL(DROP_TABLE); 
311:	db.setTransactionSuccessful(); 
-
323:	db.endTransaction(); 
Full Snippet Info
5
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
89:	db.execSQL("VACUUM;"); 
-
104:	db.beginTransaction(); 
-
106:	db.execSQL(sqlStatement); 
107:	db.setTransactionSuccessful(); 
-
112:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, endTransaction, insertOrThrow, setTransactionSuccessful
138:	db.beginTransaction(); 
-
140:	result = db.insertOrThrow(UserDatabase.TABLE_USER_FTS, null, userValues); 
-
142:	db.setTransactionSuccessful(); 
-
144:	db.endTransaction(); 
-
147:	db.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, compileStatement, endTransaction, setTransactionSuccessful
212:	SQLiteStatement sqlStatement = db.compileStatement("INSERT INTO eyepieces (type, focalLength) VALUES (?, ?)"); 
-
216:	db.beginTransaction(); 
-
220:	db.setTransactionSuccessful(); 
-
229:	db.endTransaction(); 
-
231:	db.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
39:	db.beginTransaction(); 
40:	db.execSQL("DELETE FROM sounds WHERE fileName = ?"); 
41:	db.setTransactionSuccessful(); 
42:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: close, beginTransaction, endTransaction, execSQL, setTransactionSuccessful
22:	db.beginTransaction(); 
-
24:	db.execSQL("INSERT INTO usermail VALUES(NULL,?)", 
-
26:	db.setTransactionSuccessful(); 
-
30:	db.endTransaction(); 
31:	db.close(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
27:	db.beginTransaction(); 
28:	db.execSQL("CREATE TABLE tasks (_id INTEGER PRIMARY KEY AUTOINCREMENT, content TEXT, date_created DATE);"); 
29:	db.setTransactionSuccessful(); 
-
31:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
This code example shows how to use the following methods: beginTransaction, endTransaction, execSQL, setTransactionSuccessful
41:	db.beginTransaction(); 
-
44:	db.execSQL("create table allreports (" 
-
52:	db.setTransactionSuccessful(); 
-
56:	db.endTransaction(); 
Full Snippet Info
6
CodeRank
Related SQLiteDatabase endTransaction Questions & Answers:
endTransaction Method Overview
End a transaction.
See Also