mysql 两列互转

1.mysql 一张表两列互转

UPDATE 
    tm_position as a,tm_position as b 
SET 
    a.gps_longitude = b.gps_latitude,a.gps_latitude=b.gps_longitude
WHERE a.id=b.id AND a.gps_longitude < 50 AND a.gps_longitude >0;
原文地址:https://www.cnblogs.com/rinack/p/7517451.html