Databases in Android
<p>I need to improve the speed of this query,it takes too long(16992ms) and the SQLite Admin makes it much faster</p>

<pre><code>public Cursor getContacts(String search)
    {

        Cursor c;

        String[]columns = {Constants.USER_NAME,Constants.PHONE_NUMBER};        
        String Limit = "0,20";
        String query = search != null ? Constants.USER_NAME + " LIKE '" + search + "%' " : "";

        c = myDataBase.query(Constants.TABLE_NAME,columns, query, null, null, null, null, Limit);

        return c;
    }
</code></pre>
