If you’re getting an error that reads something like “Could not convert string ‘…’ to INT64” when using the generate_subscripts()
function in DuckDB, it appears that your second argument is a string, when it should be an integer.
DuckDB’s generate_subscripts()
function accepts two arguments; the array as the first argument, and the dimension as the second argument. The second argument must be INT64
(or be able to be implicitly converted to that type). Passing the wrong data type as the second argument can cause the above error to occur.
To fix this issue, make sure that the second argument is compatible with INT64
.