classRoutineProblem
final class RoutineProblem
implements Diagnostic
uses Snapshot
Public API: explicitly declared with
@visibility public.A routine, aggregate or operator definition, signature or option list that the server rejects.
Source: https://www.postgresql.org/docs/17/sql-createfunction.html.
$problem = new \SqlSemantics\Platform\PostgreSql\Statement\Routine\Problem\RoutineProblem(\SqlSemantics\Platform\PostgreSql\Statement\Routine\Problem\RoutineProblemKind::DuplicateParameter, 'a');
$problem->message() // => 'parameter name "a" used more than once'Properties§
public RoutineProblemKind $kindpublic string $subject = ''Methods§
public function __construct(public RoutineProblemKind $kind, public string $subject = '')Parameters
$kind | RoutineProblemKind | What is wrong |
$subject | string | The name the message mentions, if any |
public function message(): stringDescribes the problem as the server does.
Returns
stringTest cases 2
Calls 1
- function-call
sprintfline 37
Test cases 15§
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 13
AggregateChecksTest::testArgumentsChecksTheVariadicOrderedSetcallsBodyFactsTest::testDeriveReportsUtilityStatementscallsObjectFactsTest::testDeriveReportsAPostfixOperatorWithoutIfExistscallsRoutineChecksTest::testBodyReportsALinkSymbolOutsideLanguageCcallsRoutineChecksTest::testBodyReportsBodyProblemscallsRoutineChecksTest::testNamesReportsSharedInputOrOutputNamescallsRoutineChecksTest::testOptionsReportsInvalidParallelModescallsRoutineChecksTest::testParametersReportsParameterProblemscallsAlterOperatorTest::testDeriveStatementReportsAPostfixOperatorcallsAlterRoutineTest::testDeriveStatementReportsAttributesOfProcedurescallsCreateFunctionTest::testDeriveStatementReportsProblemscallsAggregateArgumentsTest::testDeriveClauseReportsOutputArgumentscallsOperatorSignatureTest::testDeriveClauseReportsASingleTypecalls
Relations§
Instantiated in 14
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\AggregateChecks::arguments() packages/sql-semantics-postgres/src/Rules/Routine/AggregateChecks.php:36
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\AggregateChecks::arguments() packages/sql-semantics-postgres/src/Rules/Routine/AggregateChecks.php:48
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\BodyFacts::derive() packages/sql-semantics-postgres/src/Rules/Routine/BodyFacts.php:53
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\ObjectFacts::derive() packages/sql-semantics-postgres/src/Rules/Routine/ObjectFacts.php:47
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::options() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:60
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::options() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:66
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::options() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:69
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::body() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:86
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::body() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:98
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::parameters() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:114
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::parameters() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:121
- new SqlSemantics\Platform\PostgreSql\Rules\Routine\RoutineChecks::names() packages/sql-semantics-postgres/src/Rules/Routine/RoutineChecks.php:158
- new SqlSemantics\Platform\PostgreSql\Statement\Operator\AlterOperator::deriveStatement() packages/sql-semantics-postgres/src/Statement/Operator/AlterOperator.php:63
- new SqlSemantics\Platform\PostgreSql\Statement\Routine\Signature\OperatorSignature::deriveClause() packages/sql-semantics-postgres/src/Statement/Routine/Signature/OperatorSignature.php:84