Dan,

 

Your WHERE clause does not link T4 to any of the other tables, thus each row
found in T1, T2 and T3 get associated with a row for every T4.

 

Emmitt Dove

Manager, DairyPak Business Systems

Evergreen Packaging, Inc.

[EMAIL PROTECTED]

[EMAIL PROTECTED]

(203) 643-8022

 

From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Dan
Sent: Monday, April 14, 2008 10:16 AM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Help with Create View

 

Good morning,
  I must still be drowsy from the weekend.  Where am I going wrong in this
create view.  I am ending up with way more data than I need.  The f_name,
L_name is repeated for every piece of equipment found in t4 then starts over
with the next f_name, l_name

create view clubnewv as select t1.f_name, t1.l_name, t1.badr,
t1.badrst,t2.jobid,
t2.jobadd1,t2.jobadd2,t3.sa_invoice_number,t4.sa_EQMT_kind from ARmain t1,
jobsite t2, sa_main t3, sa_detail t4 where t1.custno = t2.custno and
t2.jobid = t3.jobid and t3.sa_status <> "closed" and t2.jobid in (select
jobid from joblist 
where finalbill  between .vsavstrtdate and .vsavenddate)








Dan Champion 

 Service Department Manager
Vredevoogd Heating & Cooling
    Grandville, MI. 49418     
        616-534-8271 x 14
    

Reply via email to