title: MYSQL: automatically extract the YEAR from the date input into another column
body: <p>I have a table with a dateOfBirth column and a yearOfBirth column. The input only contains the DOB information. What I am looking for is to just insert DOB info into the db, and the mysql will auto update the year column field with the year extracted from the date inserted. Is it possible to be done?</p>
  
  <p>Right now my MySQL query is just</p>
  
  <pre><code>INSERT INTO table
      (name, dateOfBirth, yearOfBirth) 
      VALUES (?)
  </code></pre>
  
  <p>How should I change that?</p>