protected function search()
{
$this->matches = [];
- $sql = "SELECT user_table.userID
- FROM wcf" . WCF_N . "_user user_table
- LEFT JOIN wcf" . WCF_N . "_user_option_value option_value
- ON option_value.userID = user_table.userID";
// build search condition
$this->conditions = new PreparedStatementConditionBuilder();
return;
}
- // do search
- $statement = WCF::getDB()->prepareStatement($sql . "\n". $this->conditions, $this->maxResults);
+ // perform search
+ $sql = "SELECT user_table.userID
+ FROM wcf" . WCF_N . "_user user_table
+ LEFT JOIN wcf" . WCF_N . "_user_option_value option_value
+ ON option_value.userID = user_table.userID
+ {$this->conditions}";
+ $statement = WCF::getDB()->prepareStatement($sql, $this->maxResults);
$statement->execute($this->conditions->getParameters());
$this->matches = $statement->fetchAll(\PDO::FETCH_COLUMN);
}