Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need Help with SQL Statement
Message
From
20/09/1997 11:40:31
 
 
To
20/09/1997 10:25:12
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00050724
Message ID:
00050906
Views:
41
>>
>>SELECT * FROM Quotes WHERE ;
>> DTOC(Date)+Customer IN ;
>> (SELECT MAX(DTOC(Date))+Customer FROM Quotes)
>
>Yes, but you still have two SQL-SELECTs (even if one is embeded). Still, yours should be faster than 2 separate SELECTs.
>
I left off the GROUP BY in the above statement. Sorry. It was late. I'll use that as an excuse.
Anyway it should have been

>SELECT * FROM Quotes WHERE ;
> DTOC(Date)+Customer IN ;
> (SELECT MAX(DTOC(Date))+Customer FROM Quotes GROUP BY Customer)

I don't know about the speed of nested selects vs. seperate selects.
But as you said I think the single statment would be faster.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform