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

API throws "undefined_fields" ["contact_id.gender_id"]

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.7
    • Fix Version/s: None
    • Component/s: CiviCRM API
    • Labels:
    • Documentation Required?:
      None
    • Funding Source:
      Needs Funding

      Description

      I was very happy when I learned that CiviCRM 4.7 would support api joins.
      (https://issues.civicrm.org/jira/browse/CRM-17795 which has been implemented)
      For our purpose I wanted to retrieve the number of male & female participants of an event.

      Unfortunately there seems to be a glitch with the gender field:

      When I try (through the api explorer locally and on the 4.7 sandbox):
      $result = civicrm_api3('Participant', 'get', array(
      'debug' => 1,
      'event_id' => 3,
      'contact_id.gender_id' => "Male",
      'options' => array('limit' => 9999),
      ));

      I get the debug message:
      "undefined_fields":["contact_id.gender_id"]
      and it disregards the gender filter

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              magnolia61 Richard
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: