LMongo\Query\Builder::distinct PHP Method

distinct() public method

Execute the query to only return distinct results.
public distinct ( string $column, array $query = [] ) : array
$column string
$query array
return array
    public function distinct($column, $query = array())
    {
        if (0 == count($query)) {
            $query = $this->compileWheres($this);
        }
        $results = $this->connection->{$this->collection}->distinct($column, $query);
        return $results;
    }
Builder