Closed elise-prequel closed 2 months ago
Hi @elise-prequel, I just checked your reproduction with the latest version of go-duckdb. The following test succeeds.
func TestUnsupportedType(t *testing.T) {
db := openDB(t)
_, err := db.Exec(`CREATE SCHEMA test_schema`)
require.NoError(t, err)
_, err = db.Exec(`
CREATE OR REPLACE VIEW test_schema.test_table AS
SELECT md5(CAST(range AS TEXT)) as id FROM range(10)`)
require.NoError(t, err)
res, err := db.Query(`
SELECT column_name AS Col1, data_type AS Col2
FROM information_schema.columns
WHERE LOWER(table_schema) = LOWER('test_schema')`)
require.NoError(t, err)
type row struct {
Col1 string
Col2 string
}
for res.Next() {
var r row
err = res.Scan(&r.Col1, &r.Col2)
require.NoError(t, err)
expected := row{Col1: "id", Col2: "VARCHAR"}
require.Equal(t, expected, r)
}
}
Please feel free to reopen this issue with a detailed reproduction if the error continues to reproduce for you.
Thank you so much @taniabogatsch !
Hi! I am running DuckDB compiled against (commit hash
21475f18837bb1b213ccc891bf8c32d8f1872b9f
) which is the present head.If I run the following SQL to create a table:
And the following to read:
Iterating rows fails with
unsupported type: 17
. It is similar to https://github.com/marcboeker/go-duckdb/issues/172 except the types in my table don't matter, and I think type 17 is the newUHUGEINT
.