Bug 327993

Summary: Records in reports not sorted according to the sorting of the query
Product: [Applications] KEXI Reporter: Jarosław Staniek <staniek>
Component: Reports and PrintoutsAssignee: Adam Pigg <adam>
Status: CLOSED FIXED    
Severity: normal CC: jonathan
Priority: NOR    
Version: 2.7.4   
Target Milestone: 2.7   
Platform: Compiled Sources   
OS: All   
URL: https://forum.kde.org/viewtopic.php?f=220&t=118478
Latest Commit: Version Fixed In: 2.7.5
Sentry Crash Report:
Bug Depends on:    
Bug Blocks: 327995    

Description Jarosław Staniek 2013-11-23 23:31:08 UTC
Records in reports should be sorted according to the sorting of the query from which they are fed. 

Reproducible: Always

Steps to Reproduce:
1. Create query with sorting explicitly set, eg. descending. Save the query.
2. Create report based on this query
3. Open the report.
Actual Results:  
Report is sorted using default order.

Expected Results:  
Report is sorted using order specified by the query.
Comment 1 Jarosław Staniek 2013-11-23 23:46:42 UTC
The same could apply to forms.
Comment 2 Jarosław Staniek 2013-11-24 00:02:08 UTC
Git commit 046a98a86728981ed3eec723a3b6a8670c437973 by Jaroslaw Staniek.
Committed on 23/11/2013 at 23:33.
Pushed by staniek into branch 'master'.

Make records in reports sorted according to the sorting of the query

Probably applies to forms as well.

M  +1    -0    libs/db/queryschema.cpp

http://commits.kde.org/calligra/046a98a86728981ed3eec723a3b6a8670c437973
Comment 3 Jarosław Staniek 2013-11-24 00:03:11 UTC
Git commit b123505679df59ce1edafb29d64508715d07518b by Jaroslaw Staniek.
Committed on 23/11/2013 at 23:33.
Pushed by staniek into branch 'calligra/2.7'.

Make records in reports sorted according to the sorting of the query

Probably applies to forms as well.

M  +1    -0    libs/db/queryschema.cpp

http://commits.kde.org/calligra/b123505679df59ce1edafb29d64508715d07518b
Comment 4 Jonathan Webb 2016-04-11 10:49:08 UTC
I am using 2.8.5 on Linux Mint 17,  I am finding that the records in a report are not sorted, even though they are derived from a query that has sorting applied
Comment 5 Jarosław Staniek 2016-04-11 11:35:31 UTC
This may be related to a different issue. Do you have the same name used for the query and table? If so perhaps renaming the query (and reassigning it to the report) helps?