title: How to get DISTINCT values from the database?
body: <p>I would like to get values from the database in this format </p>
  
  <p>1   Audi<br>
  3   Nissan</p>
  
  <p>But I am getting like this as of now. I don't need to get to include the _id in the output.But I couldn't eliminate as it throws a NullPointerException when I remove it.</p>
  
  <pre><code>id  MAKE
  ========= 
  1   Audi  
  2   Audi  
  3   Nissan  
  4   Audi
  </code></pre>
  
  <p>this is my query I have used in</p>
  
  <pre><code>cursor = db.rawQuery(
      "SELECT DISTINCT _id,MAKE FROM "+SQLiteAdapter.MYDATABASE_TABLE+
      " WHERE MAKE || ' ' || MODEL LIKE ?", new String[]{"%" + "" + "%"}
  );
  </code></pre>
  
  <p>Do have I to change the sequence entirely to get the output or make changes on the above code.Thanks.</p>
  
  <p>my code</p>
  
  <pre><code>cursor = db.rawQuery("SELECT DISTINCT SERIES FROM "+SQLiteAdapter.MYDATABASE_TABLE+" WHERE YEAR=2012 AND MAKE='Audi' AND MODEL=?", new String[]{"A6"});
  
  adapter = new SimpleCursorAdapter(this, R.layout.employee_list_item, cursor, new String[] {"series"}, new int[] {R.id.firstName});
  
  employeeList.setAdapter(adapter);
  </code></pre>