Let consider the below table structure

```
Product Year Month Price
A 2011 01 23
A 2011 02 34
```

.......

.....

```
A 2011 12 54
B 2011 01 13
B 2011 02 12
```

.......

.....

B 2011 12 20

From this table i need to aggregate the value for every 3 months ie..,

```
Product Year Month Price
A 2011 1-3 45
A 2011 4-6 23
A 2011 7-9 45
A 2011 10-12 16
```

A 2012 1-3 12 ....... .......

Can anybody tell me how to do this calculation using sql query... Thanks in Advance !!!