Fix handling ORDER BY part of queries
Summary:
- new APIs
- maintain relations between connections, queries and column infos
- fix cloning queries with ORDER BY
- update and add autotests
FIXED-IN:3.2
BUG:392753
CCBUG:393705
Test Plan:
Required: KEXI & KDb 3.2 (current master)
Test 1: Open report and query from https://bugs.kde.org/show_bug.cgi?id=392753#c0 in design and data views.
Expected: works, no crashes
Test 2: Try these on a standard Persons and Cars test:
select id from cars order by owner;
select id from cars order by owner, model, id;
select id, model from cars order by 2, 1;
Expected: works, no crash
Reviewers: piggz
Reviewed By: piggz
Subscribers: Kexi-Devel-list
Tags: KDb
Differential Revision: https://phabricator.kde.org/D12873