Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
1 つのレコードを挿入すると、重複したエントリが生成されます。つまり、合計 2 つの同じエントリが表示されます。select ステートメントに対する私のクエリは次のとおりです。
Cursor cur = db.query("timer", null, null, null, null, null, null);
明確な選択を行うには、次のようなブール変数を定義します。
private boolean Distinct = true;
次に、クエリを次のように変更します。
c = db.query(Distinct,DATABASE_TABLE,cols,null,null, null, null, null,null);