SOCI/soci

"unknown data type with typelem" for PostgreSQL column with custom enum type

Thiesius opened this issue · 2 comments

Soci Version: 4.0.3
PostgreSQL Version: 14
libpq version: 14.2
File: statement.cpp
Line: On the screenshot

When querying data from table containing the "bad" column, an exception is thrown. State of the program at the throw location is on the screenshot. PQfsize returns 4 instead of -1 expected by the code.

The column is defined as limited_to_type generic.item_type. generic is also different schema than limited_to_type.
The type is defined as CREATE TYPE generic.item_type AS ENUM ('val1'...);

image

Any idea how I could bypass this issue without modifying the database?

Seems like there has been some updates on the master regarding this issue since 4.0.3. I will test that and report

Seems to be working on current master.