title: Sqlite exception while trying to add parsed values of json to a sqlite table
body: <p>Im using the following query to create a table with name shippingMaster.</p>
  
  <p><code>private static final String CREATE_SHIPMENTMASTER_TABLE = "CREATE TABLE " + TABLE_SHIPMENTMASTER + "("+ KEY_ID + " INTEGER PRIMARY KEY," + KEY_STATUS + " TEXT" + ")";</code></p>
  
  <p>within onCreate method, I'm executing the above query.</p>
  
  <p>To add values to the database, Im using the following method,</p>
  
  <pre><code>public void addShipmentMaster (ShipmentMasterDao shipmentMasterDao){
      SQLiteDatabase db = this.getWritableDatabase();
      ContentValues values = new ContentValues();
  
      values.put(KEY_ID, shipmentMasterDao.getId());
      values.put(KEY_STATUS,shipmentMasterDao.getStatus());
  
      db.insert(TABLE_SHIPMENTMASTER, null, values);
      db.close();
  }
  </code></pre>
  
  <p><strong>UPDATED CODE:</strong>
  I'm parsing  a json adding those values to db as follows,</p>
  
  <pre><code>JSONObject value = new JSONObject(notificationResponse.getString("value"));
                              JSONObject shipmentMaster = value.getJSONObject("shipment_master");
                              Iterator&lt;String&gt; shipmentMasterIterator = shipmentMaster.keys();
                              String status = null;
                              String key = null;
                              final int numberLenth = shipmentMaster.length();
  
                              while (shipmentMasterIterator.hasNext()) {
                              key = shipmentMasterIterator.next();
                              status = shipmentMaster.optString(key);
  
  
                             db.addShipmentMaster(new ShipmentMasterDao(Integer.valueOf(key), status));
                              }
  </code></pre>
  
  <p>Json that im parsing is as follows,</p>
  
  <pre><code>{
    "status": 1,
    "value": {
      "shipment_master": {
        "1": "Order Placed",
        "2": "In Production",
        "3": "Quality Check In progress",
        "4": "Goods received for shipment",
        "5": "Stuffing in progress",
        "6": "Cargo Shipped"
      }
    }
  }
  </code></pre>
  
  <p>It throws an error message as follows,</p>
  
  <p><code>E/SQLiteLog: (1) no such table: shipmentMaster
  E/SQLiteDatabase: Error inserting status=Cargo Shipped id=0                                                       android.database.sqlite.SQLiteException: no such table: shipmentMaster (code 1): , while compiling: INSERT INTO shipmentMaster(status,id) VALUES (?,?)</code></p>