PHP Класс Phalcon\Db\Adapter\MongoDB\Operation\Distinct

См. также: MongoDB\Collection::distinct()
См. также: http://docs.mongodb.org/manual/reference/command/distinct/
Наследование: implements Phalcon\Db\Adapter\MongoDB\Operation\Executable
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
__construct ( string $databaseName, string $collectionName, string $fieldName, array | object $filter = [], array $options = [] ) Constructs a distinct command.
execute ( MongoDB\Driver\Server $server ) : mixed[] Execute the operation.

Приватные методы

Метод Описание
createCommand ( MongoDB\Driver\Server $server ) : MongoDB\Driver\Command Create the distinct command.

Описание методов

__construct() публичный метод

Supported options: * maxTimeMS (integer): The maximum amount of time to allow the query to run. * readConcern (MongoDB\Driver\ReadConcern): Read concern. For servers < 3.2, this option is ignored as read concern is not available. * readPreference (MongoDB\Driver\ReadPreference): Read preference.
public __construct ( string $databaseName, string $collectionName, string $fieldName, array | object $filter = [], array $options = [] )
$databaseName string Database name
$collectionName string Collection name
$fieldName string Field for which to return distinct values
$filter array | object Query by which to filter documents
$options array Command options

execute() публичный метод

Execute the operation.
См. также: Executable::execute()
public execute ( MongoDB\Driver\Server $server ) : mixed[]
$server MongoDB\Driver\Server
Результат mixed[]