To Include All Data

  • Thread starter Thread starter zyus
  • Start date Start date
zyus said:
Hi John,

My latest value is in tbl-b...based on my example for A i will take value
in
tbl-b. same goes to D & C. For B & C i will use value in tbl-A.

FYI i use access for query & reporting. Tbl-A is a previous month data and
tbl-B is the latest month data.

When i use union query, it will create duplicate record for A. Is there
any
way i can select A,B,C,D & E without any duplicates
 
ôl!nnnn

zyus said:
Hi John,

below are my sql

SELECT tbl-sks.Acno, tbl-sks.net_bal
FROM tbl-sks INNER JOIN tbl-previousmonth ON tbl-sks.Acno =
tbl-previousmonth.Acno
UNION ALL
SELECT tbl-previousmonth.acno, tbl-previousmonth.net_Bal
FROM tbl-previousmonth LEFT JOIN tbl-sks
ON tbl-sks.Acno = tbl-previousmonth.Acno
WHERE tbl-sks.Acno IS NULL;


and the error is syntax error in from clause

Thanks
 
Back
Top