# errors-query

> Claude/Codex skill by [@betterstackhq](https://omgskills.com/library/betterstackhq/index.md) · 4 stars · Updated 2026-10-23

Load BEFORE querying Better Stack exception or error-pattern data with SQL - exception counts, trends, first/last occurrence, affected users, raw stack traces. Contains instructions for querying errors/exceptions.

## Install

```sh
git clone https://github.com/BetterStackHQ/claude-plugin /tmp/claude-plugin && ln -s /tmp/claude-plugin/skills/errors-query ~/.claude/skills/errors-query
```

## From README

Querying exceptions (Errors sources) Where the query runs Better Stack runs SQL in two places, and the query text differs: Dashboard charts and chart alerts (addcharttodashboard, editchart, createchartalert): write the query as this skill shows it, with the template variables {{source}}, {{time}}, {{starttime}} and {{endtime}}. The dashboard resolves them. Chart queries always read the source's metrics collection. Ad-hoc queries (query, renderchart): there are no template variables. First call the help tool for the data type with the source ID (queryhelp for logs and spans, metricsqueryhelp for metrics, errorsqueryhelp for errors): it names the source's collections and the table to pass. Put the collection where {{source}} stands (e.g.

## Links

- HTML page: https://omgskills.com/library/betterstackhq/claude-plugin/skills/errors-query/
- GitHub: https://github.com/BetterStackHQ/claude-plugin
- Author: [@betterstackhq](https://omgskills.com/library/betterstackhq/index.md)

## More from this repo

- [chart-alerts](https://omgskills.com/library/betterstackhq/claude-plugin/skills/chart-alerts/index.md) — Guide for creating and managing Better Stack chart alerts.
   - [@betterstackhq](https://omgskills.com/library/betterstackhq/index.md) · 4 stars
- [chart-generation](https://omgskills.com/library/betterstackhq/claude-plugin/skills/chart-generation/index.md) — Complete reference for chart types, units, and settings on Better Stack dashboards.
   - [@betterstackhq](https://omgskills.com/library/betterstackhq/index.md) · 4 stars
- [chart-styling](https://omgskills.com/library/betterstackhq/claude-plugin/skills/chart-styling/index.md) — Better Stack chart styling and advanced settings reference - series colors and order, number chart coloring thresholds,...
   - [@betterstackhq](https://omgskills.com/library/betterstackhq/index.md) · 4 stars
