Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: Git Master
-
Fix Version/s: 2.0-RC2
-
Component/s: Documentation
-
Security Level: All
-
Labels:None
Description
Getting invalid SQL when using the CountSqlWalker example in the DQL Custom Walkers docs:
SELECT count(DISTINCT z0_.) AS sclr0 FROM ...
From what looks like this part of the example:
...
$pathExpression = new PathExpression(
PathExpression::TYPE_STATE_FIELD | PathExpression::TYPE_SINGLE_VALUED_ASSOCIATION, $parentName, array(
$parent['metadata']->getSingleIdentifierFieldName())
);
...
If you move the field name (3rd parameter) out of the array, it seems to work:
...
$pathExpression = new PathExpression(
PathExpression::TYPE_STATE_FIELD | PathExpression::TYPE_SINGLE_VALUED_ASSOCIATION, $parentName,
$parent['metadata']->getSingleIdentifierFieldName()
);
...
SELECT count(DISTINCT z0_.id) AS sclr0 FROM ...
Activity
Benjamin Eberlei
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Assignee | Roman S. Borschel [ romanb ] | Benjamin Eberlei [ beberlei ] |
| Fix Version/s | 2.0-RC2 [ 10112 ] | |
| Resolution | Fixed [ 1 ] |
Benjamin Eberlei
made changes -
| Workflow | jira [ 12175 ] | jira-feedback [ 14663 ] |
Benjamin Eberlei
made changes -
| Workflow | jira-feedback [ 14663 ] | jira-feedback2 [ 16527 ] |
Benjamin Eberlei
made changes -
| Workflow | jira-feedback2 [ 16527 ] | jira-feedback3 [ 18780 ] |