SELECT e.ID_Expert,p.ID_Profile,a.City,c.Initials,r.Rootsite FROM experts e JOIN profiles p on p.FK_Experts = e.ID_Expert JOIN addresses a on a.ID_Address = p.FK_Addresses JOIN branches b on p.FK_Branches = b.ID_Branch JOIN countries c on p.FK_Language = c.ID_Country JOIN rootsites r ON(p.FK_Rootsite = r.ID_Rootsite) WHERE e.Lastname LIKE '' AND a.City LIKE 'Warszawa%' AND b.Branch LIKE 'LAW' AND p.Online = 1