code: function exists(name, db) {
    return db(db.raw('information_schema.tables')).count('table_name').where('table_name', name).then(function (resp) {
      if (resp.length !== 1) {
        throw new Error('invalid response');
      }
      if (typeof resp[0].count !== 'number') {
        throw new Error('invalid response');
      }
      return resp[0].count;
    });
  }
docs: /*
  {
  style: create|replace|append
  }