sql - Why am I getting duplicate records for this query? I am performing a Left Outer Join -
i entering following query below , getting duplicate values. thought if did left outer join wouldn't that. want t0.
data 2 of 3 columns. 1 column want t1.
data related customer name customer code. seems want populate record twice.
here code attempting use:
select t0.cardcode ,t1.cardname ,t0.state crd1 t0 left outer join ocrd t1 on t0.cardcode=t1.cardcode
try using distinct keyword.
select distinct t0.cardcode ,t1.cardname ,t0.state crd1 t0 left outer join ocrd t1 on t0.cardcode=t1.cardcode
Comments
Post a Comment