Thread: PATCH: improve sorting in the Data Editor
Hello, Here is a small improvement about sorting in the Data editor. Problem: If a table has a PK or OIDs, it gets sorted by PK/OID by default. When a user wants to sort by any other column, he has first to click "Remove sort" in the context menu, and only then click "Sort ascending"(descending) on column of his choice. If he doesn't remove the default sort, he will get no effect and probably be puzzled for the first time until guesses that he makes ORDER BY column_pk, column_of_choice which is totally useless. The need to "Remove sort" each time is annoying. Solution: When a user chooses to sort by some column, we must discard the default sort order. Please see the attached patch. Thanks. -- Best regards, J.F.
Attachment
Hello,
Here is a small improvement about sorting in the Data editor.
Problem:
If a table has a PK or OIDs, it gets sorted by PK/OID by default.
When a user wants to sort by any other column, he has first to click
"Remove sort" in the context menu, and only then click "Sort
ascending"(descending) on column of his choice.
If he doesn't remove the default sort, he will get no effect and
probably be puzzled for the first time until guesses that he makes
ORDER BY column_pk, column_of_choice
which is totally useless.
The need to "Remove sort" each time is annoying.
Solution:
When a user chooses to sort by some column, we must discard the
default sort order.
Please see the attached patch.
Thanks.
--
Best regards,
J.F.
--
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
Sanket,Can you please review it?On Sun, Aug 2, 2015 at 3:49 PM, J.F. Oster <jinfroster@mail.ru> wrote:--Hello,
Here is a small improvement about sorting in the Data editor.
Problem:
If a table has a PK or OIDs, it gets sorted by PK/OID by default.
When a user wants to sort by any other column, he has first to click
"Remove sort" in the context menu, and only then click "Sort
ascending"(descending) on column of his choice.
If he doesn't remove the default sort, he will get no effect and
probably be puzzled for the first time until guesses that he makes
ORDER BY column_pk, column_of_choice
which is totally useless.
The need to "Remove sort" each time is annoying.
Solution:
When a user chooses to sort by some column, we must discard the
default sort order.
Please see the attached patch.
Thanks.
--
Best regards,
J.F.
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
Sure Ashesh.Regards,Sanket MehtaSr Software engineerEnterprisedbOn Mon, Aug 3, 2015 at 10:49 AM, Ashesh Vashi <ashesh.vashi@enterprisedb.com> wrote:Sanket,Can you please review it?On Sun, Aug 2, 2015 at 3:49 PM, J.F. Oster <jinfroster@mail.ru> wrote:--Hello,
Here is a small improvement about sorting in the Data editor.
Problem:
If a table has a PK or OIDs, it gets sorted by PK/OID by default.
When a user wants to sort by any other column, he has first to click
"Remove sort" in the context menu, and only then click "Sort
ascending"(descending) on column of his choice.
If he doesn't remove the default sort, he will get no effect and
probably be puzzled for the first time until guesses that he makes
ORDER BY column_pk, column_of_choice
which is totally useless.
The need to "Remove sort" each time is annoying.
Solution:
When a user chooses to sort by some column, we must discard the
default sort order.
Please see the attached patch.
Thanks.
--
Best regards,
J.F.
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
<p>Hello Sanket,<p><br /><p>The behaviour you described after applying the patch is correct in my opinion.<p>That is a usefulfeature to append further sorting columns after previous ones - the patch has no intent to remove this feature at all.<p><br/><p>For example, "ORDER BY employee_name, employee_id" may be quite reasonable.<p>Whereas "ORDER BY employee_id,employee_name" is *always* meaningless.<p><br /><p>Sure, the user could define that meaningless search orderhimself manually, but that's his fault.<p>Our duty is to avoid this situation caused by default sort order.<p><br /><p><br/><p><br /><p>Wednesday, August 5, 2015, 8:20:51 PM, you wrote:<p><br /><div><table border="0" cellpadding="1" cellspacing="2"><trvalign="top"><td style="background-color: #0000ff;" width="12"><p><span class="rvts6">></span></td><tdstyle="background-color: #ffffff;" width="1125"><p><span class="rvts7">Hi,</span><p><br/><p><span class="rvts7">I have reviewed the patch and below is analysis.</span><p><br /><p><spanclass="rvts7">- Behaviour of sorting in data editor before applying the patch is as below:</span><p><br /><p><spanclass="rvts7">By default table is sorted by PK/OID in ascending order.</span><p><span class="rvts7">when user selectany other column to sort the table, that column gets the second priority for sorting the table like i.e.order by col_pk,col_column1 where col_pk is column having PK and col_column1 is any other ordinary column.</span><p><br /><p><spanclass="rvts7">- below is the behaviour I have found after applying the patch:</span><p><br /><p><span class="rvts7">Bydefault table is sorted by PK/OID in ascending order.</span><p><span class="rvts7">When user selects anyother column default sorting is removed and table is getting sorted by newly selected column.</span><p><span class="rvts7">Butafter this if user wants to sort the table by PK or any other column it will have the same behaviour likeit has before applying the patch. i.e. order by col_column1, col_PK where col_column1 and col_PK are same as explainedabove. It will not sort the table by newly selected column(col_PK) because sorting of older column(col_column1)is still in effect and has the higher priority.</span><p><br /><p><span class="rvts7">This will also confusethe user.</span><p><br /><p><span class="rvts7">So according to me current behaviour of sorting of table data in pgadminis acceptable.</span><p><br /><p><span class="rvts7">Dave, </span><p><span class="rvts7">Do you have any other thoughtson it?</span><p><br /><p><br /><p><br /><p><span class="rvts7">Regards,</span><p><span class="rvts7">Sanket Mehta</span><p><spanclass="rvts7">Sr Software engineer</span><p><span class="rvts7">Enterprisedb</span><p><br /><p><br /><p><spanclass="rvts7">On Mon, Aug 3, 2015 at 11:07 AM, Sanket Mehta <</span><a class="rvts8" href="mailto:sanket.mehta@enterprisedb.com">sanket.mehta@enterprisedb.com</a><spanclass="rvts7">> wrote:</span><p><br/><p><span class="rvts7">Sure Ashesh.</span><p><br /><p><br /><p><span class="rvts7">Regards,</span><p><spanclass="rvts7">Sanket Mehta</span><p><span class="rvts7">Sr Software engineer</span><p><spanclass="rvts7">Enterprisedb</span><p><br /><p><br /><p><span class="rvts7">On Mon, Aug 3, 2015 at 10:49AM, Ashesh Vashi <</span><a class="rvts8" href="mailto:ashesh.vashi@enterprisedb.com">ashesh.vashi@enterprisedb.com</a><spanclass="rvts7">> wrote:</span><p><br/><p><span class="rvts7">Sanket,</span><p><br /><p><span class="rvts7">Can you please review it?</span><p><br/><p><br /><p><br /><p><span class="rvts9">--</span><p><span class="rvts9">Thanks & Regards,</span><p><br/><p><span class="rvts9">Ashesh Vashi</span><p><span class="rvts9">EnterpriseDB INDIA: </span><a class="rvts10"href="http://www.enterprisedb.com">Enterprise PostgreSQL Company</a><p><br /><p><a class="rvts11" href="http://www.linkedin.com/in/asheshvashi">http://www.linkedin.com/in/asheshvashi</a><p><br/><p><br /><p><span class="rvts7">OnSun, Aug 2, 2015 at 3:49 PM, J.F. Oster <</span><a class="rvts8" href="mailto:jinfroster@mail.ru">jinfroster@mail.ru</a><spanclass="rvts7">> wrote:</span><p><span class="rvts7">Hello,</span><p><br/><p><span class="rvts7">Here is a small improvement about sorting in the Data editor.</span><p><br/><p><span class="rvts7">Problem:</span><p><span class="rvts7">If a table has a PK or OIDs, it gets sortedby PK/OID by default.</span><p><span class="rvts7">When a user wants to sort by any other column, he has first to click</span><p><spanclass="rvts7">"Remove sort" in the context menu, and only then click "Sort</span><p><span class="rvts7">ascending"(descending)on column of his choice.</span><p><br /><p><span class="rvts7">If he doesn't remove thedefault sort, he will get no effect and</span><p><span class="rvts7">probably be puzzled for the first time until guessesthat he makes</span><p><span class="rvts7"> ORDER BY column_pk, column_of_choice</span><p><span class="rvts7">whichis totally useless.</span><p><span class="rvts7">The need to "Remove sort" each time is annoying.</span><p><br/><p><span class="rvts7">Solution:</span><p><span class="rvts7">When a user chooses to sort by somecolumn, we must discard the</span><p><span class="rvts7">default sort order.</span><p><br /><p><span class="rvts7">Pleasesee the attached patch.</span><p><span class="rvts7">Thanks.</span><p><br /><p><span class="rvts12">--</span><p><spanclass="rvts12">Best regards,</span><p><span class="rvts12"> J.F.</span><p><br /><p><spanclass="rvts12">--</span><p><span class="rvts12">Sent via pgadmin-hackers mailing list (</span><a class="rvts8"href="mailto:pgadmin-hackers@postgresql.org">pgadmin-hackers@postgresql.org</a><span class="rvts12">)</span><p><spanclass="rvts12">To make changes to your subscription:</span><p><a class="rvts8" href="http://www.postgresql.org/mailpref/pgadmin-hackers">http://www.postgresql.org/mailpref/pgadmin-hackers</a><p><br /></td></tr></table></div><p><br/><p><br /><p><br /><p><br /><p><span class="rvts13">-- </span><p><span class="rvts13">Bestregards,</span><p><span class="rvts13"> J.F.</span>
Hi,I have reviewed the patch and below is analysis.- Behaviour of sorting in data editor before applying the patch is as below:By default table is sorted by PK/OID in ascending order.when user select any other column to sort the table, that column gets the second priority for sorting the table like i.e.order by col_pk, col_column1 where col_pk is column having PK and col_column1 is any other ordinary column.- below is the behaviour I have found after applying the patch:By default table is sorted by PK/OID in ascending order.When user selects any other column default sorting is removed and table is getting sorted by newly selected column.But after this if user wants to sort the table by PK or any other column it will have the same behaviour like it has before applying the patch. i.e. order by col_column1, col_PK where col_column1 and col_PK are same as explained above. It will not sort the table by newly selected column(col_PK) because sorting of older column(col_column1) is still in effect and has the higher priority.This will also confuse the user.So according to me current behaviour of sorting of table data in pgadmin is acceptable.Dave,Do you have any other thoughts on it?
Regards,Sanket MehtaSr Software engineerEnterprisedbOn Mon, Aug 3, 2015 at 11:07 AM, Sanket Mehta <sanket.mehta@enterprisedb.com> wrote:Sure Ashesh.Regards,Sanket MehtaSr Software engineerEnterprisedbOn Mon, Aug 3, 2015 at 10:49 AM, Ashesh Vashi <ashesh.vashi@enterprisedb.com> wrote:Sanket,Can you please review it?On Sun, Aug 2, 2015 at 3:49 PM, J.F. Oster <jinfroster@mail.ru> wrote:--Hello,
Here is a small improvement about sorting in the Data editor.
Problem:
If a table has a PK or OIDs, it gets sorted by PK/OID by default.
When a user wants to sort by any other column, he has first to click
"Remove sort" in the context menu, and only then click "Sort
ascending"(descending) on column of his choice.
If he doesn't remove the default sort, he will get no effect and
probably be puzzled for the first time until guesses that he makes
ORDER BY column_pk, column_of_choice
which is totally useless.
The need to "Remove sort" each time is annoying.
Solution:
When a user chooses to sort by some column, we must discard the
default sort order.
Please see the attached patch.
Thanks.
--
Best regards,
J.F.
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake
EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
On Wed, Aug 5, 2015 at 6:20 PM, Sanket Mehta <sanket.mehta@enterprisedb.com> wrote:Hi,I have reviewed the patch and below is analysis.- Behaviour of sorting in data editor before applying the patch is as below:By default table is sorted by PK/OID in ascending order.when user select any other column to sort the table, that column gets the second priority for sorting the table like i.e.order by col_pk, col_column1 where col_pk is column having PK and col_column1 is any other ordinary column.- below is the behaviour I have found after applying the patch:By default table is sorted by PK/OID in ascending order.When user selects any other column default sorting is removed and table is getting sorted by newly selected column.But after this if user wants to sort the table by PK or any other column it will have the same behaviour like it has before applying the patch. i.e. order by col_column1, col_PK where col_column1 and col_PK are same as explained above. It will not sort the table by newly selected column(col_PK) because sorting of older column(col_column1) is still in effect and has the higher priority.This will also confuse the user.So according to me current behaviour of sorting of table data in pgadmin is acceptable.Dave,Do you have any other thoughts on it?I think J.F's patch makes sense. It is a little more complex logically speaking, but I also think it's more likely what the user would expect to happen.Regards,Sanket MehtaSr Software engineerEnterprisedbOn Mon, Aug 3, 2015 at 11:07 AM, Sanket Mehta <sanket.mehta@enterprisedb.com> wrote:Sure Ashesh.Regards,Sanket MehtaSr Software engineerEnterprisedbOn Mon, Aug 3, 2015 at 10:49 AM, Ashesh Vashi <ashesh.vashi@enterprisedb.com> wrote:Sanket,Can you please review it?On Sun, Aug 2, 2015 at 3:49 PM, J.F. Oster <jinfroster@mail.ru> wrote:--Hello,
Here is a small improvement about sorting in the Data editor.
Problem:
If a table has a PK or OIDs, it gets sorted by PK/OID by default.
When a user wants to sort by any other column, he has first to click
"Remove sort" in the context menu, and only then click "Sort
ascending"(descending) on column of his choice.
If he doesn't remove the default sort, he will get no effect and
probably be puzzled for the first time until guesses that he makes
ORDER BY column_pk, column_of_choice
which is totally useless.
The need to "Remove sort" each time is annoying.
Solution:
When a user chooses to sort by some column, we must discard the
default sort order.
Please see the attached patch.
Thanks.
--
Best regards,
J.F.
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers--Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake
EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
<p><br /><p>Ashesh, will you commit this, please?<p><br /><p><br /><p>Thursday, August 6, 2015, 12:16:37 PM, you wrote:<p><br/><div><table border="0" cellpadding="1" cellspacing="2"><tr valign="top"><td style="background-color: #0000ff;"width="12"><p><span class="rvts6">></span></td><td style="background-color: #ffffff;" width="1125"><p><span class="rvts7">Hi,</span><p><br/><p><span class="rvts7">In this case patch looks good to me.</span><p><br /><p><br /><p><spanclass="rvts7">Regards,</span><p><span class="rvts7">Sanket Mehta</span><p><span class="rvts7">Sr Software engineer</span><p><spanclass="rvts7">Enterprisedb</span><p><br /><p><br /><p><span class="rvts7">On Thu, Aug 6, 2015 at 2:22PM, Dave Page <</span><a class="rvts8" href="mailto:dpage@pgadmin.org">dpage@pgadmin.org</a><span class="rvts7">>wrote:</span><p><br /><p><br /><p><br /><p><br /><p><br /><p><span class="rvts7">On Wed, Aug 5, 2015 at6:20 PM, Sanket Mehta <</span><a class="rvts8" href="mailto:sanket.mehta@enterprisedb.com">sanket.mehta@enterprisedb.com</a><spanclass="rvts7">> wrote:</span><p><br/><p><span class="rvts7">Hi,</span><p><br /><p><span class="rvts7">I have reviewed the patch and belowis analysis.</span><p><br /><p><span class="rvts7">- Behaviour of sorting in data editor before applying the patch isas below:</span><p><br /><p><span class="rvts7">By default table is sorted by PK/OID in ascending order.</span><p><spanclass="rvts7">when user select any other column to sort the table, that column gets the second priorityfor sorting the table like i.e.order by col_pk, col_column1 where col_pk is column having PK and col_column1 is anyother ordinary column.</span><p><br /><p><span class="rvts7">- below is the behaviour I have found after applying thepatch:</span><p><br /><p><span class="rvts7">By default table is sorted by PK/OID in ascending order.</span><p><span class="rvts7">Whenuser selects any other column default sorting is removed and table is getting sorted by newly selectedcolumn.</span><p><span class="rvts7">But after this if user wants to sort the table by PK or any other column itwill have the same behaviour like it has before applying the patch. i.e. order by col_column1, col_PK where col_column1and col_PK are same as explained above. It will not sort the table by newly selected column(col_PK) because sortingof older column(col_column1) is still in effect and has the higher priority.</span><p><br /><p><span class="rvts7">Thiswill also confuse the user.</span><p><br /><p><span class="rvts7">So according to me current behaviourof sorting of table data in pgadmin is acceptable.</span><p><br /><p><span class="rvts7">Dave, </span><p><span class="rvts7">Doyou have any other thoughts on it?</span><p><br /><p><span class="rvts7">I think J.F's patch makes sense.It is a little more complex logically speaking, but I also think it's more likely what the user would expect to happen.</span><p><spanclass="rvts7"> </span><p><br /><p><br /><p><br /><p><span class="rvts7">Regards,</span><p><span class="rvts7">SanketMehta</span><p><span class="rvts7">Sr Software engineer</span><p><span class="rvts7">Enterprisedb</span><p><br/><p><br /><p><span class="rvts7">On Mon, Aug 3, 2015 at 11:07 AM, Sanket Mehta <</span><aclass="rvts8" href="mailto:sanket.mehta@enterprisedb.com">sanket.mehta@enterprisedb.com</a><span class="rvts7">>wrote:</span><p><br /><p><span class="rvts7">Sure Ashesh.</span><p><br /><p><br /><p><span class="rvts7">Regards,</span><p><spanclass="rvts7">Sanket Mehta</span><p><span class="rvts7">Sr Software engineer</span><p><spanclass="rvts7">Enterprisedb</span><p><br /><p><br /><p><span class="rvts7">On Mon, Aug 3, 2015 at 10:49AM, Ashesh Vashi <</span><a class="rvts8" href="mailto:ashesh.vashi@enterprisedb.com">ashesh.vashi@enterprisedb.com</a><spanclass="rvts7">> wrote:</span><p><br/><p><span class="rvts7">Sanket,</span><p><br /><p><span class="rvts7">Can you please review it?</span><p><br/><p><br /><p><br /><p><span class="rvts9">--</span><p><span class="rvts9">Thanks & Regards,</span><p><br/><p><span class="rvts9">Ashesh Vashi</span><p><span class="rvts9">EnterpriseDB INDIA: </span><a class="rvts10"href="http://www.enterprisedb.com">Enterprise PostgreSQL Company</a><p><br /><p><a class="rvts11" href="http://www.linkedin.com/in/asheshvashi">http://www.linkedin.com/in/asheshvashi</a><p><br/><p><br /><p><span class="rvts7">OnSun, Aug 2, 2015 at 3:49 PM, J.F. Oster <</span><a class="rvts8" href="mailto:jinfroster@mail.ru">jinfroster@mail.ru</a><spanclass="rvts7">> wrote:</span><p><span class="rvts7">Hello,</span><p><br/><p><span class="rvts7">Here is a small improvement about sorting in the Data editor.</span><p><br/><p><span class="rvts7">Problem:</span><p><span class="rvts7">If a table has a PK or OIDs, it gets sortedby PK/OID by default.</span><p><span class="rvts7">When a user wants to sort by any other column, he has first to click</span><p><spanclass="rvts7">"Remove sort" in the context menu, and only then click "Sort</span><p><span class="rvts7">ascending"(descending)on column of his choice.</span><p><br /><p><span class="rvts7">If he doesn't remove thedefault sort, he will get no effect and</span><p><span class="rvts7">probably be puzzled for the first time until guessesthat he makes</span><p><span class="rvts7"> ORDER BY column_pk, column_of_choice</span><p><span class="rvts7">whichis totally useless.</span><p><span class="rvts7">The need to "Remove sort" each time is annoying.</span><p><br/><p><span class="rvts7">Solution:</span><p><span class="rvts7">When a user chooses to sort by somecolumn, we must discard the</span><p><span class="rvts7">default sort order.</span><p><br /><p><span class="rvts7">Pleasesee the attached patch.</span><p><span class="rvts7">Thanks.</span><p><br /><p><span class="rvts12">--</span><p><spanclass="rvts12">Best regards,</span><p><span class="rvts12"> J.F.</span><p><br /><p><spanclass="rvts12">--</span><p><span class="rvts12">Sent via pgadmin-hackers mailing list (</span><a class="rvts8"href="mailto:pgadmin-hackers@postgresql.org">pgadmin-hackers@postgresql.org</a><span class="rvts12">)</span><p><spanclass="rvts12">To make changes to your subscription:</span><p><a class="rvts8" href="http://www.postgresql.org/mailpref/pgadmin-hackers">http://www.postgresql.org/mailpref/pgadmin-hackers</a><p><br /><p><br/><p><br /><p><br /><p><br /><p><span class="rvts12">-- </span><p><br /><p><span class="rvts12">Dave Page</span><p><spanclass="rvts12">Blog: </span><a class="rvts8" href="http://pgsnake.blogspot.com">http://pgsnake.blogspot.com</a><p><spanclass="rvts12">Twitter: @pgsnake</span><p><br /><p><spanclass="rvts12">EnterpriseDB UK: </span><a class="rvts8" href="http://www.enterprisedb.com">http://www.enterprisedb.com</a><p><spanclass="rvts12">The Enterprise PostgreSQL Company</span></td></tr></table></div><p><br/><p><br /><p><br /><p><br /><p><span class="rvts13">-- </span><p><span class="rvts13">Bestregards,</span><p><span class="rvts13"> J.F.</span>
<p><br /><p>Hi, Dave!<p><br /><p>I see bugreports and patches for PgAdmin III are set aside.<p>What's the current state ofthe project?<p>If it isn't going to develop further - that should be told to community.<p><br /><p>Seeing one's effortsbeing ignored simply kills enthusiasm :(<p><br /><p><br /><p>Wednesday, August 12, 2015, 7:06:04 PM, J.F. Oster wrote:<p><br/><div><table border="0" cellpadding="1" cellspacing="2"><tr valign="top"><td style="background-color: #0000ff;"width="7"><p><span class="rvts6">></span></td><td style="background-color: #ffffff;" width="1130"><p><br /><p><spanclass="rvts7">Ashesh, will you commit this, please?</span><p><br /><p><br /><p><span class="rvts7">Thursday, August6, 2015, 12:16:37 PM, you wrote:</span><p><br /><div><table border="0" cellpadding="1" cellspacing="2"><tr valign="top"><tdstyle="background-color: #0000ff;" width="23"><p><span class="rvts8">></span></td><td style="background-color:#ffffff;" width="1101"><p><span class="rvts9">Hi,</span><p><br /><p><span class="rvts9">In this casepatch looks good to me.</span><p><br /><p><br /><p><span class="rvts9">Regards,</span><p><span class="rvts9">Sanket Mehta</span><p><spanclass="rvts9">Sr Software engineer</span><p><span class="rvts9">Enterprisedb</span><p><br /><p><br /><p><spanclass="rvts9">On Thu, Aug 6, 2015 at 2:22 PM, Dave Page <</span><a class="rvts10" href="mailto:dpage@pgadmin.org">dpage@pgadmin.org</a><spanclass="rvts9">> wrote:</span><p><br /><p><br /><p><br /><p><br/><p><br /><p><span class="rvts9">On Wed, Aug 5, 2015 at 6:20 PM, Sanket Mehta <</span><a class="rvts10" href="mailto:sanket.mehta@enterprisedb.com">sanket.mehta@enterprisedb.com</a><spanclass="rvts9">> wrote:</span><p><br/><p><span class="rvts9">Hi,</span><p><br /><p><span class="rvts9">I have reviewed the patch and belowis analysis.</span><p><br /><p><span class="rvts9">- Behaviour of sorting in data editor before applying the patch isas below:</span><p><br /><p><span class="rvts9">By default table is sorted by PK/OID in ascending order.</span><p><spanclass="rvts9">when user select any other column to sort the table, that column gets the second priorityfor sorting the table like i.e.order by col_pk, col_column1 where col_pk is column having PK and col_column1 is anyother ordinary column.</span><p><br /><p><span class="rvts9">- below is the behaviour I have found after applying thepatch:</span><p><br /><p><span class="rvts9">By default table is sorted by PK/OID in ascending order.</span><p><span class="rvts9">Whenuser selects any other column default sorting is removed and table is getting sorted by newly selectedcolumn.</span><p><span class="rvts9">But after this if user wants to sort the table by PK or any other column itwill have the same behaviour like it has before applying the patch. i.e. order by col_column1, col_PK where col_column1and col_PK are same as explained above. It will not sort the table by newly selected column(col_PK) because sortingof older column(col_column1) is still in effect and has the higher priority.</span><p><br /><p><span class="rvts9">Thiswill also confuse the user.</span><p><br /><p><span class="rvts9">So according to me current behaviourof sorting of table data in pgadmin is acceptable.</span><p><br /><p><span class="rvts9">Dave, </span><p><span class="rvts9">Doyou have any other thoughts on it?</span><p><br /><p><span class="rvts9">I think J.F's patch makes sense.It is a little more complex logically speaking, but I also think it's more likely what the user would expect to happen.</span><p><spanclass="rvts9"> </span><p><br /><p><br /><p><br /><p><span class="rvts9">Regards,</span><p><span class="rvts9">SanketMehta</span><p><span class="rvts9">Sr Software engineer</span><p><span class="rvts9">Enterprisedb</span><p><br/><p><br /><p><span class="rvts9">On Mon, Aug 3, 2015 at 11:07 AM, Sanket Mehta <</span><aclass="rvts10" href="mailto:sanket.mehta@enterprisedb.com">sanket.mehta@enterprisedb.com</a><span class="rvts9">>wrote:</span><p><br /><p><span class="rvts9">Sure Ashesh.</span><p><br /><p><br /><p><span class="rvts9">Regards,</span><p><spanclass="rvts9">Sanket Mehta</span><p><span class="rvts9">Sr Software engineer</span><p><spanclass="rvts9">Enterprisedb</span><p><br /><p><br /><p><span class="rvts9">On Mon, Aug 3, 2015 at 10:49AM, Ashesh Vashi <</span><a class="rvts10" href="mailto:ashesh.vashi@enterprisedb.com">ashesh.vashi@enterprisedb.com</a><spanclass="rvts9">> wrote:</span><p><br/><p><span class="rvts9">Sanket,</span><p><br /><p><span class="rvts9">Can you please review it?</span><p><br/><p><br /><p><br /><p><span class="rvts11">--</span><p><span class="rvts11">Thanks & Regards,</span><p><br/><p><span class="rvts11">Ashesh Vashi</span><p><span class="rvts11">EnterpriseDB INDIA: </span><a class="rvts12"href="http://www.enterprisedb.com">Enterprise PostgreSQL Company</a><p><br /><p><a class="rvts13" href="http://www.linkedin.com/in/asheshvashi">http://www.linkedin.com/in/asheshvashi</a><p><br/><p><br /><p><span class="rvts9">OnSun, Aug 2, 2015 at 3:49 PM, J.F. Oster <</span><a class="rvts10" href="mailto:jinfroster@mail.ru">jinfroster@mail.ru</a><spanclass="rvts9">> wrote:</span><p><span class="rvts9">Hello,</span><p><br/><p><span class="rvts9">Here is a small improvement about sorting in the Data editor.</span><p><br/><p><span class="rvts9">Problem:</span><p><span class="rvts9">If a table has a PK or OIDs, it gets sortedby PK/OID by default.</span><p><span class="rvts9">When a user wants to sort by any other column, he has first to click</span><p><spanclass="rvts9">"Remove sort" in the context menu, and only then click "Sort</span><p><span class="rvts9">ascending"(descending)on column of his choice.</span><p><br /><p><span class="rvts9">If he doesn't remove thedefault sort, he will get no effect and</span><p><span class="rvts9">probably be puzzled for the first time until guessesthat he makes</span><p><span class="rvts9"> ORDER BY column_pk, column_of_choice</span><p><span class="rvts9">whichis totally useless.</span><p><span class="rvts9">The need to "Remove sort" each time is annoying.</span><p><br/><p><span class="rvts9">Solution:</span><p><span class="rvts9">When a user chooses to sort by somecolumn, we must discard the</span><p><span class="rvts9">default sort order.</span><p><br /><p><span class="rvts9">Pleasesee the attached patch.</span><p><span class="rvts9">Thanks.</span><p><br /><p><span class="rvts14">--</span><p><spanclass="rvts14">Best regards,</span><p><span class="rvts14"> J.F.</span><p><br /><p><spanclass="rvts14">--</span><p><span class="rvts14">Sent via pgadmin-hackers mailing list (</span><a class="rvts10"href="mailto:pgadmin-hackers@postgresql.org">pgadmin-hackers@postgresql.org</a><span class="rvts14">)</span><p><spanclass="rvts14">To make changes to your subscription:</span><p><a class="rvts10" href="http://www.postgresql.org/mailpref/pgadmin-hackers">http://www.postgresql.org/mailpref/pgadmin-hackers</a><p><br /><p><br/><p><br /><p><br /><p><br /><p><span class="rvts14">-- </span><p><br /><p><span class="rvts14">Dave Page</span><p><spanclass="rvts14">Blog: </span><a class="rvts10" href="http://pgsnake.blogspot.com">http://pgsnake.blogspot.com</a><p><spanclass="rvts14">Twitter: @pgsnake</span><p><br /><p><spanclass="rvts14">EnterpriseDB UK: </span><a class="rvts10" href="http://www.enterprisedb.com">http://www.enterprisedb.com</a><p><spanclass="rvts14">The Enterprise PostgreSQL Company</span></td></tr></table></div><p><br/><p><br /><p><br /><p><br /><p><span class="rvts15">-- </span><p><span class="rvts15">Bestregards,</span><p><span class="rvts15"> J.F.</span></td></tr></table></div><p><br /><p><br /><p><br /><p><br/><p><span class="rvts16">-- </span><p><span class="rvts16">Best regards,</span><p><span class="rvts16"> J.F.</span>
Hi, Dave!
I see bugreports and patches for PgAdmin III are set aside.
What's the current state of the project?
If it isn't going to develop further - that should be told to community.
Seeing one's efforts being ignored simply kills enthusiasm :(
Wednesday, August 12, 2015, 7:06:04 PM, J.F. Oster wrote:
>
Ashesh, will you commit this, please?
Thursday, August 6, 2015, 12:16:37 PM, you wrote:
>
Hi,
In this case patch looks good to me.
Regards,
Sanket Mehta
Sr Software engineer
Enterprisedb
On Thu, Aug 6, 2015 at 2:22 PM, Dave Page <dpage@pgadmin.org> wrote:
On Wed, Aug 5, 2015 at 6:20 PM, Sanket Mehta <sanket.mehta@enterprisedb.com> wrote:
Hi,
I have reviewed the patch and below is analysis.
- Behaviour of sorting in data editor before applying the patch is as below:
By default table is sorted by PK/OID in ascending order.
when user select any other column to sort the table, that column gets the second priority for sorting the table like i.e.order by col_pk, col_column1 where col_pk is column having PK and col_column1 is any other ordinary column.
- below is the behaviour I have found after applying the patch:
By default table is sorted by PK/OID in ascending order.
When user selects any other column default sorting is removed and table is getting sorted by newly selected column.
But after this if user wants to sort the table by PK or any other column it will have the same behaviour like it has before applying the patch. i.e. order by col_column1, col_PK where col_column1 and col_PK are same as explained above. It will not sort the table by newly selected column(col_PK) because sorting of older column(col_column1) is still in effect and has the higher priority.
This will also confuse the user.
So according to me current behaviour of sorting of table data in pgadmin is acceptable.
Dave,
Do you have any other thoughts on it?
I think J.F's patch makes sense. It is a little more complex logically speaking, but I also think it's more likely what the user would expect to happen.
Regards,
Sanket Mehta
Sr Software engineer
Enterprisedb
On Mon, Aug 3, 2015 at 11:07 AM, Sanket Mehta <sanket.mehta@enterprisedb.com> wrote:
Sure Ashesh.
Regards,
Sanket Mehta
Sr Software engineer
Enterprisedb
On Mon, Aug 3, 2015 at 10:49 AM, Ashesh Vashi <ashesh.vashi@enterprisedb.com> wrote:
Sanket,
Can you please review it?
--
Thanks & Regards,
Ashesh Vashi
EnterpriseDB INDIA: Enterprise PostgreSQL Company
http://www.linkedin.com/in/asheshvashi
On Sun, Aug 2, 2015 at 3:49 PM, J.F. Oster <jinfroster@mail.ru> wrote:
Hello,
Here is a small improvement about sorting in the Data editor.
Problem:
If a table has a PK or OIDs, it gets sorted by PK/OID by default.
When a user wants to sort by any other column, he has first to click
"Remove sort" in the context menu, and only then click "Sort
ascending"(descending) on column of his choice.
If he doesn't remove the default sort, he will get no effect and
probably be puzzled for the first time until guesses that he makes
ORDER BY column_pk, column_of_choice
which is totally useless.
The need to "Remove sort" each time is annoying.
Solution:
When a user chooses to sort by some column, we must discard the
default sort order.
Please see the attached patch.
Thanks.
--
Best regards,
J.F.
--
Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake
EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
--
Best regards,
J.F.
--
Best regards,
J.F.
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake
EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company