The Crosstab Table views style does not appear to be configured

Created on 26 October 2014, over 9 years ago
Updated 13 December 2023, 7 months ago

I am going insane with this. I have what ought to be a very simple problem. I have a content type called "Children" (which I am using for testing, the real thing is a bit more complicated) which contains just the following fields: Title (of course), District (obligatory, select list), and Gender (Male or Female, logically).
I want to produce a CrossTab report which lists the number of males and females per district.
I enabled the default View of content types per user and it works - except for the error message which I have just entered as a bug though this may be something completely different (it disappears when I run under PHP5.2 instead of 5.3 as usual).
Then I tried to do the same thing with my content type, defining the District as Crosstab Rows and the Gender as Crosstab Columns and the Nid as Crosstab Data, then Count as the operation.
I get these messages:
The Crosstab Table views style does not appear to be configured.
The crosstab could not be displayed, showing a linear table instead.
The table is completely blank
Here is the SQL

SELECT 'node' AS field_data_field_district_node_entity_type, 'node' AS field_data_field_gender_node_entity_type
FROM 
{node} node
WHERE (( (node.status = '1') AND (node.type IN  ('child_test')) ))
LIMIT 20 OFFSET 0

And here is the View

$view = new view();
$view->name = 'children';
$view->description = '';
$view->tag = 'default';
$view->base_table = 'node';
$view->human_name = 'Children';
$view->core = 7;
$view->api_version = '3.0';
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */

/* Display: Master */
$handler = $view->new_display('default', 'Master', 'default');
$handler->display->display_options['title'] = 'Children';
$handler->display->display_options['use_more_always'] = FALSE;
$handler->display->display_options['access']['type'] = 'perm';
$handler->display->display_options['cache']['type'] = 'none';
$handler->display->display_options['query']['type'] = 'views_query';
$handler->display->display_options['exposed_form']['type'] = 'basic';
$handler->display->display_options['pager']['type'] = 'some';
$handler->display->display_options['pager']['options']['items_per_page'] = '20';
$handler->display->display_options['style_plugin'] = 'views_crosstab_table';
$handler->display->display_options['style_options']['columns'] = array(
  'field_district' => 'field_district',
  'field_gender' => 'field_gender',
  'nid' => 'nid',
);
$handler->display->display_options['style_options']['default'] = '-1';
$handler->display->display_options['style_options']['info'] = array(
  'field_district' => array(
    'sortable' => 0,
    'default_sort_order' => 'asc',
    'align' => '',
    'separator' => '',
    'empty_column' => 0,
  ),
  'field_gender' => array(
    'sortable' => 0,
    'default_sort_order' => 'asc',
    'align' => '',
    'separator' => '',
    'empty_column' => 0,
  ),
  'nid' => array(
    'sortable' => 0,
    'default_sort_order' => 'asc',
    'align' => '',
    'separator' => '',
    'empty_column' => 0,
  ),
);
$handler->display->display_options['style_options']['crosstab_rows'] = 'field_district';
$handler->display->display_options['style_options']['crosstab_columns'] = 'field_gender';
$handler->display->display_options['style_options']['crosstab_data'] = 'nid';
/* Field: Content: District */
$handler->display->display_options['fields']['field_district']['id'] = 'field_district';
$handler->display->display_options['fields']['field_district']['table'] = 'field_data_field_district';
$handler->display->display_options['fields']['field_district']['field'] = 'field_district';
/* Field: Content: Gender */
$handler->display->display_options['fields']['field_gender']['id'] = 'field_gender';
$handler->display->display_options['fields']['field_gender']['table'] = 'field_data_field_gender';
$handler->display->display_options['fields']['field_gender']['field'] = 'field_gender';
/* Field: Content: Nid */
$handler->display->display_options['fields']['nid']['id'] = 'nid';
$handler->display->display_options['fields']['nid']['table'] = 'node';
$handler->display->display_options['fields']['nid']['field'] = 'nid';
/* Filter criterion: Content: Published */
$handler->display->display_options['filters']['status']['id'] = 'status';
$handler->display->display_options['filters']['status']['table'] = 'node';
$handler->display->display_options['filters']['status']['field'] = 'status';
$handler->display->display_options['filters']['status']['value'] = 1;
$handler->display->display_options['filters']['status']['group'] = 1;
$handler->display->display_options['filters']['status']['expose']['operator'] = FALSE;
/* Filter criterion: Content: Type */
$handler->display->display_options['filters']['type']['id'] = 'type';
$handler->display->display_options['filters']['type']['table'] = 'node';
$handler->display->display_options['filters']['type']['field'] = 'type';
$handler->display->display_options['filters']['type']['value'] = array(
  'child_test' => 'child_test',
);

/* Display: Page */
$handler = $view->new_display('page', 'Page', 'page');
$handler->display->display_options['path'] = 'children';
πŸ› Bug report
Status

Closed: duplicate

Version

1.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024