# Install clickhouse-sql-parser with Homebrew

Writing clickhouse sql parser in pure Go. Version 0.5.1 via Homebrew; verified 2026-04-21.

## Install

```sh
sudo av install brew:clickhouse-sql-parser
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install clickhouse-sql-parser
```

  Evidence: local Homebrew formula metadata

## Package facts

- **Package key:** brew:clickhouse-sql-parser
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/clickhouse-sql-parser>
- **Version:** 0.5.1
- **Source summary:** Writing clickhouse sql parser in pure Go
- **Homepage:** <https://github.com/AfterShip/clickhouse-sql-parser>
- **Repository:** <https://github.com/AfterShip/clickhouse-sql-parser>
- **Upstream docs:** <https://github.com/AfterShip/clickhouse-sql-parser#readme>
- **License:** MIT
- **Source archive:** <https://github.com/AfterShip/clickhouse-sql-parser/archive/refs/tags/v0.5.1.tar.gz>
- **Last updated:** 2026-04-21T06:24:49Z
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- clickhouse-sql-parser (cli)
- clickhouse-sql-parser (alias)

## Build dependencies

- go

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 0.5.1
- Package-manager updated: 2026-04-21
- Local data: ok
- Upstream repository: https://github.com/AfterShip/clickhouse-sql-parser
- Upstream latest detected: v0.5.1 (current)
## Project history and usage

ClickHouse SQL Parser is a Go library and CLI for parsing ClickHouse SQL into an AST and formatting or beautifying ClickHouse queries.

### Project history

The official README says the project aims to build a ClickHouse SQL parser in Go and notes inspiration from memefish, a Go SQL parser for Cloud Spanner.

### Adoption history

The tool is available both as a Go install target and as a Homebrew formula, matching common distribution paths for Go developer CLIs.

### How it is used

Developers import the parser package in Go code or run `clickhouse-sql-parser` from the shell to parse SQL strings, format SQL, beautify SQL, or read queries from files.

### Why package nerds care

It is interesting to package managers because it bridges library and CLI packaging: the same Go module can be consumed by applications and installed as a standalone formatter/parser executable.

### Related projects

- The README explicitly cites memefish as an inspiration and targets the ClickHouse SQL dialect.

### Sources

- Official GitHub README: project goal, features, Go library examples, CLI installation, and usage examples.


## Security Notes

broad file, network, media, or database tool signal.

- **Geiger risk:** blue / medium
- broad file, network, media, or database tool signal

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** clickhouse-sql-parser
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable


## Related links

- [Source-control packages](https://www.automicvault.com/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Secret-risk packages](https://www.automicvault.com/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [go](https://www.automicvault.com/pkg/brew/go/) - Build dependency declared by Homebrew.
- [h2](https://www.automicvault.com/pkg/brew/h2/) - Shares av.db curated category or tags: cli, data, sql.
- [prestodb](https://www.automicvault.com/pkg/brew/prestodb/) - Shares av.db curated category or tags: cli, data, sql.
- [trino](https://www.automicvault.com/pkg/brew/trino/) - Shares av.db curated category or tags: cli, data, sql.
- [burrow](https://www.automicvault.com/pkg/brew/burrow/) - Shares av.db curated category or tags: cli, data, go.
- [cayley](https://www.automicvault.com/pkg/brew/cayley/) - Shares av.db curated category or tags: cli, data, go.
- [conduit](https://www.automicvault.com/pkg/brew/conduit/) - Shares av.db curated category or tags: cli, data, go.
- [iceberg-cli](https://www.automicvault.com/pkg/brew/iceberg-cli/) - Shares av.db curated category or tags: cli, data, go.
- [ioctl](https://www.automicvault.com/pkg/brew/ioctl/) - Shares av.db curated category or tags: cli, data, go.
- [lazysql](https://www.automicvault.com/pkg/brew/lazysql/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, data, go, sql.
- [oj](https://www.automicvault.com/pkg/brew/oj/) - Both packages touch the same language runtime or ecosystem. Shared terms: cli, data, go, parser.

## Combined YAML source

View the package source record on GitHub. [combined/clickhouse-sql-parser.yml](https://github.com/automic-vault/db/blob/main/combined/clickhouse-sql-parser.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- cross-ecosystem install command graph
