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 Import (Moderator: Yashodha Chaku) »
  • Suggestion: change quicksearch to go by "display name" instead of "sort name"
Pages: [1] 2

Author Topic: Suggestion: change quicksearch to go by "display name" instead of "sort name"  (Read 1908 times)

vdtoan

  • I’m new here
  • *
  • Posts: 3
  • Karma: 0
  • CiviCRM version: 4.5.4
  • CMS version: joomla
  • MySQL version: 5.5
  • PHP version: 5.5
Suggestion: change quicksearch to go by "display name" instead of "sort name"
December 14, 2014, 05:47:51 pm
Hi guys,

I am new to forum, so please correct me if i post the topic at the wrong place,

I am using civicrm version 4.5.4, when i import the contact via the importer, i can't find the contact by entering the name or email into the search field. However, if i leave the search field blank, hit the search button, and i would see the imported contacts in the result list.

Please advise,

Really appreciate your help.
« Last Edit: January 13, 2015, 08:43:41 am by Coleman Watts »

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Cannot find the contact after importing
December 14, 2014, 06:45:44 pm
This forum is a more appropriate place for this question than the issue tracker. I've closed your issue there, and you can continue discussing it here if you wish. My answer there was:

The search bar goes off "sort name" not "display name" so you'd need to enter "Smith, Bob" not "Bob Smith" as your search term.
Try asking your question on the new CiviCRM help site.

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Cannot find the contact after importing
January 13, 2015, 06:46:13 am
This important little snippet of information doesn't seem to be in the documentation (http://book.civicrm.org/user/current/the-user-interface/searching/) although I may have missed it. It's something I get asked about frequently, so it would be good if this was in the book. Would you like to add it in or shall I?

Best wishes
Graham
Graham Mitchell
http://mc3.coop

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Cannot find the contact after importing
January 13, 2015, 08:36:25 am
I've actually been meaning to start a discussion about this for some time. I'm not sure what the historical reasons are for searching on sort name rather than display name but IMO it should be the other way around. So when I wrote the webform-civicrm module that's exactly what I did (the "existing contact" widget always searches on and displays "display name" while using "sort name" only for ordering the results). So far no one has complained about that. Would anyone complain if we made it work that way in core too?
Try asking your question on the new CiviCRM help site.

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Cannot find the contact after importing
January 13, 2015, 08:40:05 am
I would certainly support that change, on the basis that I believe it is a more "natural" approach, i.e. more in line with what the majority of users would expect to happen.
Graham Mitchell
http://mc3.coop

Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 08:50:49 am
Here are the pros of each I can think of. Hopefully others will weigh in:

Status quo: search by, order by, and display "sort_name"
- Keeping as-is would require no code or documentation changes
- Displaying by "sort name" in the list makes the alphabetization more obvious

Suggested change: search by and display "display_name", sort by "sort_name"
- It's more intuitive to type "Bob Smith" - as a new user it took me quite a while to figure out I had to type "Smith, Bob" (including the comma) to get an exact match
- Display name is more robust - by default it includes prefix and suffix while sort name does not. Helps with disambiguation.
- Display name is intended for display and therefore better suited for being the "display value" of a contact-reference field (displaying sort name looks weird to my eye)
Try asking your question on the new CiviCRM help site.

JonGold

  • Ask me questions
  • ****
  • Posts: 638
  • Karma: 81
    • Palante Technology
  • CiviCRM version: 4.1 to the latest
  • CMS version: Drupal 6-7, Wordpress 4.0+
  • PHP version: PHP 5.3-5.5
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 08:58:56 am
+1 for Display Name.  This is also in line with how Raiser's Edge, Salsa, and Kintera handle searches.
Sign up to StackExchange and get free expert CiviCRM advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

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: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 09:01:47 am

1. we'll need to add an index to display name

2. any reason why we cannot search on both?

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

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 09:40:00 am
+ 1 for Display Name (OR BOTH - if not a performance drag). BUT we should be consistent with this across 'Find Contacts', 'Advanced Search' etc.
Protect your investment in CiviCRM by  becoming a Member!

Eileen

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4195
  • Karma: 218
    • Fuzion
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 10:44:12 am
Agree with display name. Would be nervous about performance on both given how slow that search can be but I imagine it would be an option in the existing search preference setting
Make today the day you step up to support CiviCRM and all the amazing organisations that are using it to improve our world - http://civicrm.org/contribute

