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) »
  • Search not returning expected results
Pages: [1]

Author Topic: Search not returning expected results  (Read 713 times)

MrsBakesALot

  • I’m new here
  • *
  • Posts: 7
  • Karma: 1
  • CiviCRM version: 4.1.2
  • CMS version: Drupal
Search not returning expected results
June 08, 2012, 01:34:37 am
Hi There,

I have set up and configured a new civi for a nfp and they have quite an extensive relationship requirements list.  One of the relationships is between a contact subtype (mentor) and the same subtype (mentor) and the relationship is called "Mentor Partners" for both the A>B and B>A relationship.

However, when using the advanced search to find everyone that has this Mentor Partner relationship, it is only returning one half of the pair.  Any idea why or how to change this so I see the pair in the search results? Do I need to edit how I have set this up?

Many thanks in advance to anyone that has any answers

Olivia
« Last Edit: June 08, 2012, 01:53:11 am by MrsBakesALot »
Working with small NFPs in London & S/E to get started with Civi.

3 installs so far, hosted with 2020Media

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Search not returning expected results
June 08, 2012, 03:05:36 am
Hi,

It sounds like it's returning only the a->b (or only the b->a) you might want to rename the name of one of the direction to see more clearly what's going on.

even so the name might be the same (I thought it was enforced to be different), the search is based on the id, so a->b is different than b->a, even so the "arrows" might be named the same

If this is the case, the easiest might be to implement a custom search, that would allow to force to search on both directions.

Change the name of one of the relationships, will be easier to see what's the pb
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

phunter

  • I’m new here
  • *
  • Posts: 29
  • Karma: 0
  • CiviCRM version: Latest
  • CMS version: Drupal 7
Re: Search not returning expected results
July 28, 2012, 07:12:24 am
I would agree that the standard search results are incomplete

If a user wishes to search for the Spouse of a particular contact they will only be able to find the related Spouse if the relationship was originally added to the contact being searched for. Since these types of relationships can be entered in any order there is no consistency in finding
related contacts, making this search close to useless for this type of relationship. The search only looks for A to B relationships.

Therefore I am not sure I agree that a custom search is required here and in fact this is a bug with the system. Where the database includes thousands of records a typical user will assume the search result will return everything needed, which it doesn't. This either needs to be made clear in some way since this is a Contact Relationship Management tool or the functionality removed for single label relationships.


Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Search not returning expected results
July 28, 2012, 10:04:49 am

This was fixed in a recent release. However this is a bug which did not the right thing if there was "no name" entered.

I fixed this for 4.2beta4

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

phunter

  • I’m new here
  • *
  • Posts: 29
  • Karma: 0
  • CiviCRM version: Latest
  • CMS version: Drupal 7
Re: Search not returning expected results
July 28, 2012, 12:45:50 pm
Thanks Lobo for the feedback on this.

Just to clarify, are you saying there is still an issue in 4.2 if you just run a search for all contacts with a relationship of type spouse (or any relationship with the same label for a_b & b_a for that matter)

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Search not returning expected results
July 28, 2012, 04:16:59 pm

yes for beta3 and before.

i've fixed this for beta4. Would be good if you can test this on our sandbox server: http://sandbox.civicrm.org/

thanx

lobo


A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

phunter

  • I’m new here
  • *
  • Posts: 29
  • Karma: 0
  • CiviCRM version: Latest
  • CMS version: Drupal 7
Re: Search not returning expected results
July 29, 2012, 08:32:05 am
Hi Lobo

I am having problems accessing the Drupal menus on the sandbox but have check the Wordpress version and the results are returned as I would expect - it finds both sides of the Spouse of relationship

I will check out all version, once I am able, and undertake a more complete test on this issue.

Thanks very much for sorting this out :)

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Post-installation Setup and Configuration (Moderator: Dave Greenberg) »
  • Search not returning expected results

This forum was archived on 2017-11-26.