How to get a value from a database based on a value from the same row, but different column - pls help!!!!!!!!!!

@Paul Krzyz - Thank you, Paul for taking the time to explain in detail how to fix Kumar’s problem. Although I’m not having trouble with the same problem, it gave me information that could be helpful.
Thanks again