You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -465,15 +466,19 @@ public function analyzeQueryPlan(Scope $scope, Expr $queryExpr, ?Type $parameter
465
466
if (!$reflectorinstanceof RecordingReflector) {
466
467
thrownewDbaException('Query plan analysis is only supported with a recording reflector');
467
468
}
468
-
if ($reflectorinstanceof PdoPgSqlQueryReflector) {
469
-
thrownewDbaException('Query plan analysis is not yet supported with the pdo-pgsql reflector, see https://github.com/staabm/phpstan-dba/issues/378');
470
-
}
471
469
472
470
$ds = $reflector->getDatasource();
473
471
if (null === $ds) {
474
472
thrownewDbaException(sprintf('Unable to create datasource from %s', \get_class($reflector)));
"Query is not using an index on table 'ada'.".$proposal."\n\nSimulated query: EXPLAIN (FORMAT JSON) SELECT * FROM ada WHERE email = 'test@example.com'",
108
+
12,
109
+
QueryPlanResult::PGSQL_TIP,
110
+
],
111
+
[
112
+
"Query is not using an index on table 'ada'.".$proposal."\n\nSimulated query: EXPLAIN (FORMAT JSON) SELECT *,adaid FROM ada WHERE email = 'test@example.com'",
113
+
17,
114
+
QueryPlanResult::PGSQL_TIP,
115
+
],
116
+
[
117
+
"Query is not using an index on table 'ada'.".$proposal."\n\nSimulated query: EXPLAIN (FORMAT JSON) SELECT * FROM ada WHERE email = '1970-01-01'",
118
+
22,
119
+
QueryPlanResult::PGSQL_TIP,
120
+
],
121
+
[
122
+
"Query is not using an index on table 'ada'.".$proposal."\n\nSimulated query: EXPLAIN (FORMAT JSON) SELECT * FROM ada WHERE email = '1970-01-01'",
123
+
23,
124
+
QueryPlanResult::PGSQL_TIP,
125
+
],
126
+
[
127
+
"Query is not using an index on table 'ada'.".$proposal."\n\nSimulated query: EXPLAIN (FORMAT JSON) SELECT * FROM ada WHERE email = '1970-01-01'",
128
+
28,
129
+
QueryPlanResult::PGSQL_TIP,
130
+
],
131
+
[
132
+
'Unresolvable Query: Cannot simulate parameter value for type: mixed.',
133
+
61,
134
+
'Make sure all variables involved have a non-mixed type and array-types are specified.',
135
+
],
136
+
]);
137
+
138
+
return;
139
+
}
140
+
109
141
$tip = 'see Mysql Docs https://dev.mysql.com/doc/refman/8.0/en/select-optimization.html';
0 commit comments