title: Updating List <HashMap>
body: <p>I just want to know how to, if a Hashmap is already on the list add 1 to quantity, if it is not then add it to list. This is what I've done that just add eventhough the item is already on list.</p>
  
  <pre><code>list = new ArrayList&lt;HashMap&lt;String, String&gt;&gt;();
  Cursor c = db.rawQuery("SELECT code,desc,price FROM TbLPrice WHERE code =" + txtCode.getText().toString(), null);  //search database
                  if (c.moveToFirst()){ //if successful
                      txtDesc.setText(c.getString(1)); //get desc 
                      txtPrice.setText(c.getString(2)); // get price @ database
                      HashMap&lt;String, String&gt; map = new HashMap&lt;String, String&gt;();
                      map.put("desc", c.getString(1));
                      map.put("price", c.getString(2));
                      map.put("quantity","1");
                      list.add(map);
                      adapter.notifyDataSetChanged();
  </code></pre>