title: Knex, inserting random columns
body: <p>What I am trying to do is use knex's trx in order to post data to my database. When I try to send a post request and process it with the following code I get this error:</p>
  <blockquote>
  <p>Failing row contains (4, null, , null, 2021-05-13 23:12:17.642)</p>
  </blockquote>
  <p>I don't have much experience with knex so I have no clue why there are two null values in with the three values that are supposed to be there. I feel like this is simple but I can't find anything on it online.</p>
  <pre><code>const handleAnnouncementCreation = (req, res, db) =&gt; {
      const { body } = req.body;
      db.transaction(trx =&gt; { 
          trx.insert({
              body: body,
              posted: new Date()
          }).into('news_posts').returning('id').then(id =&gt; {
              res.json(id);
          }).then(trx.commit).catch(trx.rollback);
      }).catch(err =&gt; res.status(400).json(err));
  }
  </code></pre>