pgadmin-org / pgadmin4

pgAdmin is the most popular and feature rich Open Source administration and development platform for PostgreSQL, the most advanced Open Source database in the world.
https://www.pgadmin.org
Other
2.53k stars 656 forks source link

The slider of the query result view is useless in case of long tables (RM #3269) #1780

Closed dpage closed 3 days ago

dpage commented 6 years ago

Issue migrated from Redmine: https://redmine.postgresql.org/issues/3269 Originally created by bassi bass at 2018-04-11 09:17:35 UTC.

If I use the Slider on the right side of the result vies they would jump up if new lines are loaded. Then I have grab the slider again to navigate in the result set. This is very irritating if I navigate within long results. Going to the end of a long result with this way is nearly impossible.

dpage commented 6 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-1 Originally created by Dave Page at 2018-04-27 10:49:32 UTC.

For a future release, if we can get the final row count without loading all the rows, then we could potentially adjust the scrollbar to reflect the correct number of rows from the outset. However, if we can't do this without loading all rows, then we'll leave it as-is.

However, a workaround if desired is to create a conflg_local.py file alongside pgAdmin's config.py file, and in there add a line such as:

ON_DEMAND_RECORD_COUNT = 10000000

This will make the batch load size 10M rows which in most sane cases will cause all rows to be loaded at once, so the scrollbar will be sized correctly, though of course that may effectively slow down result retrieval. Obviously the value used here can be adjusted to suit preferences.

dpage commented 6 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-2 Originally created by Dave Page at 2018-04-27 10:50:18 UTC.

Redmine ticket header update:

Name Old Value New Value
Sprint changed Ready
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-3 Originally created by Aditya Toshniwal at 2020-03-06 11:54:21 UTC.

Redmine ticket header update:

Name Old Value New Value
Sprint changed Ready squash
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-4 Originally created by Nagesh Dhope at 2020-04-17 06:19:29 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Nagesh Dhope
Status changed New In Progress
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-5 Originally created by Nagesh Dhope at 2020-04-21 08:00:31 UTC.

Applied in changeset commit:8d4f3c07c777d57cf0e89af8ed06b0e7886f37ab.

Redmine ticket header update:

Name Old Value New Value
Done Ratio changed 0 90
Status changed In Progress In Testing
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-6 Originally created by Akshay Joshi at 2020-04-21 08:02:48 UTC.

Redmine ticket header update:

Name Old Value New Value
Fixed Version changed 4.21
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-7 Originally created by Akshay Joshi at 2020-04-21 08:03:19 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Nagesh Dhope
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-8 Originally created by Pradip Parkale at 2020-04-21 10:43:46 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Pradip Parkale
dpage commented 4 years ago

Image migrated from Redmine: https://redmine.postgresql.org/attachments/download/4845 Originally created by Pradip Parkale at 2020-04-22 06:55:50 UTC.

Screenshot_2020-04-22_at_10.50.01_AM.png

Filename: Screenshot_2020-04-22_at_10.50.01_AM.png

dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-10 Originally created by Pradip Parkale at 2020-04-22 07:16:29 UTC.

Hi Nagesh,

I have tested this on the latest snapshot build https://www.postgresql.org/ftp/pgadmin/pgadmin4/snapshots/2020-04-22/.

I created a table with 1000100 entries and hit select * from table then few rows get loaded and others were showing 'loading', I waited around an hour but no new row was loaded.

Please see the attached screenshot.

Redmine ticket header update:

Name Old Value New Value
Status changed In Testing New
Attachment added Screenshot 2020-04-22 at 10.50.01 AM.png
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-11 Originally created by Pradip Parkale at 2020-04-22 07:25:51 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Pradip Parkale
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-12 Originally created by Nagesh Dhope at 2020-04-22 07:28:41 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Nagesh Dhope
Status changed New In Progress
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-13 Originally created by Nagesh Dhope at 2020-04-22 13:17:27 UTC.

Applied in changeset commit:5e91ed2bb1123b7bc7a96ee783d50b8b8b2f716b.

Redmine ticket header update:

Name Old Value New Value
Status changed In Progress In Testing
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-14 Originally created by Akshay Joshi at 2020-04-22 13:21:32 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Nagesh Dhope
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-15 Originally created by Shubham Agarwal at 2020-04-23 05:57:42 UTC.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Shubham Agarwal
dpage commented 4 years ago

Image migrated from Redmine: https://redmine.postgresql.org/attachments/download/4853 Originally created by Shubham Agarwal at 2020-04-23 06:00:15 UTC.

Screenshot_2020-04-23_at_11.27.24_AM.png

Filename: Screenshot_2020-04-23_at_11.27.24_AM.png

dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-17 Originally created by Shubham Agarwal at 2020-04-23 06:00:38 UTC.

The values are not getting loaded after 2000 rows. Attached is the screenshot.

Redmine ticket header update:

Name Old Value New Value
Assigned To changed Shubham Agarwal Nagesh Dhope
Status changed In Testing In Progress
Attachment added Screenshot 2020-04-23 at 11.27.24 AM.png
dpage commented 4 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-18 Originally created by Akshay Joshi at 2020-04-24 05:48:42 UTC.

Reverting patch for RM #3269.

We observed that sometimes the browser is getting hanged and sometimes the ViewData grid is getting disappear. We suspect its due to the number of rows to update on the slick grid after fetching next of rows.

Redmine ticket header update:

Name Old Value New Value
Sprint changed squash Ready
Done Ratio changed 90 0
Fixed Version changed 4.21
Assigned To changed Nagesh Dhope
Status changed In Progress New
dpage commented 2 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-19 Originally created by Akshay Joshi at 2022-05-11 09:54:24 UTC.

Need to discuss.

Redmine ticket header update:

Name Old Value New Value
Sprint changed Ready
dpage commented 2 years ago

Comment migrated from Redmine: https://redmine.postgresql.org/issues/3269#note-20 Originally created by Nikhil Mohite at 2022-05-13 11:24:01 UTC.

We can try something like this: https://codepen.io/ykadosh/pen/ZdxeYY We can insert the total number of rows as dummy and load data based on the scroll.

Redmine ticket header update:

Name Old Value New Value
Sprint changed Ready
adityatoshniwal commented 2 months ago

We've decided to replace infinite scrolling with pagination for better UX.

pravesh-sharma commented 1 month ago

Feature implemented and is working fine. Tested on snapshot build.

Env: OS - macOS 14.7 (Sonoma) Mode - Desktop

anilsahoo20 commented 6 days ago

If we run queries like this, it always shows page no. 2 of 1.

Screenshot 2024-11-05 at 3 13 44 PM

If we make empty the first control of Showing rows, and clicks the apply button, it shows the message tab and if we click on cancel edit button it closes the control and shows Showing rows: to 201

Screenshot 2024-11-05 at 3 34 49 PM Screenshot 2024-11-05 at 3 35 09 PM Screenshot 2024-11-05 at 3 35 16 PM

If we enter some value and did not click on apply and clicked cancel edit button, it still shows Showing rows: 100 of 201, but the data output tab shows data from 1 to 201.

Screenshot 2024-11-05 at 3 43 35 PM

If we give the valid starting row no. and invalid end row no, still the error is on start row no. Note: this comes only when end row no is greater than 0. if 0 is given then it shows error

Screenshot 2024-11-05 at 3 48 49 PM Screenshot 2024-11-05 at 3 51 36 PM

These controls take - as valid input, as there is no error border, but if we enter alphabets or any other special character then it shows red error border.

Screenshot 2024-11-05 at 3 52 58 PM Screenshot 2024-11-05 at 3 56 43 PM
pravesh-sharma commented 5 days ago

I found one more issue

If I mark a row for deletion or add a new row and then change the page and then return, the marking or new row is gone and the bottom status bar still shows Changes staged. Attached recording:

https://github.com/user-attachments/assets/17b6db06-21e0-4e5c-99d0-ff93c6822f11

anilsahoo20 commented 3 days ago
  1. Previous page and first page are still active when page and rows are 0. Image

  2. First clicked on edit of the page icon and then selected all rows by clicking the top left corner box and the css looks distorted. Already all the rows are selected, but still it is showing Select All Rows Image

  3. I have shared a video on slack.

  4. If I give from row 5 and apply, then after some forward and next pages, if we see the Showing rows are 1 to 197 for page 1 and 198 to 201 for page 2. You can see the same in the end of the video.

adityatoshniwal commented 3 days ago
  1. If I give from row 5 and apply, then after some forward and next pages, if we see the Showing rows are 1 to 197 for page 1 and 198 to 201 for page 2. You can see the same in the end of the video.

For this, you need to check the docs once. I've added details on how it is calculated. New page nos are calc based on new page size.

anilsahoo20 commented 3 days ago

Tested and verified with latest source code. Environment: macOs 13.5.1