SELECT i.id, i.image, it.text, i.link FROM images i INNER JOIN images_text it ON i.id = it.image_id INNER JOIN pages p ON i.page_id = p.id WHERE p.category = 'banner_photo'
Too many connections