SQLsqliteOpenHelper 查询 - 如何显示 SQL-语句
SQLiteOpenHelper Query - How to show the SQL-Statment
我想知道是否可以查看 SQL-Statment 由 SQLiteOpenHelper 生成。这是一些示例代码:
String selection = "USER_LOGIN=?";
String[] sectionArgument = new String[]{"username"};
String[] columns = new String[]{"USER_LOGIN", "USER_PASS"};
Cursor c = mDatabase.query("ACCOUNT_TABLE", columns, selection, sectionArgument, null, null, null);
现在如何从 query-Method
.
中查看生成的 SQL-Statment
要查看向 SQLCipher 数据库发出的查询,请参阅 PRAGMA cipher_profile
命令,您可以通过该命令捕获查询及其各自的执行时间(以毫秒为单位)。
我想知道是否可以查看 SQL-Statment 由 SQLiteOpenHelper 生成。这是一些示例代码:
String selection = "USER_LOGIN=?";
String[] sectionArgument = new String[]{"username"};
String[] columns = new String[]{"USER_LOGIN", "USER_PASS"};
Cursor c = mDatabase.query("ACCOUNT_TABLE", columns, selection, sectionArgument, null, null, null);
现在如何从 query-Method
.
要查看向 SQLCipher 数据库发出的查询,请参阅 PRAGMA cipher_profile
命令,您可以通过该命令捕获查询及其各自的执行时间(以毫秒为单位)。