5、更新 pm_members 表的最后时间
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_0`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 0 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_1`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 110 = 1 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_2`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 2 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_3`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 3 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_4`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 4 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_5`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 5 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_6`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 6 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_7`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 7 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_8`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 8 AND m.plid = msg.plid;
- UPDATE `pre_ucenter_pm_members` m, (SELECT plid, dateline FROM `pre_ucenter_pm_messages_9`
- ORDER BY dateline DESC) msg SET m.lastdateline = msg.dateline WHERE m.plid % 10 = 9 AND m.plid = msg.plid;