Philky101
asked on
need to add col from third table of join
i need to add a col from the third table I need ad.IARCC9
it's not displaying this col. i
select ItQty#,IhDocd,ItPRT# from pklib.Fileout1 a
ad.IARCC9 from astdta.audia
b.CtCom#= a.ItCom# and
b.CtCtr# = ' ' and
b.CtPrt# =a.ItPrt#
join astdta.Audia ad
on ad.IAprt# = a.ItPrt#
where ad.IARCC9 > ''
order by ad.IARCC9
it's not displaying this col. i
select ItQty#,IhDocd,ItPRT# from pklib.Fileout1 a
ad.IARCC9 from astdta.audia
b.CtCom#= a.ItCom# and
b.CtCtr# = ' ' and
b.CtPrt# =a.ItPrt#
join astdta.Audia ad
on ad.IAprt# = a.ItPrt#
where ad.IARCC9 > ''
order by ad.IARCC9
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
Can You show your working query with 2 tables and the structure of the 3rd table?
The query is unclear, but try this
select ItQty#,IhDocd,ItPRT#, b.IARCC9 from pklib.Fileout1 a
astdta.audia b, third_table c
where c.CtCom#= a.ItCom#
and c.CtCtr# = ' '
and c.CtPrt# =a.ItPrt#
and b.IAprt# = a.ItPrt#
and b.IARCC9 > ''
order by b.IARCC9
This question is a duplicate question. See here:
https://www.experts-exchange.com/questions/28226631/Need-to-add-a-3rd-table-to-this-join.html
https://www.experts-exchange.com/questions/28226631/Need-to-add-a-3rd-table-to-this-join.html
ASKER