title: SQLite on Android return wrong result
body: <p>I'm having some troubles querying my SQLite DB from my Android APP.</p>
  
  <p>This is the table I'm querying:</p>
  
  <pre><code>id | customerCode | invoiceNumber | openAmount | grossAmount
  </code></pre>
  
  <p>and this are the datas:</p>
  
  <pre><code>1 | 1 | 1 | -1.00 | -1.00
  2 | 1 | 1 | 1.00 | 1.00
  3 | 1 | 1 | 10.00 | 10.00
  4 | 1 | 2 | 0.00 | 20.00
  5 | 1 | 3 | 0.00 | 30.00
  </code></pre>
  
  <p>I'm trying to fetch only the lines which have <code>openAmount != "0.00"</code> and the query is:</p>
  
  <pre><code>String whereClause = MyTable.CUSTOMER_CODE + " = ? "
                  + "and " + MyTable.OPEN_AMOUNT + " != \"0.00\"";
  
  Cursor cur = mDb.query(MyTable.TABLE, null, whereClause, new String[]{customerId}, null, null, null);
  </code></pre>
  
  <p>The result I expect is that the query fetch the first 3 lines from my table, and this is the result I obtain if I query the DB from an external application (like <a href="https://play.google.com/store/apps/details?id=air.SQLite.Magic" rel="nofollow">SQLite Magic</a>).</p>
  
  <p>BUT... when I run the query from my Application, I obtain only the line with <code>openAmount = -1.00</code>.</p>
  
  <p>I've tried a lot of solutions, like changing the where condition to fetch all the lines, but it seems that querying from my App not reads line <code>2</code> and <code>3</code>.</p>
  
  <p>I can't figure out a solution. 
  A little help would be appreciated.</p>
  
  <p><strong>EDIT</strong></p>
  
  <ol>
  <li>All columns are <code>TEXT</code>. </li>
  <li>It's not relevant how I iterate trhough the
  datas, in fact the cursor altready returns a wrong number of lines.</li>
  </ol>
  
  <p><strong>EDIT 2</strong></p>
  
  <p>I'm cycling though the result Cursor, and this is how i do it:</p>
  
  <pre><code>    List&lt;MyObject&gt; list = new ArrayList&lt;&gt;();
      MyObject obj;
  
      //initialization of columnsIndex
      //int idx1 = cur.getColumnIndex(columnName);
  
      if (cur.moveToFirst()) {
          do {
              obj = new MyObject();
              //set obj data
              list.add(obj);
          } while (cur.moveToNext());
  
      }
      cur.close();
  </code></pre>