neisbut / Npgsql.Bulk

Helper for performing COPY (bulk insert and update) operation easily, using Entity Framework + Npgsql.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Would it be possible to support Enum columns?

trajekolus opened this issue · comments

The GetNpgsqlType method in NpgsqlBulkUploader returns a NpgsqlDbType.
The list of Npgsql DB types doesn't include an enum type, although PostgreSQL does support enums.
https://www.npgsql.org/doc/api/NpgsqlTypes.NpgsqlDbType.html

So it seems obvious why Npgsql.Bulk doesn't support Enum columns at the moment.
But I'm wondering if there is a way Enum columns might be supported nonetheless?

Hi @advnodequest , sorry, don't get the point? What setup do you have? Any exception you face?

If you mean clr enums then they are supported, in test project Enum is used like this:

    [Column("type")]
    public AddressType? Type { get; set; }

Closed due to inactivity.