I am trying to run a select using sqllite. Its my first time using sqllite and I am getting this error over and over.
function ="Adding Event
CODE:
public List<Example> getExampleByFunctionList(String function)
{
    List<Example> examplelist = new ArrayList<Example>();
    String getQuery = "SELECT  * FROM " + MySQLiteHelper.TABLE_EXAMPLE+
        " where "+ MySQLiteHelper.COLUMN_EXAMPLE_FUNCTION +" = "+""+function+"";
    Cursor cursor = database.rawQuery(getQuery, null);
    cursor.moveToFirst();
    while (!cursor.isAfterLast()) {
        Example example = cursorToExample(cursor);
        examplelist.add(example);
        cursor.moveToNext();
    }
    cursor.close();
    return examplelist;
}
ERROR:
02-12 12:37:29.218: E/AndroidRuntime(3165): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.tutorial/com.tutorial.ManageCalendar}: android.database.sqlite.SQLiteException: near "Events": syntax error: , while compiling: SELECT * FROM example where examplefunction = Adding Events
 
     
     
    