If You want a column or a value or a single where condition data then you can use sql sub query instead of writing complex join etc.
Ex 1. Select name,gender,(Select top 1 schoolname from abc where xyzid = 1) from xyz where id=1
Ex 2. Select name,gender from xyz where id=(select max(id) from xyz)
Ex 3. Select abcxyz.Name from (select id,Name from xyz
where id=(select max(id) from xyz) ) abcxyz;
You can learn from
[^here]