Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can View Designer do this ?
Message
 
To
19/04/2001 15:20:21
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00497404
Message ID:
00497546
Views:
9
If I understand your data correctly, I think the following will work (I essentially just added the sub-query stuff):
SELECT ;
  Equipinv.mfg, Equipinv.model, Equipinv.sernum, Stumaint.clsdate,;
  Stumaint.trhrs, Stumaint.drhrs, Stumaint.udrum, Stumaint.proller,;
  Stumaint.froller, Stumaint.slpring, Stumaint.brushes, Stumaint.ctlhd,;
  Stumaint.audhd;
FROM ;
  eng!equipinv ;
  INNER JOIN eng!stumaint ON Equipinv.cmaster_index = Stumaint.cmaster_index ;
WHERE ;
  stumaint.udrum = .T. AND ;
  stumaint.clsdate = ;
    (SELECT MAX(stutemp.clsdate) ;
      FROM stumaint stutemp ;
      WHERE stutemp.cmaster_index=stumaint.cmaster_index) ;
INTO ;
  CURSOR result
(If this message solved your problem, please click on the "Mark this message as the answer to the thread" hyperlink below... Thanks).

--Brad
Previous
Reply
Map
View

Click here to load this message in the networking platform