Dear experts,

I'm using views to create a list of dates to for a whole year. Therefore I configured a filter using the date year range: '-0:+1' to filter the events of current and the next year. This filter has no effect on the results. Absolute ranges as '2011:2012' have also no effect!

Please have a look at the settings (open attached jpg).

This view creates the following query:

Italicized
SELECT node.nid AS nid,
node_data_field_date.field_date_value AS node_data_field_date_field_date_value,
node_data_field_date.field_date_value2 AS node_data_field_date_field_date_value2,
node_data_field_date.field_date_rrule AS node_data_field_date_field_date_rrule,
node.language AS node_language,
node_data_field_date.delta AS node_data_field_date_delta,
node.type AS node_type,
node.vid AS node_vid,
node.title AS node_title
FROM node node
LEFT JOIN content_field_date node_data_field_date ON node.vid = node_data_field_date.vid
WHERE node.type in ('date')
ORDER BY node_data_field_date_field_date_value ASC

Thanks for your help and advices.

CommentFileSizeAuthor
#3 views1.JPG88.38 KBiceman2202
#3 ViewExport.txt6.31 KBiceman2202
views1.JPG88.38 KBiceman2202
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

dawehner’s picture

Assigned: iceman2202 » Unassigned
Priority: Major » Normal

Please export your view. A jpg doesn't really help, especially if you don't have uploaded it :)

dawehner’s picture

Project: Views (for Drupal 7) » Date
Version: 6.x-3.0-alpha1 » 6.x-2.x-dev

As you can read on http://drupal.org/node/571990 if there is a field provided by another module it should be linked against the other module.

As it's on the jpg it's the date module.

iceman2202’s picture

FileSize
6.31 KB
88.38 KB

Sorry, I did not recognize that I forgot the attachment.

Here the export of the view:

