title: Inserting Row into Sqlite DB(Android)
body: <p>I have table "logs":</p>
  
  <pre><code>private static final String DATABASE_CREATE = 
              "create table if not exists logs (_id integer primary key autoincrement, "+ "date datetime, city text, " + "type text, log text, nick text);";
  </code></pre>
  
  <p>And method to insert a log:</p>
  
  <pre><code>public long insertLog(String city, int type, String log, String nick) {
  
          SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
          Date date = new Date();
  
          ContentValues initialValues = new ContentValues();
  
          initialValues.put(KEY_DATE, dateFormat.format(date));
          initialValues.put(KEY_CITY, city);
          initialValues.put(KEY_TYPE, type);
          initialValues.put(KEY_LOG, log);
          initialValues.put(KEY_NICK, nick);
  
          return db.insert(DATABASE_TABLE, null, initialValues);
  
      }
  </code></pre>
  
  <p>Every time i try to insert a log, i get no exceptions. Method returns every time "1". But when i looked at my table with sqliteviewer i see it empty. What could be reasons for this issue?</p>