I think we cannot do this directly by specify the particular target columns in the insert query because it is dealing with the files.
And the syntax is syntax: INSERT OVERWRITE TABLE tablename1 [PARTITION (partcol1=val1, partcol2=val2 ...)] select_statement1 FROM from_statement; INSERT INTO TABLE tablename1 [PARTITION (partcol1=val1, partcol2=val2 ...)] select_statement1 FROM from_statement; -Chinna Rao Lalam -----Original Message----- From: 曹坤 [mailto:[email protected]] Sent: Wednesday, August 03, 2011 8:30 AM To: [email protected] Subject: how to insert data to specified columns Hello : Any idea about how to insert data to specified columns? In a way like follow : INSERT OVERWRITE TABLE target_table PARTITION (day='20110803' , hour='11') (target_table_column1,target_table_column2) SELECT source_table_column1, source_table_column2 FROM source_table; -- Best wishs!
