[MDEV-14917] Problem with MEDIAN() function and using ORDER BY Created: 2018-01-11 Updated: 2018-01-12 Resolved: 2018-01-12 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer - Window functions |
| Affects Version/s: | 10.3.3 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Paul Arch | Assignee: | Varun Gupta (Inactive) |
| Resolution: | Not a Bug | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Ubuntu 16.04 LTS, Virtual Machine 4 cores / 8GB RAM |
||
| Description |
|
https://gist.github.com/paul78oz/4ea9f626ae10333a5abaacf828804f94
As per expanded example from documentation and attached, cannot seem to get working MEDIAN using ORDER BY: eg. SELECT name, median(star_rating) OVER (ORDER by id ROWS 3 preceding) from book_rating Results in: No errors showing in mariadb logs. |
| Comments |
| Comment by Varun Gupta (Inactive) [ 2018-01-12 ] |
|
archio |
| Comment by Paul Arch [ 2018-01-12 ] |
|
OK - looks like the main documentation for the function has now been updated to reflect this, at time of bug report it listed 'ORDER by LIST' in syntax Frame definitions would be nice, to support a 'rolling' median Thanks ! |