handle two way lookup