title: Is my SQLite Database created anew each time I start the application?
body: <p>I have an app that Im working on and I wonder what happens to my Database when I close my application and start it again, because I never specify what happens on onPause, onResume and onDestroy (because I dont know what to specify there).</p>
  
  <p>Here is my DBTools class</p>
  
  <pre><code>public class DBTools extends SQLiteOpenHelper {
  
      public DBTools(Context applicationcontext) {
          super(applicationcontext, "rggarb.db", null, 1);
      }
  
      public void onCreate(SQLiteDatabase database) {
  
          String tableUsers = "CREATE TABLE users ( userId INTEGER PRIMARY KEY, userName TEXT, userEmail TEXT, userPassword TEXT, userAvatar TEXT, userSex TEXT)";
          database.execSQL(tableUsers);
  
      }
  
      public void onUpgrade(SQLiteDatabase database, int version_old, int current_version) {
          String dropTableUsers = "DROP TABLE IF EXISTS tableUsers";
          database.execSQL(dropTableUsers);
          onCreate(database);
      }
               //some CRUD methods here, irrelevant for this question
  
  }
  </code></pre>
  
  <p>and here is how I operate with it</p>
  
  <p>in MainActivity:</p>
  
  <pre><code>public class MainActivity extends Activity  {
      DBTools dbTools = new DBTools(this);
  </code></pre>
  
  <p>then the user goes to Signup activity, and there:</p>
  
  <p>public class Signup extends Activity  {</p>
  
  <pre><code>private DBTools dbTools = new DBTools(this);
      //later on in this class I do some checks and inserts.
  </code></pre>
  
  <p>I suspect something might be wrong and Im not familiar with the lifecycle of the DB the way Im using it. Does it go blank on each onDestroy? do I need to instantiate it in MainActivity every time? if I have instantiated it there, do I need to instatiate it yet again in Signup Activity?</p>