Skip to content

ALT + F5 not executing the unselected query the cursor is on or near #10109

Description

@mike-ayres

Describe the bug
With two queries separated by at least one blank line, ALT + F5 should run the query that the cursor is on. I don't remember when this last worked, but I believe it did before the fix to #9570 . (That one wouldn't run highlighted queries.)

I ran into this with 9.15 and 9.16 (just installed)

To Reproduce
Have two queries in a query window, such as below:

select 1

select 2

F5 would run both queries, and break because there are no semicolons. In the past, ALT + F5 would run the query the cursor was on or next to, so if you had the cursor on select 2, then 2 would return without error. ALT + F5 currently does nothing on 9.16.

Steps to reproduce the behavior:

  1. Open query tool
  2. type in some queries with line breaks between them.
  3. highlight one query
  4. try pressing ALT + F5

Expected behavior
selected (but not highlighted) query under the cursor will execute

Error message
No error message, the key combo does nothing.

Screenshots
Expected setting for that key combo, under Query Tool -> Keyboard shortcuts

Image

Desktop (please complete the following information):

  • OS: Windows 11
  • pgAdmin version: 9.15, 9.16
  • Mode: Desktop
  • Package type: None

Additional context

Please don't regress #9570 when addressing this issue!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions