classShowProcedureCode
final class ShowProcedureCode
implements Statement
uses Snapshot
@visibility public.SHOW PROCEDURE CODE: the internal instructions of a stored procedure, in debug builds of the server.
Rule: MYSQL-SHOW-PROCEDURECODE-001. The statement is available in debug builds of the server only; a release build refuses it (ER_FEATURE_DISABLED), which is reported as UtilityRule::DebugOnly. The rows are those of a debug build: Pos and Instruction, the columns the manual names, typed as the server source declares them. Stored programs are not part of a context, so the name is not resolved. Terminates: a fixed layout. Source: https://dev.mysql.com/doc/refman/8.4/en/show-procedure-code.html. Status: Implemented.
(new \SqlSemantics\Platform\MySql\Semantics())->analyze('SHOW PROCEDURE CODE shop.p') // throws \SqlSemantics\Platform\MySql\Model\Diagnostic\SemanticException: The statement is available in debug builds of the server onlyProperties§
public QualifiedName $nameMethods§
public function __construct(public QualifiedName $name)Parameters
$name | QualifiedName | The name with its optional database |
public function deriveStatement(Derivation $derivation): voidDerives the rows.
Parameters
$derivation | Derivation |
Calls 6
- method-call ShowFacts::rows() line 50
- new ShowFacts line 50
- class-const Report::RoutineCode() line 50
- method-call Derivation::report() line 51
- new UtilityMisuse line 51
- class-const UtilityRule::DebugOnly() line 51
public function render(Output $out): voidWrites the statement.
Parameters
$out | Output |
Calls 4
- method-call Output::keyword() line 59
- method-call Output::name() line 61
- class-const NameUse::Qualifier() line 61
- class-const NameUse::Routine() line 63
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 2
- new SqlSemantics\Platform\MySql\Lowering\Utility\Show\LegacyObjectRule::schema() packages/sql-semantics-mysql/src/Lowering/Utility/Show/LegacyObjectRule.php:139
- new SqlSemantics\Platform\MySql\Lowering\Utility\Show\ObjectRule::definition() packages/sql-semantics-mysql/src/Lowering/Utility/Show/ObjectRule.php:119