I need to addtotals to exclude one of the columns created as a result of chart command.
P.S: I need exclusion, not inclusion.
If the name of fields that you want to include is finite and is known, use @adonio's answer. If they are dynamic but you know which one to exclude, try this workaround,
your current search | rename field_to_exclude as dont_field_to_exclude * as include_* | addcoltotals include_* | rename dont_field_to_exclude as field_to_exclude include_* as *
you can use addcoltotals with fields and specify only the fields that you want. example here:
index = _internal | stats sum(bytes) as totalBytes avg(bytes) as avgBytes by host | addcoltotals totalBytes