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) »
  • Non-Recoverable Error Using Special Group- During Find Contacts
Pages: [1]

Author Topic: Non-Recoverable Error Using Special Group- During Find Contacts  (Read 1129 times)

dgreenbergz

  • Guest
Non-Recoverable Error Using Special Group- During Find Contacts
December 30, 2008, 12:38:03 pm
we get this error using advanced search and choosing a canned civicrm group, "Paid Members- Special Permissions". Any advice?  Otherwise 2.0 is working just great and we like it  after a few years of use.

doug/friendsofthebbt.org


Sorry. A non-recoverable error has occurred.

Database Error Code: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') = 'all' AND civicrm_contribution.is_test = '0' AND civicrm_membership.members' at line 2, 1064

Return to home page.

Error Details:


Array
(
    [callback] => Array
        (
           
  • => CRM_Core_Error
  • [1] => handle
            )

       
Code: [Select]
=> -2
    [message] => DB Error: syntax error
    [mode] => 16
    [debug_info] => SELECT DISTINCT UPPER(LEFT(contact_a.sort_name, 1)) as sort_name  FROM civicrm_contact contact_a  LEFT JOIN civicrm_group_contact `civicrm_group_contact-17,10` ON contact_a.id = `civicrm_group_contact-17,10`.contact_id   WHERE  ( ( ( `civicrm_group_contact-17,10`.group_id IN (17,10) AND `civicrm_group_contact-17,10`.status IN ("Added") ) OR ( 
                            ( contact_a.id IN ( SELECT DISTINCT(contact_a.id) as id  FROM civicrm_contact contact_a LEFT JOIN civicrm_contribution ON civicrm_contribution.contact_id = contact_a.id  INNER JOIN civicrm_membership ON civicrm_membership.contact_id = contact_a.id  WHERE  ( LOWER(  ) = 'all' AND  civicrm_contribution.is_test = '0' AND civicrm_membership.membership_type_id IN (5,7,4,1,10,6,8,9) AND  civicrm_membership.is_test = 0 )  AND  ( 1 )  AND 1    ) 
                              AND contact_a.id NOT IN (
                              SELECT contact_id FROM civicrm_group_contact
                              WHERE civicrm_group_contact.group_id = 10 AND civicrm_group_contact.status = 'Removed' ) ) ) ) )  AND  ( 1 )     [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') = 'all' AND  civicrm_contribution.is_test = '0' AND civicrm_membership.members' at line 2]
    [type] => DB_Error
    [user_info] => SELECT DISTINCT UPPER(LEFT(contact_a.sort_name, 1)) as sort_name  FROM civicrm_contact contact_a  LEFT JOIN civicrm_group_contact `civicrm_group_contact-17,10` ON contact_a.id = `civicrm_group_contact-17,10`.contact_id   WHERE  ( ( ( `civicrm_group_contact-17,10`.group_id IN (17,10) AND `civicrm_group_contact-17,10`.status IN ("Added") ) OR ( 
                            ( contact_a.id IN ( SELECT DISTINCT(contact_a.id) as id  FROM civicrm_contact contact_a LEFT JOIN civicrm_contribution ON civicrm_contribution.contact_id = contact_a.id  INNER JOIN civicrm_membership ON civicrm_membership.contact_id = contact_a.id  WHERE  ( LOWER(  ) = 'all' AND  civicrm_contribution.is_test = '0' AND civicrm_membership.membership_type_id IN (5,7,4,1,10,6,8,9) AND  civicrm_membership.is_test = 0 )  AND  ( 1 )  AND 1    ) 
                              AND contact_a.id NOT IN (
                              SELECT contact_id FROM civicrm_group_contact
                              WHERE civicrm_group_contact.group_id = 10 AND civicrm_group_contact.status = 'Removed' ) ) ) ) )  AND  ( 1 )     [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') = 'all' AND  civicrm_contribution.is_test = '0' AND civicrm_membership.members' at line 2]
    [to_string] => [db_error: message="DB Error: syntax error" code=-2 mode=callback callback=CRM_Core_Error::handle prefix="" info="SELECT DISTINCT UPPER(LEFT(contact_a.sort_name, 1)) as sort_name  FROM civicrm_contact contact_a  LEFT JOIN civicrm_group_contact `civicrm_group_contact-17,10` ON contact_a.id = `civicrm_group_contact-17,10`.contact_id   WHERE  ( ( ( `civicrm_group_contact-17,10`.group_id IN (17,10) AND `civicrm_group_contact-17,10`.status IN ("Added") ) OR ( 
                            ( contact_a.id IN ( SELECT DISTINCT(contact_a.id) as id  FROM civicrm_contact contact_a LEFT JOIN civicrm_contribution ON civicrm_contribution.contact_id = contact_a.id  INNER JOIN civicrm_membership ON civicrm_membership.contact_id = contact_a.id  WHERE  ( LOWER(  ) = 'all' AND  civicrm_contribution.is_test = '0' AND civicrm_membership.membership_type_id IN (5,7,4,1,10,6,8,9) AND  civicrm_membership.is_test = 0 )  AND  ( 1 )  AND 1    ) 
                              AND contact_a.id NOT IN (
                              SELECT contact_id FROM civicrm_group_contact
                              WHERE civicrm_group_contact.group_id = 10 AND civicrm_group_contact.status = 'Removed' ) ) ) ) )  AND  ( 1 )     [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') = 'all' AND  civicrm_contribution.is_test = '0' AND civicrm_membership.members' at line 2]"]
)



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: Non-Recoverable Error Using Special Group- During Find Contacts
December 30, 2008, 12:47:58 pm

Can you try to reproduce it on our demo server running 2.1. if you can please file an issue (which we will then fix for 2.1 or 2.2). You can then potentially backport that fix

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

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Core CiviCRM Functions (Moderator: Yashodha Chaku) »
  • Non-Recoverable Error Using Special Group- During Find Contacts

This forum was archived on 2017-11-26.