-
-
Notifications
You must be signed in to change notification settings - Fork 23
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
running a query like
$queryString = '
SELECT
land.*,
COALESCE(NULLIF(landsprache.ort, ""), land.ort) AS ort
FROM land
INNER JOIN landsprache ON (land.landid=landsprache.landid and landsprache.spracheid = ?)
WHERE (webinaktiv = 0) ORDER BY COALESCE(NULLIF(landsprache.ort, ""), land.ort) ASC
';
thru
phpstan-dba/src/QueryReflection/QueryReflection.php
Lines 349 to 358 in 3996639
| if (preg_match_all(self::REGEX_UNNAMED_PLACEHOLDER, $queryString, $matches) > 0) { | |
| $candidates = $matches[0]; | |
| // filter placeholders within quoted strings | |
| $candidates = array_filter($candidates, function ($candidate) { | |
| return '"' !== $candidate[0] && "'" !== $candidate[0]; | |
| }); | |
| return \count($candidates); | |
| } |
does not return 1 as the number of matched placeholders
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working