Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Group by question
Message
From
11/07/2005 19:24:06
 
 
To
All
General information
Forum:
ASP.NET
Category:
Databases
Title:
Group by question
Miscellaneous
Thread ID:
01031432
Message ID:
01031432
Views:
73
lets say you have a stock file that has :
stock_id, date, price and you want to find for each stock the
minimum price and the date on which that price occurred.

you can't use
select stock_id, date, min(price)
from stock
group by stock_id

because sql requires you to use every non aggregate field
in the group by. any ideas?
Oh this is in SqlServer and Postgresql

Mike
Next
Reply
Map
View

Click here to load this message in the networking platform