SELECT t1.id AS cat_id, t1.id_cat_redirect AS cat_id_redirect, t1.url_pt AS cat_url, t2.url_pt AS cat_url_redirect FROM xtra_cat AS t1 LEFT JOIN xtra_cat AS t2 ON t2.id=t1.id_cat_redirect LEFT JOIN data_cat_country AS t3 ON (t3.id_cat=t1.id AND t3.id_country='30' AND t3.id_language='pt') WHERE LOWER(t1.url_pt)='alugar-apartamentos' || LOWER(t3.url_cat)='alugar-apartamentos' Array ( [cat_id] => 52 [cat_id_redirect] => 2 [cat_url] => alugar-apartamentos [cat_url_redirect] => alugar-apartamentos )