array_key_exists

Supported Versions: PHP 4 >= 4.0.7, PHP 5, PHP 7, PHP 8
Checks if the given key or index exists in the array
Alias key_exists
<?php array_key_exists(string|int|float|bool|resource|null $key, array $array): bool
<?php             if (isset($data[$realKey])) {

                $result = new ArrayResult($data[$realKey]);

            } elseif (array_key_exists($realKey, $data)) {

                $result = new ArrayResult([]);

            }

        }
<?php     {

        $index = $this->originalParameterIndex;



        if (! array_key_exists($index, $this->originalParameters)) {

            throw MissingPositionalParameter::new($index);

        }
<?php     {

        $name = substr($sql, 1);



        if (! array_key_exists($name, $this->originalParameters)) {

            throw MissingNamedParameter::new($name);

        }
<?php         if (isset($this->sqlParts['join'][$fromAlias])) {

            foreach ($this->sqlParts['join'][$fromAlias] as $join) {

                if (array_key_exists($join['joinAlias'], $knownAliases)) {

                    throw QueryException::nonUniqueAlias($join['joinAlias'], array_keys($knownAliases));

                }
<?php         $customOptions2 = $column2->getCustomSchemaOptions();



        foreach (array_merge(array_keys($customOptions1), array_keys($customOptions2)) as $key) {

            if (! array_key_exists($key, $properties1) || ! array_key_exists($key, $properties2)) {

                $changedProperties[] = $key;

            } elseif ($properties1[$key] !== $properties2[$key]) {

                $changedProperties[] = $key;
<?php         foreach ($records as $record) {


            $queryColumnName = array_key_exists('current_query', $record) ? 'current_query' : 'query';



            if ($record[$queryColumnName] === $sql) {

                self::assertSame('doctrine', $record['application_name']);