# `Ch.Error`
[🔗](https://github.com/plausible/ch/blob/v0.8.2/lib/ch/error.ex#L1)

Error struct wrapping ClickHouse error responses.

# `t`

```elixir
@type t() :: %Ch.Error{
  __exception__: true,
  code: non_neg_integer() | nil,
  message: String.t()
}
```

The Error struct. See [ErrorCodes.cpp](https://github.com/ClickHouse/ClickHouse/blob/5ce532e6f930c6f7fbdfa98b0327cc007df894b7/src/Common/ErrorCodes.cpp#) for possible errors.

## Fields

  * `:code` - The ClickHouse numeric error code
  * `:message` - The error message returned by the server

---

*Consult [api-reference.md](api-reference.md) for complete listing*
