I've a table that contains weekly statistical infos.
Society - Week - Year - Data AAA Inc - 1 - 2014 - 10250 AAA Inc - 2 - 2014 - 5235 BBB Inc - 2 - 2014 - 3210 ...
Over this table i need to perform some aggregate functions (group by Society and Year and Sum data for example). For the most frequent of this i wanna create a View.
Society - Year - Data Sum AAA Inc - 2014 - 15485 BBB Inc - 2014 - 3210
Than over this view i need to not only select data (with filters and ordering) but also to perform other aggregate functions (for example the Max(Data) for the AAA Society).
My questions are: - Can this approac improve performance? How much? - Is possible to add some index to view to improve some operations?
Thanks a lot!