CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • General Discussion (please no support requests here!) (Moderator: Michał Mach) »
  • Bulk imprt into Contacts with Tags
Pages: [1]

Author Topic: Bulk imprt into Contacts with Tags  (Read 376 times)

jboris

  • I’m new here
  • *
  • Posts: 1
  • Karma: 0
  • CiviCRM version: 4.6.9
  • CMS version: Drupal 7
  • MySQL version: 5
  • PHP version: 5
Bulk imprt into Contacts with Tags
October 28, 2015, 10:58:12 am
I have searched the instructions and did a Google search for this. I found early posts (2099-2012) asking how to include Tags during import but it did not help. I am using 4.6.9 and want to import contacts and also include Tag data. But when I use the import function the tags don't show up in the mapping drop downs. If you can't imprt them when you import the contacts is there a way to do a mass update based on another field?

totten

  • Administrator
  • Ask me questions
  • *****
  • Posts: 695
  • Karma: 64
Re: Bulk imprt into Contacts with Tags
October 28, 2015, 01:15:12 pm
AFAIK, the standard importer doesn't support it, but the API does allow you to add records of type "EntityTag". Basically, each entity tag is a tuple of:

 * entity_table (i.e. 'civicrm_contact')
 * entity_id (i.e. the contact's ID#)
 * tag_id (i.e. the tag's ID#)

If you're trying to do a spreadsheet-based import, then you could look at the "API-CSV-Import":

https://civicrm.org/blogs/stoob/csv-api-import
https://civicrm.org/extensions/api-csv-import-gui

The API's data-model (entity_table, entity_id, tag_id) probably doesn't match your original inputs, but sometimes folks can figure out a creative way to finagle the spreadsheets. (Ex: It may help to break the import into multiple files/passes or maybe export an intermediate spreadsheet to get the contact ids.)

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • General Discussion (please no support requests here!) (Moderator: Michał Mach) »
  • Bulk imprt into Contacts with Tags

This forum was archived on 2017-11-26.