classCollationFor
final class CollationFor
implements Scalar, OutputNaming
uses Snapshot
Public API: explicitly declared with
@visibility public.COLLATION FOR (value): the name of the collation of a value.
The server calls pg_catalog.pg_collation_for(value). Rule: PG-COLLATION-FOR-001. Facts: text, NULL when no collation is derived for the value. The result column is named pg_collation_for. Source: https://www.postgresql.org/docs/17/functions-info.html#FUNCTIONS-INFO-CATALOG. Status: Implemented.
(new \SqlSemantics\Platform\PostgreSql\Statement\Invocation\Syntax\CollationFor(new \SqlSemantics\Platform\PostgreSql\Statement\Literal\NullLiteral()))->outputName()->value // => 'pg_collation_for'Properties§
public Scalar $valueMethods§
public function __construct(public Scalar $value)Parameters
$value | Scalar | The value whose collation is asked |
public function outputName(): NameNames an unaliased result column after the function the server calls.
Returns
Test cases 1
public function deriveScalar(Derivation $derivation, Environment $environment): ScalarFactDerives the value and the result of pg_catalog.pg_collation_for.
Parameters
$derivation | Derivation | |
$environment | Environment |
Returns
Calls 3
- method-call CallTyping::catalog() line 53
- new CallTyping line 53
- method-call Derivation::scalar() line 53
public function render(Output $out): voidWrites COLLATION FOR and the value in parentheses.
Parameters
$out | Output |
Test cases 1
Calls 1
- method-call Output::keyword() line 61
Test cases 3§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.