title: Cannot insert the value "Null" into column 'xyz'
body: <p>I'm having an issue with adding new patients to my SQL database. When I do so, the following error appears, and an SQL Exception is thrown.</p>
  
  <blockquote>
    <p>Cannot insert the value NULL into column 'ID', table 'IntelliMedDB.dbo.PatientRecord'; column does not allow nulls. INSERT fails.</p>
  </blockquote>
  
  <p>The information contained in all of the values that are added as parameters aren't <em>actually</em> null. They all have information inside them.</p>
  
  <p>Now, to protect against SQL Injection attacks, all of my queries use parameterized values.</p>
  
  <p>I had an MS Access DB that handled all of this fine (same queries, I've just switched from using <code>OleDBCommand</code> to <code>SqlCommand</code>. Other than that, nothing's changed).</p>
  
  <p>Here's the "INSERT INTO" statement, followed by a parameterized query, just so you all can see what I've done:</p>
  
  <pre><code>INSERT INTO PatientRecord (patientID, firstName, lastName, patientGender, dateOfBirth, residentialAddress, postalAddress, nationalHealthNumber, telephoneNumber, cellphoneNumber) 
                     VALUES (@patientIDNumber, @recepPatFirstName, @recepPatLastName, @recepPatGender,  @recepPatDateOfBirth, @recepPatResidentialAddress, @recepPatPostalAddress, @recepNHINumber, @recepPatTelephone, @recepPatCellularNumber)";
  </code></pre>
  
  <p>(I apologize for the length of the query).</p>
  
  <p>And now, one of the parameterized values:</p>
  
  <pre><code>recepPatRecordCommand.Parameters.AddWithValue("@recepPatFirstName", patRecepFirstName);
  </code></pre>
  
  <p>Any help gratefully received.</p>
  
  <p>Thank you!</p>