How can i convert following plsql to tsql. B.STATUS(+)=1 doesnt work in tsql.
Select * from A,B where A.ID=B.ID(+)
WHERE B.STATUS(+)=1
this doesnt return rows in mssql because it doesnt understand B.STATUS is optional
Select * from A LEFT JOIN B ON A.ID=B.ID
WHERE B.STATUS=1
An OUTER JOIN changes to an INNER JOIN when a condition is applied to the outer table in the WHERE clause. In the ON clause, it stays as OUTER.
You need to push the predicate “in”
OR