How do I add the two values from stats which I get from these query?
Check the addcoltotals command.
Check the addcoltotals command.
where should I use the addcoltotals command? After |stats max?
Yes. The columns have to exist before addcoltotals can add them.