Cmd chord passes through in any mode, so Cmd+Enter still runs the query.
Turn it on in Settings > Editor > Vim mode, which is also the only way to turn it off: there is no :set. A badge next to the editor shows the current mode.


Mode badge in the SQL editor
Modes
gi puts you back where you last left insert.
Move the cursor
Characters
Words
Lines
Find a character
Sentences and paragraphs
Counts work:
3w moves three words, 5j moves five lines down.
Edit
2d3w deletes six words. 3yy yanks three lines. 5>> indents five lines.
Yank, delete, and change all write to the system clipboard.
Text objects
Use afterd, c, y, or in visual mode.
ciw rewrites the current word. da" removes a quoted string and its trailing space. yip copies the current paragraph.
Paste
In visual mode,
p and P replace the selection with the register.
Registers
Prefix with"{a-z} to pick a register.
"ayy stores a line in a. "ap pastes it back later.
Marks
Marks shift when you insert or delete text before them.
Search
The pattern is a literal, case-sensitive substring, not a regex. Searches wrap around.
Repeat and undo
5. repeats the last change five times.
Macros
A macro that calls itself stops after 50 rounds.
Control keys
Outside insert mode, aCtrl letter goes to vim, never to the editor’s own binding:
Any other
Ctrl letter does nothing. That includes Ctrl+E and Ctrl+Y, which like zt, zz and zb are read and discarded: the view scrolls only to follow the cursor. Ctrl+Space still opens completions, and Ctrl+Tab and Ctrl+Shift+Tab still move focus to the next and previous control. A shortcut of Ctrl and a letter assigned in Settings > Keyboard does not fire from the SQL editor outside insert mode.
In insert and replace mode, vim takes these and leaves every other Ctrl combination to the editor:
Ctrl+H is the editor’s own backspace in insert mode, so it deletes a selection the way Delete does. In replace mode vim takes it, and like Delete it restores the character you overwrote.
Option keys
AnOption chord outside insert mode is read as the character it types. On a keyboard layout where Option types [ or @, such as German, those work as vim commands, and a character vim has no use for, such as the non-breaking space from Option+Space, does nothing. A dead key such as Option+E on the US layout does nothing outside insert mode.
In insert mode, Option types as usual. In replace mode, the character it types overwrites the one under the cursor.
Visual mode
Motions extend the selection. Then:
Indent and outdent work in normal mode only (
>>, <<, >{m}, <{m}).
Insert mode
Esc or Ctrl+[ goes back to normal mode. Apart from the insert-mode control keys, what you type goes to the editor as usual.
Command line
/ and ? are search. Every other : command is parsed and ignored, :wq, :x and :set among them. :10 does not jump to line 10 either; use 10G or 10gg.
Delete and Ctrl+H erase the last character of the command. The arrow keys and the other Ctrl letters do nothing while you type one.
