Changelog

View Source

0.7.0 (2026-01-13)

0.6.2 (2026-01-03)

  • added support for multipart/form-data in queries: https://github.com/plausible/ch/pull/290 -- which allows bypassing URL length limits sometimes imposed by reverse proxies when sending queries with many parameters.

    ⚠️ This is currently opt-in per query ⚠️

    Global support for the entire connection pool is planned for a future release.

    Usage

    Pass multipart: true in the options list for Ch.query/4

    # Example usage
    Ch.query(pool, "SELECT {a:String}, {b:String}", %{"a" => "A", "b" => "B"}, multipart: true)

    <details> <summary>View raw request format reference</summary>

    POST / HTTP/1.1
    content-length: 387
    host: localhost:8123
    user-agent: ch/0.6.2-dev
    x-clickhouse-format: RowBinaryWithNamesAndTypes
    content-type: multipart/form-data; boundary="ChFormBoundaryZZlfchKTcd8ToWjEvn66i3lAxNJ_T9dw"
    
    --ChFormBoundaryZZlfchKTcd8ToWjEvn66i3lAxNJ_T9dw
    content-disposition: form-data; name="param_a"
    
    A
    --ChFormBoundaryZZlfchKTcd8ToWjEvn66i3lAxNJ_T9dw
    content-disposition: form-data; name="param_b"
    
    B
    --ChFormBoundaryZZlfchKTcd8ToWjEvn66i3lAxNJ_T9dw
    content-disposition: form-data; name="query"
    
    select {a:String}, {b:String}
    --ChFormBoundaryZZlfchKTcd8ToWjEvn66i3lAxNJ_T9dw--

    </details>

0.6.1 (2025-12-04)

0.6.0 (2025-11-26)

  • added automatic decoding to Ch.stream/4 when using RowBinaryWithNamesAndTypes format: https://github.com/plausible/ch/pull/277.

    Previously, this function returned raw bytes.

    To restore the previous behavior (raw bytes/no automatic decoding), pass decode: false in the options (fourth argument).

    Example of required change to preserve the previous behavior

      # before, no decoding by default
      DBConnection.run(pool, fn conn ->
        conn
        |> Ch.stream("select number from numbers(10)")
        |> Enum.into([])
      end)
    
      # after, to keep the same behaviour add `decode: false` option
      DBConnection.run(pool, fn conn ->
        conn
        |> Ch.stream("select number from numbers(10)", _params = %{}, decode: false)
        |> Enum.into([])
      end)

    Queries using other explicit formats like CSVWithNames are unaffected and can remain as they are.

    Examples of unaffected queries

    DBConnection.run(pool, fn conn ->
      conn
      |> Ch.stream("select number from numbers(10) format CSVWithNames")
      |> Enum.into([])
    end)
    
    DBConnection.run(pool, fn conn ->
      conn
      |> Ch.stream("select number from numbers(10)", _params = %{}, format: "CSVWithNames")
      |> Enum.into([])
    end)

0.5.7 (2025-11-26)

0.5.6 (2025-08-26)

0.5.5 (2025-08-26)

0.5.4 (2025-07-22)

0.5.2 (2025-07-21)

0.5.1 (2025-07-20)

0.5.0 (2025-07-17)

0.4.1 (2025-07-07)

0.4.0 (2025-06-19)

  • restrict to Ecto v3.13

0.3.4 (2025-07-07)

0.3.3 (2025-06-19)

  • restrict to Ecto v3.12

0.3.2 (2025-02-25)

0.3.1 (2025-02-08)

0.3.0 (2025-02-03)

0.2.10 (2025-02-03)

0.2.9 (2024-11-04)

0.2.8 (2024-09-06)

0.2.7 (2024-08-15)

0.2.6 (2024-05-30)

0.2.5 (2024-03-05)

0.2.4 (2024-01-29)

0.2.3 (2024-01-29)

0.2.2 (2023-12-23)

0.2.1 (2023-08-22)

0.2.0 (2023-07-28)

0.1.14 (2023-05-24)

  • simplify types, again...

0.1.13 (2023-05-24)

0.1.12 (2023-05-24)

0.1.11 (2023-05-19)

0.1.10 (2023-05-05)

0.1.9 (2023-05-02)

  • relax deps versions

0.1.8 (2023-05-01)

  • fix varint encoding

0.1.7 (2023-04-24)

  • support RowBinaryWithNamesAndTypes

0.1.6 (2023-04-24)

  • add Map(K,V) support in Ch Ecto type

0.1.5 (2023-04-23)

  • fix query param encoding like Array(Date)
  • add more types support in Ch Ecto type: tuples, ipv4, ipv6, geo

0.1.4 (2023-04-23)

  • actually support negative Enum values

0.1.3 (2023-04-23)

  • support negative Enum values, fix Enum16 encoding

0.1.2 (2023-04-23)

  • support Enum8 and Enum16 encoding

0.1.1 (2023-04-23)

  • cleanup published docs