/frameworks/base/core/java/android/database/sqlite/ |
D | SQLiteTokenizer.java | 56 private static IllegalArgumentException genException(String message, String sql) { in genException() argument 57 throw new IllegalArgumentException(message + " in '" + sql + "'"); in genException() 77 public static List<String> tokenize(@Nullable String sql, int options) { in tokenize() argument 79 tokenize(sql, options, res::add); in tokenize() 89 public static void tokenize(@Nullable String sql, int options, Consumer<String> checker) { in tokenize() argument 90 if (sql == null) { in tokenize() 94 final int len = sql.length(); in tokenize() 96 final char ch = peek(sql, pos); in tokenize() 102 while (isAlNum(peek(sql, pos))) { in tokenize() 107 final String token = sql.substring(start, end); in tokenize() [all …]
|
D | SQLiteSession.java | 576 public void prepare(String sql, int connectionFlags, CancellationSignal cancellationSignal, in prepare() argument 578 if (sql == null) { in prepare() 586 acquireConnection(sql, connectionFlags, cancellationSignal); // might throw in prepare() 588 mConnection.prepare(sql, outStatementInfo); // might throw in prepare() 607 public void execute(String sql, Object[] bindArgs, int connectionFlags, in execute() argument 609 if (sql == null) { in execute() 613 if (executeSpecial(sql, bindArgs, connectionFlags, cancellationSignal)) { in execute() 617 acquireConnection(sql, connectionFlags, cancellationSignal); // might throw in execute() 619 mConnection.execute(sql, bindArgs, cancellationSignal); // might throw in execute() 640 public long executeForLong(String sql, Object[] bindArgs, int connectionFlags, in executeForLong() argument [all …]
|
D | SQLiteQueryBuilder.java | 505 final String sql; in query() local 535 sql = wrappedSql; in query() 538 sql = unwrappedSql; in query() 544 Log.d(TAG, sql + " with args " + Arrays.toString(sqlArgs)); in query() 546 Log.d(TAG, sql); in query() 550 mFactory, sql, sqlArgs, in query() 576 final String sql; in update() local 603 sql = wrappedSql; in update() 606 sql = unwrappedSql; in update() 624 Log.d(TAG, sql + " with args " + Arrays.toString(sqlArgs)); in update() [all …]
|
D | SQLiteConnection.java | 127 private static native long nativePrepareStatement(long connectionPtr, String sql); in nativePrepareStatement() argument 450 boolean isPreparedStatementInCache(String sql) { in isPreparedStatementInCache() argument 451 return mPreparedStatementCache.get(sql) != null; in isPreparedStatementInCache() 494 public void prepare(String sql, SQLiteStatementInfo outStatementInfo) { in prepare() argument 495 if (sql == null) { in prepare() 499 final int cookie = mRecentOperations.beginOperation("prepare", sql, null); in prepare() 501 final PreparedStatement statement = acquirePreparedStatement(sql); in prepare() 541 public void execute(String sql, Object[] bindArgs, in execute() argument 543 if (sql == null) { in execute() 547 final int cookie = mRecentOperations.beginOperation("execute", sql, bindArgs); in execute() [all …]
|
D | SQLiteDatabase.java | 1067 public SQLiteStatement compileStatement(String sql) throws SQLException { in compileStatement() argument 1070 return new SQLiteStatement(this, sql, null); in compileStatement() 1236 String sql = SQLiteQueryBuilder.buildQueryString( in queryWithFactory() local 1239 return rawQueryWithFactory(cursorFactory, sql, selectionArgs, in queryWithFactory() 1330 public Cursor rawQuery(String sql, String[] selectionArgs) { in rawQuery() argument 1331 return rawQueryWithFactory(null, sql, selectionArgs, null, null); in rawQuery() 1347 public Cursor rawQuery(String sql, String[] selectionArgs, in rawQuery() argument 1349 return rawQueryWithFactory(null, sql, selectionArgs, null, cancellationSignal); in rawQuery() 1365 CursorFactory cursorFactory, String sql, String[] selectionArgs, in rawQueryWithFactory() argument 1367 return rawQueryWithFactory(cursorFactory, sql, selectionArgs, editTable, null); in rawQueryWithFactory() [all …]
|
D | SQLiteStatement.java | 30 SQLiteStatement(SQLiteDatabase db, String sql, Object[] bindArgs) { in SQLiteStatement() argument 31 super(db, sql, bindArgs, null); in SQLiteStatement()
|
D | SQLiteDirectCursorDriver.java | 37 public SQLiteDirectCursorDriver(SQLiteDatabase db, String sql, String editTable, in SQLiteDirectCursorDriver() argument 41 mSql = sql; in SQLiteDirectCursorDriver()
|
D | SQLiteConnectionPool.java | 367 public SQLiteConnection acquireConnection(String sql, int connectionFlags, in acquireConnection() argument 369 SQLiteConnection con = waitForConnection(sql, connectionFlags, cancellationSignal); in acquireConnection() 645 private SQLiteConnection waitForConnection(String sql, int connectionFlags, in waitForConnection() argument 664 sql, connectionFlags); // might throw in waitForConnection() 677 priority, wantPrimaryConnection, sql, connectionFlags); in waitForConnection() 922 String sql, int connectionFlags) { in tryAcquireNonPrimaryConnectionLocked() argument 926 if (availableCount > 1 && sql != null) { in tryAcquireNonPrimaryConnectionLocked() 931 if (connection.isPreparedStatementInCache(sql)) { in tryAcquireNonPrimaryConnectionLocked() 1040 int priority, boolean wantPrimaryConnection, String sql, int connectionFlags) { in obtainConnectionWaiterLocked() argument 1052 waiter.mSql = sql; in obtainConnectionWaiterLocked()
|
D | SQLiteCursor.java | 263 String sql = mQuery.getSql(); in finalize() local 264 int len = sql.length(); in finalize() 269 ", query = " + sql.substring(0, (len > 1000) ? 1000 : len), in finalize()
|
D | SQLiteProgram.java | 40 SQLiteProgram(SQLiteDatabase db, String sql, Object[] bindArgs, in SQLiteProgram() argument 43 mSql = sql.trim(); in SQLiteProgram()
|
/frameworks/support/persistence/db-framework/src/main/java/android/arch/persistence/db/framework/ |
D | FrameworkSQLiteDatabase.java | 61 public SupportSQLiteStatement compileStatement(String sql) { in compileStatement() argument 62 return new FrameworkSQLiteStatement(mDelegate.compileStatement(sql)); in compileStatement() 207 StringBuilder sql = new StringBuilder(120); 208 sql.append("UPDATE "); 209 sql.append(CONFLICT_VALUES[conflictAlgorithm]); 210 sql.append(table); 211 sql.append(" SET "); 219 sql.append((i > 0) ? "," : ""); 220 sql.append(colName); 222 sql.append("=?"); [all …]
|
/frameworks/base/core/tests/coretests/src/android/database/ |
D | DatabaseCursorTest.java | 110 String sql = "INSERT INTO test (s, d, l, b) VALUES (?,?,?,?)"; in testBlob() local 111 mDatabase.execSQL(sql, args); in testBlob() 240 StringBuilder sql = new StringBuilder(2100); in testLargeField() local 241 sql.append("INSERT INTO test (data) VALUES ('"); in testLargeField() 247 sql.append(randomString); in testLargeField() 248 sql.append("');"); in testLargeField() 249 mDatabase.execSQL(sql.toString()); in testLargeField() 321 StringBuilder sql = new StringBuilder(2100); in testManyRowsTxt() local 322 sql.append("INSERT INTO test (data) VALUES ('"); in testManyRowsTxt() 328 sql.append(randomString); in testManyRowsTxt() [all …]
|
D | DatabaseLocaleTest.java | 65 private String[] query(String sql) { in query() argument 66 Log.i("LocaleTest", "Querying: " + sql); in query() 67 Cursor c = mDatabase.rawQuery(sql, null); in query()
|
/frameworks/base/core/tests/coretests/src/android/database/sqlite/ |
D | SQLiteTokenizerTest.java | 30 private List<String> getTokens(String sql) { in getTokens() argument 31 return SQLiteTokenizer.tokenize(sql, SQLiteTokenizer.OPTION_NONE); in getTokens() 34 private void checkTokens(String sql, String spaceSeparatedExpectedTokens) { in checkTokens() argument 39 assertEquals(expected, getTokens(sql)); in checkTokens() 42 private void assertInvalidSql(String sql, String message) { in assertInvalidSql() argument 44 getTokens(sql); in assertInvalidSql()
|
/frameworks/support/room/compiler/src/main/kotlin/android/arch/persistence/room/verifier/ |
D | DatabaseVerifier.kt | 24 import java.sql.Connection in <lambda>() 25 import java.sql.DriverManager in <lambda>() 26 import java.sql.SQLException in <lambda>() 71 fun analyze(sql : String) : QueryResultInfo { in <lambda>() 73 val stmt = connection.prepareStatement(sql) in <lambda>()
|
D | jdbc_ext.kt | 19 import java.sql.PreparedStatement in <lambda>() 20 import java.sql.ResultSet in <lambda>() 21 import java.sql.ResultSetMetaData in <lambda>() 22 import java.sql.SQLException in <lambda>()
|
D | QueryResultInfo.kt | 19 import java.sql.SQLException
|
D | DatabaseVerificaitonErrors.kt | 19 import java.sql.SQLException
|
/frameworks/support/room/integration-tests/testapp/src/androidTest/java/android/arch/persistence/room/integration/testapp/test/ |
D | IndexingTest.java | 65 public String sql; field in IndexingTest.IndexInfo 88 assertThat(indices.get(0).sql, is("CREATE INDEX `index_foo_table_field1_field2`" in verifyIndices() 90 assertThat(indices.get(1).sql, is("CREATE UNIQUE INDEX `index_foo_table_field2_mId`" in verifyIndices() 92 assertThat(indices.get(2).sql, is("CREATE UNIQUE INDEX `customIndex`" in verifyIndices() 94 assertThat(indices.get(3).sql, is("CREATE INDEX `index_foo_table_my_field`" in verifyIndices()
|
/frameworks/base/core/tests/coretests/src/android/content/ |
D | MemoryFileProvider.java | 136 String sql = "SELECT _blob FROM data WHERE _id=" + url.getPathSegments().get(1); in openFile() local 137 return getBlobColumnAsFile(url, mode, sql); in openFile() 152 private ParcelFileDescriptor getBlobColumnAsFile(Uri url, String mode, String sql) in getBlobColumnAsFile() argument 159 return DatabaseUtils.blobFileDescriptorForQuery(db, sql, null); in getBlobColumnAsFile()
|
/frameworks/support/persistence/db/src/main/java/android/arch/persistence/db/ |
D | SupportSQLiteDatabase.java | 46 SupportSQLiteStatement compileStatement(String sql); in compileStatement() argument 376 void execSQL(String sql) throws SQLException; in execSQL() argument 394 void execSQL(String sql, Object[] bindArgs) throws SQLException; in execSQL() argument
|
/frameworks/base/test-runner/src/android/test/ |
D | ProviderTestCase.java | 97 String databaseName, int databaseVersion, String sql) in newResolverWithContentProviderFromSql() argument 107 DatabaseUtils.createDbFromSqlStatements(context, databaseName, databaseVersion, sql); in newResolverWithContentProviderFromSql()
|
D | ProviderTestCase2.java | 222 String databaseName, int databaseVersion, String sql) in newResolverWithContentProviderFromSql() argument 230 DatabaseUtils.createDbFromSqlStatements(context, databaseName, databaseVersion, sql); in newResolverWithContentProviderFromSql()
|
/frameworks/base/core/java/android/database/ |
D | DatabaseUtils.java | 368 public static final void appendValueToSql(StringBuilder sql, Object value) { in appendValueToSql() argument 370 sql.append("NULL"); in appendValueToSql() 374 sql.append('1'); in appendValueToSql() 376 sql.append('0'); in appendValueToSql() 379 appendEscapedSQLString(sql, value.toString()); in appendValueToSql() 1391 public static int getSqlStatementType(String sql) { in getSqlStatementType() argument 1392 sql = sql.trim(); in getSqlStatementType() 1393 if (sql.length() < 3) { in getSqlStatementType() 1396 String prefixSql = sql.substring(0, 3).toUpperCase(Locale.ROOT); in getSqlStatementType()
|
/frameworks/support/room/compiler/src/test/kotlin/android/arch/persistence/room/verifier/ |
D | DatabaseVerifierTest.kt | 42 import java.sql.Connection in <lambda>() 165 private fun validQueryTest(sql: String, cb: (QueryResultInfo) -> Unit) { in <lambda>() 168 val info = verifier.analyze(sql) in <lambda>()
|