mysql從一張表查出數據存到另外一張表和inner join的用法

INSERT INTO test_table_public(class, name, geography)  SELECT class, name, geography FROM test_table WHERE id >= 137181 AND id <= 137214;

SELECT class, name, geography FROM test_table WHERE id >= 137181 AND id <= 137214;

SELECT t1.class, t1.name, t2.geography, t1.test FROM test_table t1 INNER JOIN test_table_public t2 ON t1.name = t2.name;
相關文章
相關標籤/搜索