title: How to check value of column exist or not in sqlite android?
body: <p>This is my code:   </p>
  
  <pre><code>public boolean checkIDTraLoiBangID(int Id)
  {
      boolean check = false;
      String query = "select IDTraLoi from BangCauHoi where ID=?";
      Cursor c = database.rawQuery(query, new String[] { "" + Id });
      if (c != null &amp;&amp; c.moveToFirst())
      {
          check = true;
      }
      c.close();
      return check;
  }
  </code></pre>
  
  <p>I'm trying to check value of <code>IDTraLoi</code> exist or not follow <code>where</code> clause. But, even in column <code>IDTraLoi</code> have no value this function still return <code>true</code>.</p>
  
  <p>Somebody can help me please?
  Thank you and sorry because my english...</p>