title: database file can't be found
body: <p>i am trying to use dataBAseHelper class to create database file, but i cant find it on data file (it stills empty). while debugging it, it seems that onCreate method doesn't been called  .
  i tried different databaseHelper versions,but it didnt work.<br />
  you can see my code below (MAinActivity &amp; DataBaseHelper classes):</p>
  <h3>The DatabaseHelper class</h3>
  <pre><code>public class DatabaseHelper extends SQLiteOpenHelper {
      public static final String DATABASE_NAME = &quot;tasks.db&quot;;
      public static final String TABLE_NAME = &quot;task_table&quot;;
      public static final String ID_COL = &quot;ID&quot;;
      public static final String NAME_COL = &quot;NAME&quot;;
      public static final String CATEGORY_COL = &quot;CATEGORY&quot;;
      public static final String DURATION_COL = &quot;DURATION&quot;;
      public static final String DATETIME_COL = &quot;DATETIME&quot;;
      public static final String DESCRIPTION_COL = &quot;DATETIME&quot;;
  
      public DatabaseHelper(Context context) {
          super(context, DATABASE_NAME, null, 1);
      }
  
      @Override
      public void onCreate(SQLiteDatabase db) {
          String CREATE_TABLE_TASKS = &quot;CREATE TABLE &quot; + TABLE_NAME  + &quot;(&quot;
                  + ID_COL + &quot; INTEGER PRIMARY KEY AUTOINCREMENT ,&quot;
                  + NAME_COL + &quot; TEXT, &quot;
                  + DATETIME_COL + &quot; TEXT,&quot;
                  + DURATION_COL + &quot; INTEGER,&quot;
                  + CATEGORY_COL + &quot; TEXT,&quot;
                  + DESCRIPTION_COL + &quot; TEXT &quot; + &quot;)&quot;;
          db.execSQL(CREATE_TABLE_TASKS);
      }
  
      @Override
      public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
          db.execSQL(&quot;DROP TABLE IF EXISTS &quot;+TABLE_NAME);
          onCreate(db);
      }
  
      public boolean insertData(Task task) {
          SQLiteDatabase db = this.getWritableDatabase();
          ContentValues contentValues = new ContentValues();
          contentValues.put(NAME_COL,task.getName());
          contentValues.put(CATEGORY_COL,task.getCategory().toString());
          contentValues.put(DATETIME_COL,task.getDateTime());
          contentValues.put(DURATION_COL,task.getDuration());
          contentValues.put(DESCRIPTION_COL,task.getDescription());
  
          long result = db.insert(TABLE_NAME,null ,contentValues);
          if(result == -1)
              return false;
          else
              return true;
      }
  
      public Cursor getAllData() {
          SQLiteDatabase db = this.getWritableDatabase();
          Cursor res = db.rawQuery(&quot;select * from &quot;+TABLE_NAME,null);
          return res;
      }
  
      public boolean updateData(String id,Task task) {
          SQLiteDatabase db = this.getWritableDatabase();
          ContentValues contentValues = new ContentValues();
          contentValues.put(ID_COL,id);
          contentValues.put(CATEGORY_COL,task.getCategory().toString());
          contentValues.put(DATETIME_COL,task.getDateTime());
          contentValues.put(DURATION_COL,task.getDuration());
          contentValues.put(DESCRIPTION_COL,task.getDescription());
          db.update(TABLE_NAME, contentValues, &quot;ID = ?&quot;,new String[] { id });
          return true;
      }
  
      public Integer deleteData (String id) {
          SQLiteDatabase db = this.getWritableDatabase();
          return db.delete(TABLE_NAME, &quot;ID = ?&quot;,new String[] {id});
      }
  }
  </code></pre>
  <h3>The MainActivity class</h3>
  <pre><code>public class MainActivity extends AppCompatActivity {
      DatabaseHelper data;
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
           data = new DatabaseHelper(this);
          setContentView(R.layout.activity_main);
      }
  
  
      @Override
      public boolean onCreateOptionsMenu(Menu menu){
  
      getMenuInflater().inflate(R.menu.item,menu);
      Intent intent = new Intent(MainActivity.this, addActivity.class);
     // startActivity(intent);
      return super.onCreateOptionsMenu(menu);
  }
  
  
      @Override
      public boolean onOptionsItemSelected(MenuItem item) {
          switch (item.getItemId()) {
              case R.id.add:
  
                  Intent  intent = new Intent(MainActivity.this,addActivity.class);
                  startActivity(intent);
          }
          return super.onOptionsItemSelected(item);
      }
  }
  </code></pre>