We have a query for loading the data into a table using a INSERT-SELECT query directly on another table(s) as shown below
INSERT OVERWRITE TABLE <table1>
SELECT * FROM <table2> t2
WHERE <some-conditions>;
Similarly how can load a table with complex data types? How can I let couple of/some of columns in my SELECT query contribute for a complex data typed column? Am i clear?
Schema of the table1 is
TABLE (col1 INT, col2 STRING, col3 ARRAY<STRING>)
Note: Loading from a file to such tables is possible, but I just wanna try whether I can load using above INSERT-SELECT query fashion. Appreciate your interest.
INSERT-SELECTquery.CASTof UDFs which generate new types of data, e.g.SPLITwill create array<string> from string.SPLIT?