$view = new view;
$view->name = 'Jahresterminplan';
$view->description = 'Jahresüberblick der Termine des VSGH Reutlingen-Betzingen';
$view->tag = 'Jahresübersicht';
$view->view_php = '';
$view->base_table = 'node';
$view->is_cacheable = FALSE;
$view->api_version = 2;
$view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
$handler = $view->new_display('default', 'Standards', 'default');
$handler->override_option('fields', array(
  'field_date_value' => array(
    'label' => 'Datum',
    'alter' => array(
      'alter_text' => 0,
      'text' => '',
      'make_link' => 0,
      'path' => '',
      'link_class' => '',
      'alt' => '',
      'prefix' => '',
      'suffix' => '',
      'target' => '',
      'help' => '',
      'trim' => 0,
      'max_length' => '',
      'word_boundary' => 1,
      'ellipsis' => 1,
      'strip_tags' => 0,
      'html' => 0,
    ),
    'empty' => '',
    'hide_empty' => 0,
    'empty_zero' => 0,
    'link_to_node' => 0,
    'label_type' => 'widget',
    'format' => 'default',
    'multiple' => array(
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_to' => '',
      'group' => 0,
    ),
    'repeat' => array(
      'show_repeat_rule' => 'hide',
    ),
    'fromto' => array(
      'fromto' => 'both',
    ),
    'exclude' => 0,
    'id' => 'field_date_value',
    'table' => 'node_data_field_date',
    'field' => 'field_date_value',
    'relationship' => 'none',
  ),
  'title' => array(
    'label' => 'Titel',
    'alter' => array(
      'alter_text' => 0,
      'text' => '',
      'make_link' => 0,
      'path' => '',
      'link_class' => '',
      'alt' => '',
      'prefix' => '',
      'suffix' => '',
      'target' => '',
      'help' => '',
      'trim' => 0,
      'max_length' => '',
      'word_boundary' => 1,
      'ellipsis' => 1,
      'strip_tags' => 0,
      'html' => 0,
    ),
    'empty' => '',
    'hide_empty' => 0,
    'empty_zero' => 0,
    'link_to_node' => 1,
    'exclude' => 0,
    'id' => 'title',
    'table' => 'node',
    'field' => 'title',
    'relationship' => 'none',
  ),
));
$handler->override_option('sorts', array(
  'field_date_value' => array(
    'order' => 'ASC',
    'delta' => '-1',
    'id' => 'field_date_value',
    'table' => 'node_data_field_date',
    'field' => 'field_date_value',
    'relationship' => 'none',
  ),
));
$handler->override_option('arguments', array(
  'date_argument' => array(
    'default_action' => 'ignore',
    'style_plugin' => 'default_summary',
    'style_options' => array(),
    'wildcard' => 'all',
    'wildcard_substitution' => 'Alle',
    'title' => '',
    'breadcrumb' => '',
    'default_argument_type' => 'fixed',
    'default_argument' => '',
    'validate_type' => 'none',
    'validate_fail' => 'not found',
    'date_fields' => array(
      'node_data_field_date.field_date_value' => 'node_data_field_date.field_date_value',
    ),
    'year_range' => '-0:+1',
    'date_method' => 'OR',
    'granularity' => 'day',
    'id' => 'date_argument',
    'table' => 'node',
    'field' => 'date_argument',
    'validate_user_argument_type' => 'uid',
    'validate_user_roles' => array(
      '2' => 0,
      '7' => 0,
      '8' => 0,
      '4' => 0,
      '5' => 0,
      '6' => 0,
      '3' => 0,
    ),
    'relationship' => 'none',
    'default_options_div_prefix' => '',
    'default_argument_user' => 0,
    'default_argument_fixed' => '',
    'default_argument_php' => '',
    'validate_argument_node_type' => array(
      'gallery_assist' => 0,
      'panel' => 0,
      'book' => 0,
      'date' => 0,
      'page' => 0,
      'story' => 0,
    ),
    'validate_argument_node_access' => 0,
    'validate_argument_nid_type' => 'nid',
    'validate_argument_vocabulary' => array(),
    'validate_argument_type' => 'tid',
    'validate_argument_transform' => 0,
    'validate_user_restrict_roles' => 0,
    'validate_argument_signup_status' => 'any',
    'validate_argument_signup_node_access' => 0,
    'validate_argument_php' => '',
  ),
));
$handler->override_option('filters', array(
  'type' => array(
    'operator' => 'in',
    'value' => array(
      'date' => 'date',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'id' => 'type',
    'table' => 'node',
    'field' => 'type',
    'relationship' => 'none',
  ),
  'date_filter' => array(
    'operator' => '=',
    'value' => array(
      'min' => '',
      'max' => '',
      'value' => '',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'date_fields' => array(
      'node_data_field_date.field_date_value' => 'node_data_field_date.field_date_value',
    ),
    'date_method' => 'OR',
    'granularity' => 'year',
    'form_type' => 'date_select',
    'default_date' => '',
    'default_to_date' => '',
    'year_range' => '-0:+1',
    'id' => 'date_filter',
    'table' => 'node',
    'field' => 'date_filter',
  ),
));
$handler->override_option('access', array(
  'type' => 'none',
));
$handler->override_option('cache', array(
  'type' => 'none',
));
$handler->override_option('title', 'Jahresübersicht VSGH');
$handler->override_option('items_per_page', 0);
$handler->override_option('style_plugin', 'table');
$handler->override_option('style_options', array(
  'grouping' => '',
  'override' => 1,
  'sticky' => 0,
  'order' => 'asc',
  'columns' => array(
    'field_date_value' => 'field_date_value',
    'title' => 'title',
  ),
  'info' => array(
    'field_date_value' => array(
      'separator' => '',
    ),
    'title' => array(
      'sortable' => 0,
      'separator' => '',
    ),
  ),
  'default' => '-1',
));
$handler = $view->new_display('page', 'Seite', 'page_1');
$handler->override_option('path', 'Jahresterminplan');
$handler->override_option('menu', array(
  'type' => 'normal',
  'title' => 'Jahresübersicht',
  'description' => 'alle Termine des VSGH des aktuellen Jahres',
  'weight' => '0',
  'name' => 'primary-links',
));
$handler->override_option('tab_options', array(
  'type' => 'none',
  'title' => '',
  'description' => '',
  'weight' => 0,
));

Thanks.

iceman2202’s picture

Is there anybody there who can give me a hint how to solve this problem. Otherwise I must delete a lot of events.
It would be very nice to get this view work as intended.

Thanks.

DamienMcKenna’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

We're sorry but the D6 release of Date module is no longer being supported. You are encouraged to update to Drupal 7 or 8, or direct questions to Drupal Answers.