title: how to get a list of rows that have the same value in a column?
body: <p>I need to get all rows that have the same value "r_c" in "Tname" column from the table of my db.</p>
  
  <pre><code> public ArrayList&lt;String&gt; getDb2(String r_c ){
      ArrayList&lt;String&gt; dd = new ArrayList&lt;&gt;();
      String KW = r_c.toString();
      String selection = "Tname " + "like ? ";
  
      Cursor cursor = db.query("info", null,selection,new String[]{"%"+KW+"%"},null,null,null);
      if(cursor !=null &amp;&amp; cursor.moveToFirst()){
          do{
              dd.add(cursor.getString(0)+"\n " + "From :  " +cursor.getString(2)+"\n "+"price : " + cursor.getString(1)+" \n "+"Nots : " + cursor.getString(3));
          }
          while (cursor.moveToNext());
      }
      return dd ;
  }
  </code></pre>