SELECT ab.* FROM ad_banners ab, ads a, ads_cats_rel ac WHERE a.enabled=1 AND ab.enabled=1 AND ab.id NOT IN (0, 1603, 1604, 1605, 1606, 1607, 1608, 1609, 1610, 1611, 1612, 1628, 1629, 1630, 1631, 1632, 1633, 1634, 1635, 1636, 1637, 1638, 1639, 2355, 2356, 2357, 2358, 2359, 2360, 1551, 1552, 1553, 1554, 1555, 1556, 1557, 1558, 1559, 1560, 1561, 1562, 1502, 1503, 1505, 1506, 1507, 1508, 1509, 1510, 1511, 1512, 1513, 1514, 1565, 1570, 2322, 2323, 2324, 2325, 2326, 2327, 2328, 2329, 1225, 1226, 1227, 1228, 1229, 1230, 1231, 1232, 1233, 1234, 1235, 1236, 1237, 1238, 2008, 2034, 2349, 2350, 2351, 2352, 2353, 2354, 702, 703, 704, 710, 711, 712, 713, 714, 715, 499, 500, 501, 503, 504, 505, 506) AND 1=1 AND width =468 AND height=60 AND a.id=ab.ad_id AND ac.cat_id = 29 AND a.id=ac.ad_id ORDER BY rand() LIMIT 1