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 »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • Need organization and individual to share field
Pages: [1]

Author Topic: Need organization and individual to share field  (Read 1159 times)

jakeh666

  • I’m new here
  • *
  • Posts: 12
  • Karma: 1
  • CiviCRM version: 4.0.8
  • CMS version: 2.5.0 Joomla
  • MySQL version: 5.1.41
  • PHP version: 5.3.1?
Need organization and individual to share field
March 01, 2012, 07:17:57 pm
I'm importing a database where organizations and individuals need to share a custom field for query purposes. I don't want people within our organization to have to do complex queries. I want them to pull up one query that searches for that field in both organization and individual. Having organizations and individuals separately also prevent easy addition of a custom field because the custom field has to be added twice.

My solution as of now has been to create a person named "Representative of" and then create a relationship to the organization or even a custom field for the organization name. How can I make individuals and organizations essentially the same?

For my uses, I'd really prefer to import all organizations and individuals together. I run into the problem when I am missing first and last name for the organizations. Could there be a way to add an organization field for individuals, make first and last name not required, and just not have to deal with the organization type of contact?

Thanks
« Last Edit: March 01, 2012, 07:26:04 pm by jakeh666 »

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: Need organization and individual to share field
March 02, 2012, 12:26:53 am
Quote
Could there be a way to add an organization field for individuals, make first and last name not required, and just not have to deal with the organization type of contact?
That can be done with customizations. You would probably create a custom field for Individual, and use a number of hooks (buildForm, validate, pre and postProcess) to make Individuals work the way you want to.
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Need organization and individual to share field
March 02, 2012, 11:10:48 am
Jake - Why not just create a Custom Data Set with "Used For" = Contacts (rather than Individual or Organization). This way the custom field(s) in that set are available and searchable for both Individuals and Organizations.
Protect your investment in CiviCRM by  becoming a Member!

jakeh666

  • I’m new here
  • *
  • Posts: 12
  • Karma: 1
  • CiviCRM version: 4.0.8
  • CMS version: 2.5.0 Joomla
  • MySQL version: 5.1.41
  • PHP version: 5.3.1?
Re: Need organization and individual to share field
March 02, 2012, 03:37:25 pm
Dave:  What an elegantly simple solution to my first issue that I had completely missed! Thanks! But I still have the problem of doing one search of one field for organizations AND individuals who have the same field value. --Which I suspect is what the hooks might be needed to accomplish, Erik?

Any suggestions for how to set it up so that individuals and organizations can be searched easily by nontechnical users who aren't necessarily keen to go to Search Builder and search individual -> custom field -> [value] AND search organization -> custom field -> [value] at once? Do I need some serious customization to make that happen?

Thanks

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: Need organization and individual to share field
March 02, 2012, 08:59:09 pm
You can perform such a search from Adv Search.

You can also save such a search as a Smart Group - then your non-techs just need to look in that group.
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

jakeh666

  • I’m new here
  • *
  • Posts: 12
  • Karma: 1
  • CiviCRM version: 4.0.8
  • CMS version: 2.5.0 Joomla
  • MySQL version: 5.1.41
  • PHP version: 5.3.1?
Re: Need organization and individual to share field
March 03, 2012, 08:32:24 am
Perfect, thanks.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • Need organization and individual to share field

This forum was archived on 2017-11-26.