Jan Walraven
DevOps



Categories:
  • Arduino (2)
  • CSS (3)
  • Docker (11)
  • ESXi (1)
  • Git (4)
  • Google Cloud (3)
  • Javascript (6)
  • Kubernetes (4)
  • Linux (36)
  • Mac (7)
  • Magento (4)
  • Mysql (14)
  • PHP (9)
  • Zend framework 2 (9)
  • Posted on February 22, 2012

    Example intro

    Copy data from tb1 to tb2

    
    INSERT INTO tb2 SELECT * FROM tb1
    

    Copy specific columns from tb1 to tb2

    
    INSERT INTO tb2 (col1,col2) SELECT col11,col12 FROM tb1
    

    Copy specific columns from tb1 to tb2 with WHERE statement

    
    INSERT INTO tb2 (col1,col2) SELECT col11,col12 FROM tb1 WHERE col11 > 1