Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Calculate field with the same conditions
Message
From
02/03/2011 15:10:36
 
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Environment versions
SQL Server:
SQL Server 2008
Application:
Web
Miscellaneous
Thread ID:
01502373
Message ID:
01502385
Views:
35
>Something like this?
>
>
>SELECT		Member.FirstName,
>		Member.LastName,
>		Details.AddDate,
>		Details.CountRecord
>FROM		Member
>Join		(
>			Select		Order.NoMember,
>					Max(Order.AddDate) as AddDate, 
>					Count(*) as CountRecord
>				FROM	Order
>				GROUP	BY Order.NoMember
>		) Details on Detais.NoMember = Member.Numero
>
>
This seems to work but the only difference is that I will not get the Member records having no orders.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform