|
»Forumlar »SE ? Core Labs
»Tüm Özel Mesajları Silme
https://seditio.com.tr/eski1/forums.php?m=posts&q=1656 |
| Author: Kaan, Posted: 2011-11-14 01:54 GMT. |
|
Clean the private messages On popular sites the count of private messages can go high, it's often the second biggest SQL table after the posts in forums. So to ... - Delete ALL the PM older than 1 year (including the archives). - Delete the PM older than 6 month and not archived (yet read and still in the inbox). - Delete the PM older than 3 month and not read by the recipient. Run this with phpMyAdmin, tab "SQL" : : ysql]DELETE FROM sed_pm WHERE pm_date < UNIX_TIMESTAMP(NOW()) - 86400 * 365; DELETE FROM sed_pm WHERE pm_date < UNIX_TIMESTAMP(NOW()) - 86400 * 180 AND pm_state=1; DELETE FROM sed_pm WHERE pm_date < UNIX_TIMESTAMP(NOW()) - 86400 * 90 AND pm_state=0; OPTIMIZE TABLE sed_pm; 1. 365 g?nden eski Ar?ivlenmi? ?zel mesajlar? silme 2. 180 g?nden eski Okunmu? ve ar?ivlenmi? ?zel mesajlar? silme 3. 90 g?nden eski okunmam?? ?zel mesajlar? silme Kodlar? ister tek tek isterseniz hepsini birlikte phpmyadmin sayfan?zdan import ediniz. |
| Powered by Seditio | Print version |