Unable to start activity , no such table (sqlite)
<p>I have a problem that I have never met.</p>

<p>This is a part of my logcat :</p>

<blockquote>
  <p>FATAL EXCEPTION: main
                                                                        Process: ad.training.repertoire, PID: 1108
                                                                        java.lang.RuntimeException: Unable to start activity
  ComponentInfo{ad.training.repertoire/ad.training.repertoire.MainActivity}:
  android.database.sqlite.SQLiteException: no such table: Ichar (code
  1): , while compiling: select * FROM Ichar</p>
</blockquote>

<p>and the lines concerned :</p>

<blockquote>
  <p>at ad.training.repertoire.MySQLite.donneesBDD(MySQLite.java:73)
                                                                            at ad.training.repertoire.MainActivity.onCreate(MainActivity.java:35)</p>
</blockquote>

<pre><code>My MainActivity :

    public class MainActivity extends AppCompatActivity  {

    MySQLite sqlite;
    List&lt;Character&gt; characters;
    RecyclerView mRecyclerView;
    private RecyclerView.Adapter mAdapter;
    private RecyclerView.LayoutManager mLayoutManager;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
        setSupportActionBar(toolbar);
        getSupportActionBar().setDisplayHomeAsUpEnabled(true);


        sqlite = new MySQLite(this);
        characters= new ArrayList&lt;Character&gt;();


 **Ligne 35 : characters = sqlite.donneesBDD();**


        mRecyclerView = (RecyclerView)findViewById(R.id.recyclerView);

        mRecyclerView.setHasFixedSize(true);


        mLayoutManager = new LinearLayoutManager(this);
        mRecyclerView.setLayoutManager(mLayoutManager);

        mAdapter = new MyAdapter(this,characters);
        mRecyclerView.setAdapter(mAdapter);

    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        getMenuInflater().inflate(R.menu.menu_main, menu);
        return true;
    }



    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        switch (item.getItemId()) {
            case android.R.id.home:
                finish();
                return true;
        }
        return super.onOptionsItemSelected(item);
    }
}
</code></pre>

<p>and my MySQLite :</p>

<pre><code>public class MySQLite extends SQLiteOpenHelper {

private static final String DATABASE_NAME = "character";
private static final int DATABASE_VERSION = 1;
private static final String CHARACTER_TABLE = "Ichar";
private static final String CHAR_TABLE = "create table " + CHARACTER_TABLE + "(nom TEXT,prenom TEXT ,numero TEXT primary key)";


Context context;


public MySQLite(Context context) {
    super(context, DATABASE_NAME, null, DATABASE_VERSION);
    this.context = context;
}

@Override
public void onCreate(SQLiteDatabase db) {
    // Création de la base de données
    // on exécute ici les requêtes de création des tables
    db.execSQL(CHAR_TABLE); // création table "character"
}

@Override
public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
    // Mise à jour de la base de données
    // méthode appelée sur incrémentation de DATABASE_VERSION
    // on peut faire ce qu'on veut ici, comme recréer la base :
    onCreate(db);
}


public void InsererBDD(String nom, String prenom, String numero) {

    Log.d("insert", "before insert");

    SQLiteDatabase db = this.getWritableDatabase();

    ContentValues entree = new ContentValues();
    entree.put("nom", nom);
    entree.put("prenom", prenom);
    entree.put("numero", numero);

    db.insert(CHARACTER_TABLE, null, entree);

    db.close();
    Toast.makeText(context, "insérer entrée", Toast.LENGTH_LONG);

    Log.i("insert", "after insert");
}


public List&lt;Character&gt; donneesBDD() {

    List&lt;Character&gt; modelList = new ArrayList&lt;Character&gt;();
    String query = "select * FROM " + CHARACTER_TABLE;

    SQLiteDatabase db = this.getWritableDatabase();
</code></pre>

<p><strong>ligne 73 : Cursor cursor = db.rawQuery(query, null);</strong></p>

<pre><code>    if (cursor.moveToFirst()) {
        do {
            Character model = new Character();
            model.setNom(cursor.getString(0));
            model.setPrenom(cursor.getString(1));
            model.setNumero(cursor.getString(2));

            modelList.add(model);

        } while (cursor.moveToNext());
    }

    Log.d("donnee character", modelList.toString());


    return modelList;

}

public void supprimerLigne(String numero){

    SQLiteDatabase db = getWritableDatabase();
    db.delete(CHARACTER_TABLE , " numero" + " = ?", new String[] {numero});



}
</code></pre>

<p>}</p>

<p>Can you help me?</p>

<p>Thanks</p>