classColumnCountMismatch
final class ColumnCountMismatch
implements Diagnostic
uses Snapshot
Public API: explicitly declared with
@visibility public.A view whose column list has another length than the result of its query.
SQLite reports "expected N columns for 'view' but got M" when the view is used. Source: https://sqlite.org/lang_createview.html.
(new \SqlSemantics\Platform\Sqlite\Semantics())->analyze('CREATE VIEW v (a) AS SELECT 1, 2') // throws \SqlSemantics\Platform\Sqlite\Model\Diagnostic\SemanticException: The column list names 1 columns but the query returns 2.Properties§
public int $listedpublic int $returnedMethods§
public function __construct(public int $listed, public int $returned)Parameters
$listed | int | The number of names in the column list |
$returned | int | The number of columns the query returns |
public function message(): stringDescribes the problem.
Returns
stringTest cases 1
Test cases 2§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.