I have arranged a result with Dynamic PIVOT into Temp Table, which looks like:
--------------------------------------------------------
| City | 2018-07-14 | 2018-07-15 | 2018-07-16 |
--------------------------------------------------------
| Satara | 3 | 9 | 1 |
| Maharashtra | 0 | 4 | 1 |
| Ghatkopar | 10 | 1 | 1 |
--------------------------------------------------------
Expected output :
----------------------------------------------------------------------
| City | 2018-07-14 | 2018-07-15 | 2018-07-16 | Total |
---------------------------------------------------------------------
| Satara | 3 | 9 | 1 | 13 |
| Maharashtra | 0 | 4 | 1 | 5 |
| Ghatkopar | 10 | 1 | 1 | 12 |
----------------------------------------------------------------------
NULL | 13 | 14 | 3 | 30 |
--------------------------------------------------------------------
That last three columns is date which is dynamic Today's Date - 3 Days