title: Why SQLAlchemy send null value for id primary column?
body: <p>I'm trying to build an user registration page and facing this:<br>
  For some reason sqlalchemy forms this row for postgresql database - <code>(null, roman, 2021-05-04)</code>, but I've passed in User model that id column is primary key (so NOT NULL) <br>
  I created tables in database via pgAdmin4<br>
  I have no idea why this is happening, because I used the same code but for MySQL and for SQLite and it works</p>
  <p><strong>models.py</strong></p>
  <pre><code>class User(UserMixin, db.Model):
      __tablename__ = 'users'
  
      id = db.Column(db.Integer, primary_key=True)
      username = db.Column(db.String(20), unique=True, nullable=False)
      registration_date = db.Column(db.DateTime, nullable=False)
  
      def __init__(self, username, registration_date):
          self.username = username
          self.registration_date = registration_date
  </code></pre>
  <p><strong>routes.py</strong></p>
  <pre><code>@app.route('/register', methods=['POST', 'GET'])
  def register():
      form = RegistrationForm()
      if form.validate_on_submit():
          user = User(username=form.username.data,
                      registration_date=datetime.now(),
                      )
          db.session.add(user)
          db.session.commit()
          flash('User was created!', 'success')
          return redirect(url_for('login'))
      return render_template('register.html', form=form)
  </code></pre>