I have view that shows articles. It works fine if user selects one image but if she selects multiple images to article, it will duplicate the article on my view X amount time (x = number of images that article has). I have tried using distinct but that doesn't do any difference. Why would this image amount effect on this?

I'm using Drupal 6, with Views Version 3.

Here is the query if it helps:

 SELECT DISTINCT(node.nid) AS nid_1, users.uid AS users_uid,
 node_data_field_article_image.field_article_image_fid AS
 node_data_field_article_image.field_article_image_list AS
 node_data_field_article_image.field_article_image_data AS
 node_data_field_article_image.delta AS node_data_field_article_image_delta,
 node.type AS node_type, node.nid AS nid, node.vid AS node_vid,
 node_data_field_article_color.field_article_color_value AS
 node_data_field_article_numbers.field_article_numbers_value AS
 node_data_field_article_numbers_field_article_numbers_value, node.created AS
 node_created, users.name AS users_name, node.title AS node_title,
 node_revisions.body AS node_revisions_body, node_revisions.format AS
 node_revisions_format, feeds_node_item.url AS feeds_node_item_url FROM node node 
 INNER JOIN users users ON node.uid = users.uid LEFT JOIN
 content_field_article_image node_data_field_article_image ON node.vid =
 node_data_field_article_image.vid LEFT JOIN content_type_blog
 node_data_field_article_color ON node.vid = node_data_field_article_color.vid LEFT
 JOIN content_field_article_numbers node_data_field_article_numbers ON
 node.vid =
 node_data_field_blog_font.vid LEFT JOIN node_revisions node_revisions ON
 node.vid = node_revisions.vid LEFT JOIN feeds_node_item feeds_node_item ON
 node.nid = feeds_node_item.nid WHERE (node.type in ('blog', 'feed_item')) AND
 (node.status = 1) ORDER BY node_created DESC
  • Which version of views are you using? Is it (still) Views 2, or is it Views 3 ? – Pierre.Vriens Jun 22 '15 at 10:08
  • Views version 3 – user995317 Jun 22 '15 at 10:15

The version you have should provide an option for the image field Group multiple values and also underneath this you can choose just to show 1 image. Either or a combination should stop these duplicates happening

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.