data-peek
Features

Results Viewer

View and interact with query results

Results Viewer

The results viewer displays your query output in a powerful, interactive table.

Results Table

Column Headers

  • Click a column header to sort by that column
  • Click again to reverse sort order
  • Shift+Click another header to add a second sort level
  • Data type badge shows the column type

Cells

  • Click any cell to copy its value
  • Hover to see full content for truncated values
  • Right-click for context menu options

Data Type Formatting

TypeDisplay
TextPlain text (truncated if long)
NumbersRight-aligned, formatted
DatesISO format with time
BooleanCheckbox icon (✓ or ✗)
JSONCollapsed preview, expandable
NULLGray NULL badge

Smart Sort Bar

Multi-column sorting is managed by a sort bar above the grid. Each sort level is a chip showing its priority, column, and direction — drag chips to reorder priority, click the arrow to flip direction, and click Clear to remove all sorts.

Type-Aware Sort Modes

Beyond ascending/descending, each column type offers extra modes (press M on a focused chip to cycle):

TypeModes
TextAlphabetic, Natural (item2 before item10), By length
NumbersNumeric, Absolute value
DatesChronological, By month, By weekday, Time of day
BooleanTrue first / false first

Every type also has a Shuffle mode for a random sample order — click the dice to reroll.

Sort Presets

The sort bar’s picker includes one-click presets: Newest first, Oldest first, A → Z, Z → A, Largest first, Smallest first, and Shuffle. Each preset picks the first matching column by type.

Chip Keyboard Controls

With a chip focused:

KeyAction
Space / EnterToggle direction
MCycle sort mode
BackspaceRemove the sort
Cmd+← / Cmd+→Move chip (change priority)

A hover toggle on each chip controls whether NULLs sort first or last.

Keyboard Navigation

The grid is fully keyboard-navigable — click a cell (or run a query) and drive with the keyboard:

KeyAction
Move between cells
Home / EndFirst / last column in the row
Cmd+Home / Cmd+EndTop-left / bottom-right cell
PageUp / PageDownJump 20 rows
Cmd+CCopy the focused cell
EnterOpen the cell inspector
EscapeClose the inspector

Focus position is preserved across sorting, filtering, and pagination.

Cell Inspector

Press Enter on a focused cell to open the inspector — a docked panel below the grid showing the full value without truncation:

  • Position and type - Row/column position, column name, data type badge, and a NULL badge when applicable
  • Value details - Kind (string, number, date, JSON, …), character count, and byte size
  • Formatted display - JSON pretty-printed with syntax coloring
  • Copy - Copy the exact value
  • Follow - For foreign key cells, jump to the referenced record

Arrow buttons (and while open) scrub the inspector across neighboring cells, so you can walk a column of JSON payloads without reopening it.

JSON Viewer

For JSON/JSONB columns, data-peek provides a rich viewer:

Inline Preview

  • Small JSON values show inline
  • Larger values show a preview with ”…” indicator
  • Click to expand

Expanded View

When expanded, JSON shows:

  • Collapsible tree structure
  • Color-coded values by type:
    • 🟢 Strings in green
    • 🔵 Numbers in blue
    • 🟡 Booleans in yellow
    • ⚪ Null in gray
  • Copy buttons at each level

Settings

Configure JSON display in Settings:

  • Expand JSON by Default - Auto-expand JSON columns
  • Default Expansion Depth - How many levels to expand (1-5)

Pagination

Results are paginated for performance:

  • Page size options: 25, 50, 100, 250, 500 rows
  • Navigation buttons: First, Previous, Next, Last
  • Page indicator shows current page and total

Changing Page Size

  1. Click the page size dropdown
  2. Select desired size
  3. Results reload with new page size

Smaller page sizes make navigation faster, especially for tables with many columns or JSON data.

Toolbar Actions

Query Metrics

The toolbar shows:

  • Row count - Total rows returned
  • Duration - Query execution time (ms)

Export

Click Export to download results:

FormatDescription
CSVComma-separated values
JSONJSON array of objects

See Export for more details.

Edit Mode

Click Edit to enable inline editing. See Inline Editing for details.

Execution Plan

Click Explain to view the query execution plan. See Query Plans for details.

Context Menu

Right-click any cell for:

OptionDescription
Copy CellCopy the cell value
Copy Row as JSONCopy entire row as JSON
Copy Row as CSVCopy the row with a header line
Copy ColumnCopy all values in column
Filter by ValueAdd WHERE clause for this value

In edit mode, the row menu also offers Duplicate Row and Delete Row. The context menu works on every row, including virtualized rows deep in large result sets.

Foreign Key Navigation

If a column is a foreign key:

  1. The cell shows a link icon
  2. Cmd+Click (macOS) or Ctrl+Click (Windows/Linux) to navigate
  3. Opens a new tab with the referenced record

Foreign key navigation requires the referenced table to be accessible in the current connection.

Performance Tips

For large result sets:

  1. Use LIMIT - Always limit your queries
  2. Select specific columns - Avoid SELECT * when possible
  3. Use pagination - Navigate page by page
  4. Filter early - Add WHERE clauses to reduce data

On this page