You are here

function services_resource_execute_index_query in Services 7.3

Helper function to execute a index query.

Parameters

$query: Object dbtng query object.

5 calls to services_resource_execute_index_query()
_comment_resource_index in resources/comment_resource.inc
Return an array of optionally paged cids based on a set of criteria.
_file_resource_index in resources/file_resource.inc
Return an array of optionally paged fids based on a set of criteria.
_node_resource_index in resources/node_resource.inc
Return an array of optionally paged nids based on a set of criteria.
_taxonomy_term_resource_index in resources/taxonomy_resource.inc
Return an array of optionally paged tids based on a set of criteria.
_user_resource_index in resources/user_resource.inc
Return an array of optionally paged uids based on a set of criteria.

File

./services.module, line 1094
Provides a generic but powerful API for web services.

Code

function services_resource_execute_index_query($query) {
  try {
    return $query
      ->execute();
  } catch (PDOException $e) {
    return services_error(t('Invalid query provided, double check that the fields and parameters you defined are correct and exist. ' . $e
      ->getMessage()), 406);
  }
}