Thread: FW: UI Addition Request. View Data > View BOTTOM 100 Rows

FW: UI Addition Request. View Data > View BOTTOM 100 Rows

From
"Matt Janssen"
Date:
From: Dave Page [mailto:dpage@pgadmin.org]
Sent: Thursday, August 12, 2010 3:21 PM
>On Thu, Aug 12, 2010 at 5:40 PM, Matt Janssen <matt@luggagepros.com> wrote:
>> Presently pgAdmin tables have a right-click context menu option "View
Data >
>> View Top 100 Rows".
>
>> More often than wanting to see the oldest data, we want to view the
newest
>> data. I propose an addition or change that allows for "View Bottom 100
>> Rows." This option would mimic the existing functionality, except that
the
>> sort order would be descending.
>>
>> Thoughts? I apologize if I'm bothering the wrong people on this.
>
>"Top" just means the first 100 returned by an unordered select query.
>They're actually in a completely arbitrary order, as that's how
>Postgres stores them, so "bottom" doesn't really make any sense. We
>don't make any attempt to order, as we have no idea what makes sense
>for any particular table - you can specify your own ordering in the
>filter/sort dialog of course.

Not to argue since I'm pretty novice with pgAdmin, but every time I open a
table with "View Top 100 Rows" the filter/sort options are already set to
PRIMARY KEY Ascending. Can we offer the reverse behavior?

Matt
matt@luggagepros.com


Re: FW: UI Addition Request. View Data > View BOTTOM 100 Rows

From
Dave Page
Date:
On Thu, Aug 12, 2010 at 11:08 PM, Matt Janssen <matt@luggagepros.com> wrote:
>>"Top" just means the first 100 returned by an unordered select query.
>>They're actually in a completely arbitrary order, as that's how
>>Postgres stores them, so "bottom" doesn't really make any sense. We
>>don't make any attempt to order, as we have no idea what makes sense
>>for any particular table - you can specify your own ordering in the
>>filter/sort dialog of course.
>
> Not to argue since I'm pretty novice with pgAdmin, but every time I open a
> table with "View Top 100 Rows" the filter/sort options are already set to
> PRIMARY KEY Ascending. Can we offer the reverse behavior?

Hmm, that must have been snuck in when I wasn't looking :-p

I guess we could offer that in reverse.


--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise Postgres Company

Re: FW: UI Addition Request. View Data > View BOTTOM 100 Rows

From
Guillaume Lelarge
Date:
Le 13/08/2010 02:07, Dave Page a écrit :
> On Thu, Aug 12, 2010 at 11:08 PM, Matt Janssen <matt@luggagepros.com> wrote:
>>> "Top" just means the first 100 returned by an unordered select query.
>>> They're actually in a completely arbitrary order, as that's how
>>> Postgres stores them, so "bottom" doesn't really make any sense. We
>>> don't make any attempt to order, as we have no idea what makes sense
>>> for any particular table - you can specify your own ordering in the
>>> filter/sort dialog of course.
>>
>> Not to argue since I'm pretty novice with pgAdmin, but every time I open a
>> table with "View Top 100 Rows" the filter/sort options are already set to
>> PRIMARY KEY Ascending. Can we offer the reverse behavior?
>
> Hmm, that must have been snuck in when I wasn't looking :-p
>
> I guess we could offer that in reverse.
>

Steffen Kuhn worked on a patch for this request. I commited it tonight.
See
http://git.postgresql.org/gitweb?p=pgadmin3.git;a=commit;h=527e2972bfff8cb8f16db6155980760c6810496b
for the actual patch. It adds a "View Last X lines" menu item everywhere
there is a "View Top X lines".

Thanks for the request, Matt. And thanks for the patch, Steffen.


--
Guillaume
 http://www.postgresql.fr
 http://dalibo.com