function views_plugin_query_default::get_aggregation_info

Overrides views_plugin_query::get_aggregation_info

1 call to views_plugin_query_default::get_aggregation_info()
views_plugin_query_default::compile_fields in plugins/views_plugin_query_default.inc
Build fields array.

File

plugins/views_plugin_query_default.inc, line 1564

Class

views_plugin_query_default
Object used to create a SELECT query.

Code

public function get_aggregation_info() {
    // @todo Need a way to get database specific and customized aggregation
    // functions into here.
    return array(
        'group' => array(
            'title' => t('Group results together'),
            'is aggregate' => FALSE,
        ),
        'count' => array(
            'title' => t('Count'),
            'method' => 'views_query_default_aggregation_method_simple',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'field' => 'views_handler_field_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
        'count_distinct' => array(
            'title' => t('Count DISTINCT'),
            'method' => 'views_query_default_aggregation_method_distinct',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'field' => 'views_handler_field_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
        'sum' => array(
            'title' => t('Sum'),
            'method' => 'views_query_default_aggregation_method_simple',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
        'avg' => array(
            'title' => t('Average'),
            'method' => 'views_query_default_aggregation_method_simple',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
        'min' => array(
            'title' => t('Minimum'),
            'method' => 'views_query_default_aggregation_method_simple',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
        'max' => array(
            'title' => t('Maximum'),
            'method' => 'views_query_default_aggregation_method_simple',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
        'stddev_pop' => array(
            'title' => t('Standard deviation'),
            'method' => 'views_query_default_aggregation_method_simple',
            'handler' => array(
                'argument' => 'views_handler_argument_group_by_numeric',
                'filter' => 'views_handler_filter_group_by_numeric',
                'sort' => 'views_handler_sort_group_by_numeric',
            ),
        ),
    ) + views_fetch_plugin_data('query_aggregate');
}