Body: <p>We are attempting a CiviCRM Member import for a client on CiviCRM 4.6.12.
  The import starts to run but then fails saying no memberships were created. </p>
  
  <ul>
  <li>Nothing is logged to the CiviCRM log file.</li>
  <li>The .csv file detailing the import errors says for ecah line <em>'DB Constraint Violation - possibly membership_type_id should possibly be marked as mandatory for this API. If so, please raise a bug report'</em></li>
  </ul>
  
  <p>The client says there have been no reported upgrade errors and each member record in the Db has a valid membership type ID.</p>
  
  <p>Has anyone had a similar issue?</p>
  
  <p>Oliver</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-02-15T23:48:58.987Z
Comments.Text: Ollie - want to be clear. Using Import Wizard, or API (assuming the latter but I assume too often)
Comments.UserDisplayName: petednz - fuzion
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-02-16T23:27:31.990Z
Comments.Text: You have already imported the contacts into Civi, yes? The member record in the DB - that's your internal member ID or the CiviMember ID?
Comments.UserDisplayName: Barbara Forbes-Lyons
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-02-17T08:42:43.240Z
Comments.Text: Yes, this is via the import wizard. And when I said member record I meant the internal member ID. Olly
Comments.UserDisplayName: Oliver Gibson
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-02-18T13:49:21.790Z
Comments.Text: Civi will create the CiviMember ID automatically. You can't import into that field. You can, however, import the internal member ID into the External ID field when you import Contact. When you import the memberships, match the Internal Member ID to the External Member ID you imported with the contact.
Comments.UserDisplayName: Barbara Forbes-Lyons
Tags: <civimember><import>
Title: CiviCRM Member Import Tool Issue
ThreadText: # CiviCRM Member Import Tool Issue
  
  (Asked by: username_0 on 2016-02-15)
  
  We are attempting a CiviCRM Member import for a client on CiviCRM 4.6.12.
  The import starts to run but then fails saying no memberships were created.
  
  * Nothing is logged to the CiviCRM log file.
  * The .csv file detailing the import errors says for ecah line *'DB Constraint Violation - possibly membership\_type\_id should possibly be marked as mandatory for this API. If so, please raise a bug report'*
  
  The client says there have been no reported upgrade errors and each member record in the Db has a valid membership type ID.
  
  Has anyone had a similar issue?
  
  Oliver
  
  **Tags:** civimember, import
  
  > **Comments:**
  > **username_1**: Ollie - want to be clear. Using Import Wizard, or API (assuming the latter but I assume too often)  
  > **username_2**: You have already imported the contacts into Civi, yes? The member record in the DB - that's your internal member ID or the CiviMember ID?  
  > **username_0**: Yes, this is via the import wizard. And when I said member record I meant the internal member ID. Olly  
  > **username_2**: Civi will create the CiviMember ID automatically. You can't import into that field. You can, however, import the internal member ID into the External ID field when you import Contact. When you import the memberships, match the Internal Member ID to the External Member ID you imported with the contact.  
  
  ---
  
  ## 0 answers
  
  