Re: total showing wrong in pivot table at the time of expanding all column
It looks like your second dimensions has some duplication in it. You see that when you expand 20 you get two rows, both with 1,020. Usually in Qlikview is "smart" about this and realizes the duplication, but depending on your data model and your expression this may not happen.
I would start by investigating your data model.
Post an example of you QVW and we can take a look.