public Cursor query (SQLiteDatabase db, String[] projectionIn, String selection, String[] selectionArgs, String groupBy, String having, String sortOrder, String limit)
public Cursor query (SQLiteDatabase db, String[] projectionIn, String selection, String[] selectionArgs, String groupBy, String having, String sortOrder)
Since: API Level 1
Perform a query by combining all current settings and the information passed into this method.
Parameters
db | the database to query on |
---|---|
projectionIn | 傳入要取回的欄位名稱陣列,若傳入null時則傳回所有欄位資料 |
selection | SQL WHERE 敘述據的條件資料. null 則傳回所有資料 |
selectionArgs | 若 WHERE 條件敘述內有使用 ? 變數, 則變數資料由此帶入 |
groupBy | SQL GROUP BY 條件設定 |
having | SQL HAVING 條件設定 |
sortOrder | SQL ORDER BY 條件設定 |
limit | 限定傳回筆數, null 則不限定 |
Returns
- a cursor over the result set