ConnectionException.php
2 years ago
ConnectionLost.php
2 years ago
ConstraintViolationException.php
2 years ago
DatabaseDoesNotExist.php
2 years ago
DatabaseObjectExistsException.php
2 years ago
DatabaseObjectNotFoundException.php
2 years ago
DatabaseRequired.php
2 years ago
DeadlockException.php
2 years ago
DriverException.php
2 years ago
ForeignKeyConstraintViolationException.php
2 years ago
InvalidArgumentException.php
2 years ago
InvalidFieldNameException.php
2 years ago
InvalidLockMode.php
2 years ago
LockWaitTimeoutException.php
2 years ago
MalformedDsnException.php
2 years ago
NoKeyValue.php
2 years ago
NonUniqueFieldNameException.php
2 years ago
NotNullConstraintViolationException.php
2 years ago
ReadOnlyException.php
2 years ago
RetryableException.php
2 years ago
SchemaDoesNotExist.php
2 years ago
ServerException.php
2 years ago
SyntaxErrorException.php
2 years ago
TableExistsException.php
2 years ago
TableNotFoundException.php
2 years ago
TransactionRolledBack.php
9 months ago
UniqueConstraintViolationException.php
2 years ago
index.php
2 years ago
NoKeyValue.php
13 lines
| 1 | <?php |
| 2 | namespace MailPoetVendor\Doctrine\DBAL\Exception; |
| 3 | if (!defined('ABSPATH')) exit; |
| 4 | use MailPoetVendor\Doctrine\DBAL\Exception; |
| 5 | use function sprintf; |
| 6 | final class NoKeyValue extends Exception |
| 7 | { |
| 8 | public static function fromColumnCount(int $columnCount) : self |
| 9 | { |
| 10 | return new self(sprintf('Fetching as key-value pairs requires the result to contain at least 2 columns, %d given.', $columnCount)); |
| 11 | } |
| 12 | } |
| 13 |