title: how to delete a record from ORMLITE?
body: <p>I need to delete a record from ORMLite Database I can delete a record by id using  as below</p>
  
  <pre><code>@Override
  public void Delete(int id) throws SQLException {
      this.dao.deleteById(id);
  }
  </code></pre>
  
  <p>but what if I have to delete a record from same table not by id but by name or any other field
  I want something like </p>
  
  <pre><code>public void Deletefromcanteen(String name,MealType mealtype) {
      this.dao.deletebyName(name);
  }
  </code></pre>
  
  <p>what query should i write using querybuilder to delete a record where name = name and mealtype = say (lunch)</p>
  
  <p>I tried something like this in my databasehelper class</p>
  
  <pre><code>public  void deletefromcanteen(int id, String mealtype) {
      try {
          Dao&lt;CanteenLog, Integer&gt; canteenDao = getCanteen();
          DeleteBuilder&lt;CanteenLog, Integer&gt; deleteBuilder = canteenDao
                  .deleteBuilder();
          deleteBuilder.where().eq("user_id", id).and().eq("meal", mealtype);
          canteenDao.delete(deleteBuilder.prepare());
      } catch (Exception e) {
          ...
      }
  }
  </code></pre>