SELECT COUNT(*) FROM accounts WHER registration_date IS NULL AND
registration_date IS NOT NULL => 16 000 rows !
Signed-off-by: Raphaël Barrois <raphael.barrois@polytechnique.org>
$date = 'a.uid IS NOT NULL AND a.state != \'pending\'';
}
if (!is_null($this->comparison)) {
- $date .= ' AND a.registration_date ' . $this->comparison . ' ' . XDB::format('{?}', $this->date->format('Y-m-d'));
+ $date .= ' AND a.registration_date != \'0000-00-00 00:00:00\' AND a.registration_date ' . $this->comparison . ' ' . XDB::format('{?}', $this->date->format('Y-m-d'));
}
return $date;
}