clickhouse-elixir / clickhouse_ecto

Ecto adapter for ClickHouse database
Apache License 2.0
64 stars 37 forks source link

Fix a bug: modify/3 uses wrong alter action #10

Closed llxff closed 5 years ago

llxff commented 5 years ago

Hi!

I found that modify/3 generates wrong query. For example such code

alter(table(:table)) do
  modify :column, :integer
end

generates such query ALTER TABLE "table" ALTER COLUMN "column" Int32;, but according to documentation it should be ALTER TABLE "table" MODIFY COLUMN "column" Int32;.

santaux commented 5 years ago

Cool! Got it