kuzu
kuzu copied to clipboard
Unsupported casting function from UNION to UNION.
Creating new nodes with a UNION type is not possible.
CREATE NODE TABLE tab(id SERIAL, un UNION(a INT32), PRIMARY KEY(id));
CREATE (t:tab {un: union_value(a := 1)});
This gives the error message
RuntimeError: Conversion exception: Unsupported casting function from UNION to UNION.
This seems to be because union_value(a := 1)
creates a UNION(a INT64)
Edit: The main problem is that union_value
isn't sufficient to define the type of the union, and we don't have good casting from different union types.