> ## Documentation Index
> Fetch the complete documentation index at: https://docs.btsscorp.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Keyboard Shortcuts

> Essential keyboard shortcuts for efficient query development

## Overview

Koala Data Explorer includes essential keyboard shortcuts to improve your productivity when writing and executing SQL queries. The shortcuts work within the VS Code environment alongside standard VS Code shortcuts.

## Essential Shortcuts

The following shortcuts are implemented and available in Koala Data Explorer:

### Query Execution

| Action        | Windows/Linux | Mac         | Description                       |
| ------------- | ------------- | ----------- | --------------------------------- |
| Execute Query | `Ctrl+Enter`  | `Cmd+Enter` | Run entire query or selected text |
| Save Query    | `Ctrl+S`      | `Cmd+S`     | Save current query to file        |

### Editor Features

| Action               | Windows/Linux | Mac         | Description                          |
| -------------------- | ------------- | ----------- | ------------------------------------ |
| Find                 | `Ctrl+F`      | `Cmd+F`     | Find text in query                   |
| Replace              | `Ctrl+H`      | `Cmd+H`     | Find and replace text                |
| Comment/Uncomment    | `Ctrl+/`      | `Cmd+/`     | Toggle line comment                  |
| Trigger IntelliSense | `Ctrl+Space`  | `Cmd+Space` | Show autocomplete suggestions (Paid) |

### Results Management

| Action             | Windows/Linux | Mac      | Description                |
| ------------------ | ------------- | -------- | -------------------------- |
| Select All Results | `Ctrl+A`      | `Cmd+A`  | Select all rows in results |
| Copy               | `Ctrl+C`      | `Cmd+C`  | Copy selected results      |
| Clear Selection    | `Escape`      | `Escape` | Clear result selection     |

### Editor Navigation

| Action            | Shortcut      | Description                  |
| ----------------- | ------------- | ---------------------------- |
| Move Line Up/Down | `Alt+↑/↓`     | Move current line up or down |
| Duplicate Line    | `Shift+Alt+↓` | Duplicate current line below |

## Standard VS Code Shortcuts

Koala Data Explorer works within VS Code, so all standard VS Code shortcuts also apply:

### File Operations

* **New File**: `Ctrl+N` / `Cmd+N`
* **Open File**: `Ctrl+O` / `Cmd+O`
* **Save**: `Ctrl+S` / `Cmd+S`
* **Save As**: `Ctrl+Shift+S` / `Cmd+Shift+S`

### Text Editing

* **Undo**: `Ctrl+Z` / `Cmd+Z`
* **Redo**: `Ctrl+Y` / `Cmd+Y`
* **Cut**: `Ctrl+X` / `Cmd+X`
* **Copy**: `Ctrl+C` / `Cmd+C`
* **Paste**: `Ctrl+V` / `Cmd+V`
* **Select All**: `Ctrl+A` / `Cmd+A`

## Customizing Shortcuts

You can customize any shortcuts through VS Code's keyboard shortcuts settings:

1. Open Command Palette: `Ctrl+Shift+P` / `Cmd+Shift+P`
2. Type "Preferences: Open Keyboard Shortcuts"
3. Search for specific commands to modify

## Productivity Tips

### Essential Shortcuts for Koala

Focus on these key shortcuts for maximum productivity:

1. **`Ctrl+Enter` / `Cmd+Enter`** - Execute queries (most important)
2. **`Ctrl+S` / `Cmd+S`** - Save your work frequently
3. **`Ctrl+/` / `Cmd+/`** - Comment/uncomment SQL lines
4. **`Ctrl+F` / `Cmd+F`** - Find text in large queries
5. **`Escape`** - Clear result selections

### Workflow Tips

* **Partial Execution**: Select SQL text and press `Ctrl+Enter` / `Cmd+Enter` to run only the selection
* **Line Management**: Use `Alt+↑/↓` to move lines up/down when organizing queries
* **Duplicate Lines**: Use `Shift+Alt+↓` to quickly duplicate useful query patterns

## Next Steps

<CardGroup cols={2}>
  <Card title="Bind Variables" icon="variable" href="/koala/editor/bind-variables">
    Use parameters in queries
  </Card>

  <Card title="Writing Queries" icon="code" href="/koala/editor/writing-queries">
    SQL query best practices
  </Card>
</CardGroup>
