Skip to main content

You are here

Little Views Tricks #2

It's a common thing -- you want to filter Views results by whether or not it's got a particular field, like an image. Problem is, Views returns a row for every image on the node! Here's how to deal with that: If you're using a field with multiple values, in many cases Views has a version of that field with a 'delta' value. The figure shows two fields that come with Drupal Commerce that can use multiple values. Configure the Operator value 'Is equal to' to '0' -- you're just checking to see if there's an item in the field -- and you should return one row as a result.

Multiple value fields

About the author

Feeds: 

Issue identifier: 

The Design Issue
Share/Save

Comments

Thanks.

Premium Drupal Themes by Adaptivethemes