Actions
Bug #6421
closed![Author: Taras Chervinka](https://www.gravatar.com/avatar/2700a814de1c8e45c477fa2093624718?rating=PG&size=50&default=https%3A%2F%2Fassets.plan.io%2Fimages%2Fdefault_avatar.png)
![Assignee: Michael Kay](https://www.gravatar.com/avatar/db6526d63053f09b62e52c2da8b2230a?rating=PG&size=22&default=https%3A%2F%2Fassets.plan.io%2Fimages%2Fdefault_avatar.png)
XQuery "group by" - result data duplication
Start date:
2024-05-13
Due date:
% Done:
0%
Estimated time:
Legacy ID:
Applies to branch:
10, 11, 12
Fix Committed on Branch:
Fixed in Maintenance Release:
Platforms:
.NET, Java
Description
let $a := <root>
<user id="1">A</user>
<user id="2">B</user>
<user id="1">C</user>
<user id="1">D</user>
<user id="1">E</user>
</root>
return string-join(
for $usr in $a/user
let $id := data($usr/@id)
where $id = '1'
group by $id
return
for $u in $a/user
where $u/@id = $usr/@id
return $u/text(), ", ")
we got a case from a customer and simplified it. The expression produces different results in 9.5, 10 and 11 9.5 - A, C, D, E 10,11 - A, A, A, A, C, C, C, C, D, D, D, D, E, E, E, E
Related issues
Please register to edit this issue
Actions