final class Tuple
    implements TypeDescriptor
    uses Snapshot
Public API: explicitly declared with @visibility public.

The type of a row of several values: a row constructor or a subquery of several columns (ROW_RESULT).

Only the number of columns is part of the type: comparisons, IN and row subqueries require rows of equal width. Source: https://dev.mysql.com/doc/refman/8.4/en/row-subqueries.html.

Reading the width of a rowdoctest
(new \SqlSemantics\Platform\MySql\Semantics())->analyze('SELECT a FROM t WHERE (a, b) IS NULL') // throws \SqlSemantics\Platform\MySql\Model\Diagnostic\SemanticException: Operand should contain 1 column(s), not 2.

Properties§

public int $width

Methods§

public function __construct(public int $width)

Parameters

$widthintThe number of columns; at least two
Calls 1
public function name(): string

Names the type as the server's result type.

Returns

string
Test cases 1

Test cases 9§

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

Dedicated tests 2
Other tests reaching this symbol 7

Relations§

Instantiated in 2
Type checks 3