Issue 121096 - When editing a table query in Design View, the ORDER BY clause of the the query being edited is ignored
Summary: When editing a table query in Design View, the ORDER BY clause of the the que...
Status: RESOLVED FIXED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: 3.4.1
Hardware: PC Windows XP
: P3 Normal (vote)
Target Milestone: 4.2.0
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
: 120457 122165 123687 124348 (view as issue list)
Depends on:
Blocks:
 
Reported: 2012-09-24 21:15 UTC by wheer
Modified: 2016-11-06 17:02 UTC (History)
7 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: 4.2.0-dev
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description wheer 2012-09-24 21:15:16 UTC
While editing a table query in Design View, when a Sort parameter (ascending or descending) is selected for a table field or fields and the query is subsequently saved, the selected Sort parameters are missing when the query is re-opened for editing. This problem did not occur running OO ver. 3.3. I'm running Windows XP Service Pack 3.
Comment 1 Ariel Constenla-Haile 2012-09-25 12:50:32 UTC
version 3.3 is rather old.

Can you test with a newer version?
For example, http://people.apache.org/~arielch/packages/r1389156/win/Apache_OpenOffice_incubating-Dev_AOO350m1_Win_x86_install_en-US.exe
This is a development build, only meant for testing. It will install without replacing your current OOo 3.3 version.

There is also more information needed: for example, are you connecting to an external database?
Comment 2 wheer 2012-09-25 18:34:43 UTC
(In reply to comment #1)

My current version is 3.4.1.  I recently upgraded from version 3.3.  The database is not external and was built using version 3.3.  I discovered the problem in version 3.4.1 while running a couple of queries after the upgrade.  Thank you for your interest.

> version 3.3 is rather old.

Can you test with a newer version?
For example,
> http://people.apache.org/~arielch/packages/r1389156/win/
> Apache_OpenOffice_incubating-Dev_AOO350m1_Win_x86_install_en-US.exe
This is
> a development build, only meant for testing. It will install without
> replacing your current OOo 3.3 version.

There is also more information
> needed: for example, are you connecting to an external database?
Comment 3 kbarber 2015-09-30 03:07:57 UTC
This bug still persists in OpenOffice Base 4.1.1.

Basically, whether you use the wizard or design view to make a query, or if you edit an existing query (right-click, Edit), you have the option to sort fields. Your choices are (not sorted), ascending, and descending. When you save, exit, and reopen the query (through right-click, Edit), you will not see your previous sorting choices. If you run the query (F5), the sorting will not apply. However, if you view the query's SQL (right-click, Edit in SQL View), you will see that the ORDER BY clause is indeed there.

Basically, when you save a query with sorting, the ORDER BY clause is created correctly, but it is not loaded back correctly when you go to edit the query.

I've tried this on Windows 7 and Windows 10.
Comment 4 damjan 2015-11-09 18:06:08 UTC
*** Issue 124348 has been marked as a duplicate of this issue. ***
Comment 5 damjan 2015-11-09 18:16:54 UTC
The problem was that the Query Design View was looking at the wrong position in the SQL parse tree.

Patch committed by revision 1713502, resolving fixed. Thank you for you research!
Comment 6 damjan 2016-11-06 16:01:47 UTC
*** Issue 120457 has been marked as a duplicate of this issue. ***
Comment 7 damjan 2016-11-06 16:19:53 UTC
*** Issue 123687 has been marked as a duplicate of this issue. ***
Comment 8 damjan 2016-11-06 17:02:30 UTC
*** Issue 122165 has been marked as a duplicate of this issue. ***