commit a7a5da7858d0d06a146b5dcd2797e1bada13dba8
Author: Vernon Mauery <vernon@mauery.com>
Date:   Fri Jan 21 10:51:20 2011 -0800

    make 'and' operator work on multiple-term arguments
    
    Currently the query generated by the numeric handler only
    generates a correct SQL statement for 'or' operators when
    working with mulitple-term arguments (e.g. /myview/2+3+4)
    but does not work with the 'and' operator (/myview/2,3,4).
    
    This patch adds a HAVING clause to the 'and' queries that
    requires that all of the terms matched in the 'IN' where
    clause are matched.
    
    Signed-off-by: Vernon Mauery <vernon@mauery.com>

diff --git a/views/handlers/views_handler_argument_numeric.inc b/views/handlers/views_handler_argument_numeric.inc
index 6d5d785..e12474f 100644
--- a/views/handlers/views_handler_argument_numeric.inc
+++ b/views/handlers/views_handler_argument_numeric.inc
@@ -85,6 +85,9 @@ class views_handler_argument_numeric extends views_handler_argument {
       $operator = empty($this->options['not']) ? 'IN' : 'NOT IN';
       $placeholders = implode(', ', array_fill(0, sizeof($this->value), '%d'));
       $this->query->add_where(0, "$this->table_alias.$this->real_field", $this->value, $operator);
+      if ($this->operator == 'and') {
+        $this->query->add_having_expression(0, "COUNT({$this->table_alias}.{$this->real_field}) = :nrvals", array(':nrvals' => count($this->value)));
+      }
     }
     else {
       $operator = empty($this->options['not']) ? '=' : '!=';
