MySQL server has gone away
SELECT `banners`.`iBanner`, `banners`.`sFile`, `banners`.`sLink`, `banners`.`iType`, `banners`.`iWidth`, `banners`.`iHeight`, `banners`.`sColor`, `banners`.`iMax`, `banners`.`iStatus`, `banners`.`sText` FROM `sc8_pl_banners` AS `banners` LEFT JOIN `sc8_pl_banners_stats` AS `banners_stats` ON (`banners`.`iBanner` = `banners_stats`.`iBanner` ) LEFT JOIN `sc8_pl_banners_pages` AS `banners_pages` ON( `banners`.`iBanner` = `banners_pages`.`iBanner` ) WHERE ( `iStatus` = '1' ) AND `iType` = 0 AND ( ( `banners`.`iMax` = '0' ) OR ( `banners_stats`.`iViews` < `banners`.`iMax` ) ) AND ( ( `banners`.`iMaxClicks` = '0' ) OR ( `banners_stats`.`iClicks` < `banners`.`iMaxClicks` ) ) AND ( ( `banners`.`iTimeFrom` IS NULL ) OR ( `banners`.`iTimeFrom` = '0' ) OR ( `banners`.`iTimeFrom` < UNIX_TIMESTAMP() ) ) AND ( ( `banners`.`iTimeTo` IS NULL ) OR ( `banners`.`iTimeTo` = '0' ) OR ( `banners`.`iTimeTo` > UNIX_TIMESTAMP() ) ) AND ( `banners_pages`.`iPage` = 212 ) ORDER BY `iPosition`, `iBanner`