asked on
select LOC_CODE, LOC_STAT, from M_LOC where comp_Code = 'A1' and Whse_code = '8' and loc_code like '28-%'
28-11-01 A
28-11-02 A
28-11-03 A
28-11-04 A
28-11-05 A
select LOC_CODE, Cust_code from C_LOC where comp_Code = 'A1' and Whse_code = '8' and loc_code like '28-%'
28-11-01 BVFTOR
28-11-03 BVFTOR
select
M.LOC_CODE,
C.CUST_CODE
from M_LOC M
LEFT OUTER JOIN C_LOC C on M.COMP_CODE = C.COMP_CODE and M.WHSE_CODE = C.WHSE_CODE and M.LOC_CODE = C.LOC_CODE
where M.comp_Code = 'A1' and M.Whse_code = '8' and M.loc_STAT = 'A'
and M.loc_code like '28-%'
28-11-01 BVFTOR
28-11-03 BVFTOR
select
M.LOC_CODE,
C.CUST_CODE
from M_LOC M
LEFT OUTER JOIN C_LOC C on (c.COMP_CODE = m.COMP_CODE and c.WHSE_CODE = m.WHSE_CODE and c.LOC_CODE = m.LOC_CODE)
where M.comp_Code = 'A1' and M.Whse_code = '8' and M.loc_STAT = 'A'
and M.loc_code like '28-%'
Oracle is an object-relational database management system. It supports a large number of languages and application development frameworks. Its primary languages are SQL, PL/SQL and Java, but it also includes support for C and C++. Oracle also has its own enterprise modules and application server software.
TRUSTED BY
ASKER
I am showing you only the top 5 rows of 10,000+
the null records are there, they are just at the bottom.
I added a Order by LOC_CODE and the output is correct.