RawTotal Mode

Retrieves the arithmetic total (sum) of sampled values for each interval.

Value

The sum of the good quality values of all raw samples in the interval. All bad quality samples are ignored.

Quality

Percent good is always 100, even if the interval does not contain any raw samples or it contains only bad quality samples.

Example: Calculating the Raw Total

The following example demonstrates that only good quality samples are included in the sum. Perform the fol- lowing query on the same data set as that in the Count example above:

select timestamp, value, quality from ihrawdata where samplingmode=calculated and calculationmode=rawtotal and timestamp >= '29-Mar-2002 13:30' and timestamp <= '29-Mar-2002 14:30' and tagname = counttag and intervalmilliseconds = 10M                                                                                                                                                                                                                                             
Time StampValueQuality
29-Mar-200213:40:00.0000.00100.00
29-Mar-200213:50:00.0000.00100.00
29-Mar-200214:00:00.0022.00100.00
29-Mar-200214:10:00.0000.00100.00
29-Mar-200214:20:00.0000.00100.00
29-Mar-200214:30:00.0004.00100.00

If the same start and end time are used, but the time span is treated as a single interval, then all values are added together:

select timestamp, value, quality from ihrawdata where samplingmode=calculated and calculationmode=rawtotal and timestamp >= '29-Mar-2002 13:30' and timestamp <= '29-Mar-2002 14:30' and tagname = counttag 
and numberofsamples=1
Time StampValueQuality
29-Mar-200214:30:00.00026.00100.00

Even though the time span covers all raw samples, only the two good quality samples are used in the calculation: 26 = 22 + 4

Anticipated Usage

RawTotal mode is useful for calculating an accurate total when a sufficient number of raw samples are collected. Note that unlike ihTotal, this is a simple sum with no assumption that the values are rate values.