Created search for other tables, updated select query