- 
                Notifications
    You must be signed in to change notification settings 
- Fork 705
Popularize Tables
        Yi Wang edited this page Oct 19, 2018 
        ·
        6 revisions
      
    https://stackoverflow.com/questions/18049444/hive-select-into
create table people1990 as select * from people where dob_year=1990 - 
https://dev.mysql.com/doc/connector-python/en/connector-python-examples.html Save results into a local CSV file and upload it to Hive. Doesn't seems scalable. 
- 
https://stackoverflow.com/a/26777130 - Load the data in a relational database like mysql.
- Import data from relational database to HDFS using Apache Sqoop.
- Create a Hive table as parquet format
- Load the data from HDFS to Hive table.
 
https://docs.databricks.com/spark/latest/spark-sql/language-manual/insert.html
Similar to Hive
https://dev.mysql.com/doc/refman/8.0/en/ansi-diff-select-into-table.html
INSERT INTO tbl_temp2 (fld_id)
   SELECT tbl_temp1.fld_order_id
   FROM tbl_temp1 WHERE tbl_temp1.fld_order_id > 100;