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) »
  • Problem with Search Builder
Pages: [1]

Author Topic: Problem with Search Builder  (Read 553 times)

rshun

  • I post occasionally
  • **
  • Posts: 44
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 7.21
  • MySQL version: 5.5
  • PHP version: 5.4
Problem with Search Builder
February 21, 2013, 02:27:20 pm
Hi,
  I try to use Search Builder to build smart group.
  Unfortunately, I have some problem with Search Builder.  How can I search a custom field in profile?

For example:
Custom Data Fields:
Rating
Multiple choice values
1, 2, 3, 4 and 5
I added that custom data field to “Extra Info” Profile for MemberContact
I use Search Builder
Include contacts where
MemberContact
MemberContact:Rating
= 1

I cannot get correct result every time.  Sometime Civicrm gives me result with Rating = 2 or Rating 4.
What’s wrong with my setting?
Thanks,
R


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: Problem with Search Builder
February 21, 2013, 08:01:32 pm
Can yu attach a screenshot of your search
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

rshun

  • I post occasionally
  • **
  • Posts: 44
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 7.21
  • MySQL version: 5.5
  • PHP version: 5.4
Re: Problem with Search Builder
February 22, 2013, 11:03:04 am
For example:
Custom Data Fields:
Rating
Multiple choice values
1, 2 and 3 (see ss1.jpg and ss2.jpg)
I added that Rating field to  Membership profile (see ss3.jpg and ss4.jpg)

I have set a contact with Rating 1 and 3

I use Search Builder (see ss5.jpg)
I try to search by 1, tc, 3 and en (no result)
I also search by IS NOT NULL (it displays that contact)

Please help me.  Thank you!

R

rshun

  • I post occasionally
  • **
  • Posts: 44
  • Karma: 0
  • CiviCRM version: 4.2.1
  • CMS version: Drupal 7.21
  • MySQL version: 5.5
  • PHP version: 5.4
Re: Problem with Search Builder
February 22, 2013, 11:03:52 am
Forget to post ss5.jpg

R

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: Problem with Search Builder
February 26, 2013, 10:24:17 am
rshun - Can you store multiple values in that custom field?  If so, I think you may need to use "LIKE" rather than "=".  That's a semi-bug, but you should be able to get it to work.  Let us know if it works!

Tech reason: when you can store multiple values, it puts a separator character into the database, which means you can't match on "=".
Sign up to StackExchange and get free expert CiviCRM advice: https://civicrm.org/blogs/colemanw/get-exclusive-access-free-expert-help

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Problem with Search Builder

This forum was archived on 2017-11-26.