final class InstallComponent
    implements Statement
    uses Snapshot
Public API: explicitly declared with @visibility public.

INSTALL COMPONENT 'urn', … [SET assignment, …]: a request to load server components (MySQL 8.0 and later).

Mirrors PT_install_component (Sql_cmd_install_component). Rule: MYSQL-INSTALL-COMPONENT-001. The SET list (MySQL 8.0.33 and later) gives component variables their values as the components are loaded; each value is derived where no relation is visible, and each variable is a system variable whose facts name the server state it depends on. The statement returns no rows. Source: https://dev.mysql.com/doc/refman/8.4/en/install-component.html. Status: Implemented.

Installing a component with a variable valuedoctest
$install = (new \SqlSemantics\Platform\MySql\Semantics())->analyze("install component 'file://a', 'file://b' set global a.size = 2 * 8");
    [$install->toString(), count($install->statement->components)] // => ["INSTALL COMPONENT 'file://a', 'file://b' SET GLOBAL a.size = 2 * 8", 2]

Properties§

public list<Text> $components
public list<ComponentSetting> $settings

Methods§

public function __construct(list<Text> $components, list<ComponentSetting> $settings = [])

Parameters

$componentslist<Text>The component URNs in written order; at least one
$settingslist<ComponentSetting>The variable assignments in written order

Throws

InvalidConstruction When no component is named
Calls 3
public function deriveStatement(Derivation $derivation): void

Derives each variable and value where no relation is visible.

Parameters

$derivationDerivation
Calls 2
public function render(Output $out): void

Writes the request.

Parameters

$outOutput
Calls 1

Test cases 2§

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

Dedicated tests 1
Other tests reaching this symbol 1

Relations§

Instantiated in 1