Skip to content
New issue

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

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

Already on GitHub? # to your account

Add selected text as parameter in query shortcuts #14893

Closed
mejiaej opened this issue Mar 27, 2021 · 0 comments · Fixed by #14894
Closed

Add selected text as parameter in query shortcuts #14893

mejiaej opened this issue Mar 27, 2021 · 0 comments · Fixed by #14894
Labels
Area - Query Editor Enhancement Request for new features or functionality Triage: Needed

Comments

@mejiaej
Copy link
Contributor

mejiaej commented Mar 27, 2021

Is your feature request related to a problem? Please describe.
I really like the query shortcut feature, I just think that adding the selected text at the end of the query is not enough. For example, one query that I run a lot is select * from table order by 1 desc. I use that query to see recent records that I've added to a table. Currently, there is no way to set up a query shortcut that inserts the text selection anywhere in the query.

Currently just the select * from shortcut works. From the feature description, I get the feeling that it is meant to be used with procedures, but it also accepts queries. I just want to make the query execution a bit more flexible.

Describe the solution or feature you'd like
I'd like to have a keyword, for example {arg}, that will get replaced by the selected text whenever I use the shortcut query.

Describe alternatives you've considered
An alternative can be creating an sp that receives the table name as a parameter. But that might not be efficient if you deal with many client databases.

Additional context
query-shortcut

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Area - Query Editor Enhancement Request for new features or functionality Triage: Needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants