Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The join definition below from ga_stats_views_data() does not support table aliases. Example: the below join would generate ga_stats_count_pageviews_today
in the views definition, but the actual aliased table name used by views could be node_taxonomy_index_ga_stats_count_pageviews_today
.
$data['ga_stats_count_'.$mkl.'_'.$tk]['table']['join'] = array(
'node' => array(
'table' => 'ga_stats_count',
'left_field' => 'nid',
'field' => 'nid',
'type' => 'LEFT OUTER',
'extra' => 'ga_stats_count_'.$mkl.'_'.$tk.'.metric=\''.$mk.'\' AND ga_stats_count_'.$mkl.'_'.$tk.'.timeframe=\''.$tk.'\''
)
);
Comment | File | Size | Author |
---|---|---|---|
#1 | ga_stats-fix-views-extra-join-2158753-1.patch | 786 bytes | recrit |
Comments
Comment #1
recrit CreditAttribution: recrit commentedthe patch attached fixes the views extra join to use the current alias of the table. @see
class views_join