Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-4135

CiviCASE db error in search builder

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 2.2.0
    • Fix Version/s: 3.0
    • Component/s: CiviCase
    • Labels:
      None

      Description

      In search builder I selected
      record type = case activity
      activity field = activity subject
      operator = IS NOT NULL

      and I got the db error below;

      Code:

      Search Builder

      unrecoverable error
      Sorry. A non-recoverable error has occurred.

      DB Error: no such field

      Database Error Code: Unknown column 'civicrm_case.id' in 'on clause', 1054

      Return to home page.

      Error Details:

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

      [code] => -19
      [message] => DB Error: no such field
      [mode] => 16
      [debug_info] => SELECT DISTINCT(contact_a.id) as contact_id, contact_a.contact_type as `contact_type`, contact_a.contact_sub_type as `contact_sub_type`, contact_a.sort_name as `sort_name`, case_activity.subject as case_subject FROM civicrm_contact contact_a INNER JOIN civicrm_case_activity ON civicrm_case_activity.case_id = civicrm_case.id INNER JOIN civicrm_activity case_activity ON ( civicrm_case_activity.activity_id = case_activity.id
      AND case_activity.is_current_revision = 1 ) WHERE ( 1 ) ORDER BY contact_a.sort_name asc LIMIT 0, 50 [nativecode=1054 ** Unknown column 'civicrm_case.id' in 'on clause']
      [type] => DB_Error
      [user_info] => SELECT DISTINCT(contact_a.id) as contact_id, contact_a.contact_type as `contact_type`, contact_a.contact_sub_type as `contact_sub_type`, contact_a.sort_name as `sort_name`, case_activity.subject as case_subject FROM civicrm_contact contact_a INNER JOIN civicrm_case_activity ON civicrm_case_activity.case_id = civicrm_case.id INNER JOIN civicrm_activity case_activity ON ( civicrm_case_activity.activity_id = case_activity.id
      AND case_activity.is_current_revision = 1 ) WHERE ( 1 ) ORDER BY contact_a.sort_name asc LIMIT 0, 50 [nativecode=1054 ** Unknown column 'civicrm_case.id' in 'on clause']
      [to_string] => [db_error: message="DB Error: no such field" code=-19 mode=callback callback=CRM_Core_Error::handle prefix="" info="SELECT DISTINCT(contact_a.id) as contact_id, contact_a.contact_type as `contact_type`, contact_a.contact_sub_type as `contact_sub_type`, contact_a.sort_name as `sort_name`, case_activity.subject as case_subject FROM civicrm_contact contact_a INNER JOIN civicrm_case_activity ON civicrm_case_activity.case_id = civicrm_case.id INNER JOIN civicrm_activity case_activity ON ( civicrm_case_activity.activity_id = case_activity.id
      AND case_activity.is_current_revision = 1 ) WHERE ( 1 ) ORDER BY contact_a.sort_name asc LIMIT 0, 50 [nativecode=1054 ** Unknown column 'civicrm_case.id' in 'on clause']"]
      )

      [/code]

        Attachments

          Activity

            People

            • Assignee:
              sunil Sunil Pawar
              Reporter:
              creea1 Alistair Cree
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 2 hours
                2h
                Remaining:
                Remaining Estimate - 2 hours
                2h
                Logged:
                Time Spent - Not Specified
                Not Specified