I am trying to migrate an existing Postgresql database table that uses a field in Postgresql as text[]. However when using the Bun.BaseModel and tags this does defaults to either bytea, __varchar, or __text in the Migration of the table.
I've tried the following to get the generation correct but bun seems to only want to recognize usage from varchar. Any way this can be supported properly for Postgresql Data types in the dialect?
I am trying to migrate an existing Postgresql database table that uses a field in Postgresql as
text[]
. However when using the Bun.BaseModel and tags this does defaults to eitherbytea
,__varchar
, or__text
in the Migration of the table.I've traced this back to this mapping here: https://github.com/uptrace/bun/blob/master/schema/sqltype.go#L45
I've tried the following to get the generation correct but bun seems to only want to recognize usage from varchar. Any way this can be supported properly for Postgresql Data types in the dialect?
https://github.com/uptrace/bun/blob/master/dialect/pgdialect/sqltype.go#L32