joanne

  • Administrator
  • Ask me questions
  • *****
  • Posts: 852
  • Karma: 83
  • CiviCRM version: 4.4.16
  • CMS version: Drupal 7
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 02:54:48 pm
Well, I'm going to be the (very strongly) dissenting voice on this. I think we should be adequately documenting quick search by sort name rather than changing to it to search by display name.  Could we have a help icon to left of the search box? It can certainly be added to the book and extra text could be added to the Search settings screen and the Display preferences screen. I am happy to do all but the help icon ( if it is possible) as I wouldn't know where to start with that.

All this has been prompted by one post. Something else was going on there anyway as the original poster said:
Quote from: vdtoan on December 14, 2014, 05:47:51 pm
i can't find the contact by entering the name or email into the search field.

Now the bolding was my doing, but this shows that the name field used for the search was not the issue. (We don't even know whether he was entering "Smith, Bob" or "Bob Smith".)

I have read every post on the forum in the last eighteen months and problems with using sort name for the search bar is not one that I remember coming up frequently, so is it really a problem?

What I get from Coleman's post about the webform-civicrm module is that people are adaptable; provided they know what form to use they can adjust, and searching different ways in different places is not a problem for them.

Also, whether or not people need to adjust will depend on what they have used previously.  I came from using IMIS and it used last name, first name for searches, so I had no problems.

 
So far all I have done is say why I don't think we need to change, I have to go to a meeting now but will I continue this later with reasons why the sort name  is better than display name. I am posting an incomplete response now because I want to get in before the decision gets made.




« Last Edit: January 14, 2015, 03:32:21 am by joanne »

joanne

  • Administrator
  • Ask me questions
  • *****
  • Posts: 852
  • Karma: 83
  • CiviCRM version: 4.4.16
  • CMS version: Drupal 7
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 13, 2015, 09:06:21 pm
Why do I think we could keep using sort name?

As Eileen noted the quicksearch can actually be quite slow. 

I think changing to display name will severely reduce the effectiveness of the autocomplete list and hence slow down searches even more. (We have found that it is quicker to type in more letters and select from the auto-complete list rather than fewer letters, hit enter and then be taken to a page of search results.)  This will definitely be true for those if us who have disabled automatic wildcard on the search settings page, as suggested to improve search performance. For others I am not so sure.

We don't get consistency in how names are presented to us.    The person with display name Mrs Margaret Smith may communicate with us a Mrs Margaret Smith, or Margaret Smith, or Maggie Smith or Meg Smith or Peggy Smith or ?  At the moment I can start typing in smith, m... and I rapidly get to a point where I can select her from the autocomplete list. (We display sort name, email address and postcode in the autocomplet list)  It is also quick to change from smith, p to smith, m if I can see she is not on the autocomplete list.

If I was searching by display name the auto-complete list would be of no use to me.  If I type in anything other than Mrs Margaret Smith she won't appear in the autocomplete list.  I would have to type in m smith, hit enter and search for her in the page(s) of results.  If she contacted us as Peggy Smith and I searched for p smith, hit enter and found she wasn't in the results, I would then have to do another search with m smith.

Do the "display value" of a contact-reference field and the form of the name used for searching have to be the same?



Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 14, 2015, 11:04:34 am
I think Joanne has made some excellent points, and we should not jump too quickly into changing how this works. IF we can support both Sort and Display Names w/o a performance hit then that seems like a win-win. If not, let's open the discussion to a wider audience on the blog.
Protect your investment in CiviCRM by  becoming a Member!

joanne

  • Administrator
  • Ask me questions
  • *****
  • Posts: 852
  • Karma: 83
  • CiviCRM version: 4.4.16
  • CMS version: Drupal 7
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 14, 2015, 04:11:16 pm
Rather than searching on both display name and sort name, is making it a configurable setting an option?

Or would having to look up that setting every time a search was run negate the possible performance savings of not searching on both?



Coleman Watts

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 2346
  • Karma: 183
  • CiviCRM version: The Bleeding Edge
  • CMS version: Various
Re: Suggestion: change quicksearch to go by "display name" instead of "sort name"
January 15, 2015, 01:39:37 pm
Agree, thanks for the input Joanne. We chatted a bit on IRC and I think I'm more clear about your concerns now and how to ensure this change does not negatively impact you.
I think a configurable setting could meet all the requirements :)
Setting lookup is very fast compared to finding contacts in the db. There are bottlenecks, but I don't think that is one of them.
Try asking your question on the new CiviCRM help site.

Pages: [1] 2
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Import (Moderator: Yashodha Chaku) »
  • Suggestion: change quicksearch to go by "display name" instead of "sort name"

This forum was archived on 2017-11-26.