Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem in writing SQL
Message
From
22/07/2002 03:46:41
 
 
To
22/07/2002 03:15:12
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00681016
Message ID:
00681026
Views:
13
>Sorry I think I didn't make my question clear enough...
>I am now working on the enhancement project the structure of the dbf file a kind of poor design, unfortunately I've got to remain the structure of the dbf file
>the actually structure of my maintenance.dbf file is like this
>
> ref_no ser_no c_exiry fee
> AAA 0002 2/3/02 $10
> BBB 0001 8/3/02 $20
> CCC 0002 2/4/03 $10
> DDD 0003 3/2/02 $20
>
>I write the SQL as below
>
>select maintenance.ser_no, maintenance.ref_no, max(maintenance.c_expiry),; maintenance.fee from maintenance where ser_no in;
>(select cser_no from mainboard) and fee>0 and c_expiry>
>my desired result should be as below
>
> ref_no ser_no c_exiry fee
> BBB 0001 18/3/02 $20
> DDD 0003 3/2/02 $20
>
>however because the c_expiry date in record CCC has been filter out by the condition
>c_expiry>
> ref_no ser_no c_exiry fee
> AAA 0002 2/3/02 $10<-------undesire record
> BBB 0001 8/3/02 $20
> DDD 0003 3/2/02 $20
>how can I solve the problem....thank you for your help..
Hi,
Please make clear why AAAA record is undesirable and should not come in the final result.
Hitendra
Previous
Reply
Map
View

Click here to load this message in the networking platform