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) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Importing Contacts with Employee of= Match to Org
Pages: [1]

Author Topic: Importing Contacts with Employee of= Match to Org  (Read 1603 times)

Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Importing Contacts with Employee of= Match to Org
January 26, 2011, 07:08:25 am
On this topic,

http://forum.civicrm.org/index.php/topic,3457.msg16288.html#msg16288

facing this right now in migrating from one custom made CRM database to Civi. I already have all the Orgs Imported.

As I import contacts, it's not check to see if the Org already exists and is not creating the relationship as I thought it would.

So is there an easy way of import 8000 contacts that need to be linked to the 600 or so Org's that are already in the system?

I've already imported some 1000 contacts that didn't have any Org relationship, so those are done and I only have about 7k+ contact records to import.

D

Thanks!

D

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: Importing Contacts with Employee of= Match to Org
January 27, 2011, 01:22:28 am
I'm not sure you are hitting the same issue - mine was because I needed to avoid Duplicate Matching for the Individuals. If that is the same for you then why not use the tedious work around I suggested?
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Re: Importing Contacts with Employee of= Match to Org
January 27, 2011, 05:56:56 am
Not sure I am either.

If I import 5 users that work for Acme Insurance, then 5 Acme Insurance Org records get created.

If the 5 users already exist, and I use update/Fill, the system still is creating 5 Acme Insurance records and each 1 has a relationship corresponding to the user that was imported/updated.

When I did a 7k import back on 2.x system, I don't recall this happening.

And if it's the same thing you ran into, instead of a custom field, I was thinking of just tagging the records Name2Change. I haven't gotten back to this yet as I am working on other items while I wait formy programmer to update to 3.3.3.

Thanks!

D

Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Re: Importing Contacts with Employee of= Match to Org
January 27, 2011, 06:29:10 am
So maybe I did this backwards.

I imported all the Org names first, thinking that on importing the contacts and using the Field "Employee of" Org (Match to contact), that it would than sync to the existing org file.

I'm thinking that I should Export all of My Org's that I have to an Org.csv file, then delete all orgs, complete my import of users with out Org Info. After all contacts are imported, go back to the contact records (the Orgs and contact import files have exact same structure), Do Import of Contact Type =Org and then set the field to Employer Of (Match to Contacts...) etc..

I'm going to test with my 5 Acme insurance contacts and report back.

I'm really hoping that it does not duplicate the employee's, but I have a feeling as I am typing this that it will.

D

Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Re: Importing Contacts with Employee of= Match to Org
January 27, 2011, 12:12:10 pm
Hi Peter,

didn't work as I surmised as I was completing the last post.

So I am back to your work around.

Problem is that I already have about 1K+ contact records imported, which may or may not have associated Org/Emp names.

So how would you recommend that I proceed? I have to import around another 7K+ Contacts.

Thanks!

Dallas





Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Re: Importing Contacts with Employee of= Match to Org
January 27, 2011, 12:44:41 pm
Quote from: peterd on January 27, 2011, 01:22:28 am
I'm not sure you are hitting the same issue - mine was because I needed to avoid Duplicate Matching for the Individuals. If that is the same for you then why not use the tedious work around I suggested?

Quote from: peterd on May 23, 2008, 01:25:40 am
Bit more info - my file had Organisation Name and I had my mapping set to 'Employee of" "organisation name" - the organisations all already existed, hence my expectation that it would simple add the Individual and include the Relationship to the existing organisation.
Seems it doesn't check for an existing organisation as part of No Duplicate CHeck and therefore sets up new organisation.

This occured on Demo too. See import 'NoDupChk test for demo'.

I would consider this an inconvenience if not a bug.

If this is expected behaviour then I suppose there is a way around it by doing the NoDupChk import without 'employee of' set to import.

Then I will have to reimport with an 'update' setting.

Is that the way to go?

