Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for pagination #57

Open
mvrozanti opened this issue Dec 26, 2019 · 3 comments
Open

Add support for pagination #57

mvrozanti opened this issue Dec 26, 2019 · 3 comments

Comments

@mvrozanti
Copy link

Hi I love this

I was hoping pagination could be added but I'm not sure how that would work. Maybe select count(*) from table before the actual query? It would make every query slower though. Is this a wanted feature?

Thanks for this tool anyways!

@hasankhan
Copy link
Owner

Hi Marcelo

Thank you for your comments.

Currently pagination is up to the author of the query to control i.e. by using limit and top clause. Since it is possible to redirect the output of the program to file, modifying the query of the user to add a limit clause can give undesirable results.

@mvrozanti
Copy link
Author

mvrozanti commented Dec 27, 2019

Understandable. What if it was an option? I ask this because while it's always desirable to get the full query response when scripting, we don't always (most likely never) want it on interactive mode. The option could even have an optional setting for the row count of each page that default to terminal height or something. I'm gonna fiddle a bit with this

@hasankhan
Copy link
Owner

Sure, that seems reasonable. Feel free to send a pull request if you'd like to contribute this feature.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants