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

DROP SERVER [IF EXISTS] name: a request to remove a FEDERATED server definition.

Mirrors SQLCOM_DROP_SERVER. Rule: MYSQL-DROP-SERVER-001. Source: https://dev.mysql.com/doc/refman/8.4/en/drop-server.html. Status: Implemented.

Removing a serverdoctest
$drop = (new \SqlSemantics\Platform\MySql\Semantics())->analyze("drop server if exists 's'");
    [$drop->toString(), $drop->statement->name->value] // => ['DROP SERVER IF EXISTS s', 's']

Properties§

public bool $ifExists
public Name $name

Methods§

public function __construct(public bool $ifExists, public Name $name)

Parameters

$ifExistsboolWhether IF EXISTS is written
$nameNameThe server name
public function deriveStatement(Derivation $derivation): void

Has nothing to derive: a server is no relation.

Parameters

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

Writes the request.

Parameters

$outOutput
Calls 3

Test cases 1§

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

Dedicated tests 1

Relations§

Instantiated in 1