Quote from: Dave Greenberg on May 23, 2008, 05:54:33 pm
Import of Individuals w/ "related contact info" for Employer (Organization Name) in 2.0 should "simply add the Individual and include the Relationship to the existing organisation." - as you've noted. If the Organization Name was entered exactly the same as the existing ones, it sounds like this is another bug in the import process. (Organization duplicates are detected based strictly on organization name in 2.0 and prior.)

In 2.1, the duplicate matching on contacts has been reworked substantially - and you will be able to configure the "strict" matching rules for organizations - so hopefully this will all work better. Please file an issue for this so we can verify that things are working properly in 2.1 (or fix there if needed).

Seems like the exact same thing to me that I am trying to do.

Figured this would be fixed as far a long as Civi is now.

petednz

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4899
  • Karma: 193
    • Fuzion
  • CiviCRM version: 3.x - 4.x
  • CMS version: Drupal 6 and 7
Re: Importing Contacts with Employee of= Match to Org
January 28, 2011, 10:49:51 am
want to just carefully spell out your exact situation with regard to the spreadsheet and the columns, ie

col A = First
col B = Last
Col C = organisation - and the field chosen is 'related data' (or whatever the dropdown calls it) 'employee of // organisation name

and therefore Col C contains the names of ORganisations that should be matching to the existing Org in the DB?

just to be sure there isn't anything obvious that is missing
Sign up to StackExchange and get free expert advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

pete davis : www.fuzion.co.nz : connect + campaign + communicate

Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Re: Importing Contacts with Employee of= Match to Org
January 29, 2011, 08:04:52 pm
Column Names

Salutation   First Name   Last Name   ImpID   Title   District No   Company   Address   City   State   Postal Code   Postal Code Suffix   Country   County   Email   Courthouse Phone   Fax Phone   Home Phone   Office Phone   

ImpID is a custom filed in the CSV File and is FirstInitial FN + FirstInitial LN + Row Number in the CSV file. This CSV File is my master list, the ImpID is imported into a Custom Field.

I actually have dumped everything and I started from scratch.

I even cleared out all the Orgs as well.

Even with a clean DB no contacts no orgs, I started importing Contacts with Employee of OrgName.

It created the orgs and relationships, but each contact was duplicated, so in the first import of 600 records, I wound up with 1200 Contact records and about 20  or so Org Records.

I dumped every thing again and I have imported 6907 Contacts and put company name into a custom field called Company for now and not importing Employee of Org Name.

Hosted server is having some issues tonight so I'll pick backup on this in the morning. But at least I have 6907 Contacts that are about 98% reliable.

- Each Import session I did when it was creating Duplicates I set to SKIP, so I went in to the DeDupe rules and for Ind Contacts, I added the ImpID to the list with a weight of 15.

D

Dwiding

  • I post frequently
  • ***
  • Posts: 165
  • Karma: 8
  • CiviCRM version: 3.3.3
  • CMS version: Joomla 1.5.x
Re: Importing Contacts with Employee of= Match to Org
February 01, 2011, 06:17:25 am
I dumped everything, tweaked the Dedupe rules for Org = Org Name weight = 100 and Ind first Name = 25, Last Name = 25, email = 25 and ImpID (Custom field) = 25.

I just ran an import on 19 contacts that were previously imported, that are part of the same org. The import created the new Org and did not dupe any contacts or the org, so I think I'm good to go.

As I had numerous contacts with no Org and No email, had to group the data sets such as "Indvidual No Org No Email.csv", "Individual With Org No Email", "Individual With Org With email" and I created 4 Import Mappings to match whether or not there was an Org "Employee Of" "Match to Org" or No Org, "Email" or "No Email", etc.

I now have over 8000 contacts Individual and Org with no duplicates with out having to import then export and then re-import. Everything imported on a single pass.

I also had to break the import files up into 250 records each file, as the "Import" routine continuously timed out if I had more than 275 or so contacts in the file. Number varied, so I just stuck with 250 in each file to minimize the issue. Once I got going, was done in about 6 hours.

Thanks for your help.

D

« Last Edit: February 02, 2011, 06:14:32 pm by Dwiding »

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Importing Contacts with Employee of= Match to Org

This forum was archived on 2017-11-26.