DATABASE ERROR:
SELECT p.*,
                       u.nickname as author, u.login, u.is_deleted,
                       b.allow_who as blog_allow_who,
                       b.seolink as bloglink,
                       b.title as blog_title,
                       b.owner as owner , up.imageurl, img.fileurl
                FROM cms_blog_posts p
				INNER JOIN cms_blogs b ON b.id = p.blog_id
				LEFT JOIN cms_users u ON u.id = p.user_id
				LEFT JOIN cms_user_profiles up ON up.user_id = u.id
LEFT JOIN cms_upload_images img ON img.target_id = p.id AND img.target = 'blog_post' AND img.component = 'blogs'

                WHERE p.published = 1 AND b.owner = 'user'
				       AND (b.allow_who = 'all')
 AND (p.allow_who = 'all')

                GROUP BY p.id
                ORDER BY p.pubdate DESC
LIMIT 0, 10
Incorrect key file for table '/tmp/#sql_7aec_0.MYI'; try to repair it