Hi I have the following table:
Doc | code | Qty | Next
5211386 | 91992 | 1 | 52183
5211386 | 91992 | 1 | 52182
I trying to figure out a way to group the records by the first two colums, sum the third and concat the last column to obtain something like:
Doc | code | Qty | Next
5211386 | 91992 | 2 | 52183-52182
Any help?
Sounds like you’re looking for a group_concat like function found in MySQL. Check out Allen Browne’s solution