I have two table BLINES and BPATIENT.
BPATIENT should have identical number of lines as BLINES.
In my scenario, i am missing some lines for BPATIENT. Line_Num is the column which has line numbers such as 1 2 3 4 5 ..
I need a Left Join query to find missing line_num in BPATIENT Table.
I wrote my query .. which is not working. I am not able to figure it out ..
FROM BLINES A
LEFT OUTER JOIN BPATIENT B
ON A.DOC_ID = B.DOC_ID
AND A.LINE_NUM = B.LINE_NUM
WHERE A.LINE_NUM is null