pgo icon indicating copy to clipboard operation
pgo copied to clipboard

Add support for array columns

Open maxdeviant opened this issue 2 years ago • 3 comments

While working in gleam-lang/packages I noticed that gleam_pgo doesn't seem to support array columns in Postgres.

maxdeviant avatar May 29 '23 17:05 maxdeviant

Good idea! Thanks

lpil avatar May 29 '23 18:05 lpil

Array columns can be added easily, coercion is already working. I have a column as params int[] in postgres, and all I had to do (to trick pgo) was to put the value with dynamic.unsafe_coerce(dynamic.from([1, 2, 3])), and it's working! I think we could add array: fn (List(a)) -> Value in pgo module directly.

ghivert avatar May 04 '24 12:05 ghivert

Excellent! Let's do it

lpil avatar May 04 '24 12:05 lpil