final class NullLiteral
    implements Scalar, OutputNaming
    uses Snapshot
Public API: explicitly declared with @visibility public.

The constant NULL.

Rule: PG-NULL-001. Facts: the null-only type, nullable; the type it takes is decided by its context. Source: https://www.postgresql.org/docs/17/typeconv-overview.html. Status: Implemented.

Reading the facts of NULLdoctest
$query = (new \SqlSemantics\Platform\PostgreSql\Semantics())->analyze('SELECT NULL');
    $query->field(0)->nullability // => \SqlSemantics\Platform\PostgreSql\Model\Statement\Type\Nullability::Nullable

Methods§

public function outputName(): ?Name

Gives a result column no name.

Returns

Test cases 1
public function deriveScalar(Derivation $derivation, Environment $environment): ScalarFact

Derives the null-only type.

Parameters

$derivationDerivation
$environmentEnvironment

Returns

Calls 3
public function render(Output $out): void

Writes the keyword.

Parameters

$outOutput
Test cases 1
Calls 1

Test cases 136§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 3
Other tests reaching this symbol 133

Relations§

Instantiated in 1
Type checks 2