Hello friends,

I have a query that runs perfectly on MS SQL Server, but won't on ORACLE. Please, explain wether such nested queries are allowed in oracle. Example is given below, as you see - the nested query in select statement selects a max value based on field values in select statement. if max is not available, it returns null.

select A.ID, (select max(B.SOMEFIELD) from B where B.ID=A.ID) as test
from A


My query is more complicated, but this is simplified view.

Thank you.