Quality rule - query 8
- Last UpdatedFeb 07, 2025
- 1 minute read
For Interpolated mode only, the returned row with Linear wwInterpolationType will have combined qualities.
SELECT TagName, DateTime, Value, QualityDetail, OPCQuality, wwRetrievalMode, wwInterpolationType
FROM History
WHERE TagName = 'I0R5'
AND DateTime >= '2009-09-12 00:20'
AND DateTime <= '2009-09-12 00:40'
AND wwResolution = 10000
AND wwRetrievalMode = 'Interpolated'
AND wwInterpolationType = 'Linear'
If you run this query against the following sample data:
|
Tagname |
DateTime |
Resolution |
QualityDetail |
|---|---|---|---|
|
I0R5 |
2009-09-12 00:07 |
2 |
193 |
|
I0R5 |
2009-09-12 00:14 |
3 |
195 |
|
I0R5 |
2009-09-12 00:22 |
0 |
196 |
|
I0R5 |
2009-09-12 00:25 |
1 |
199 |
|
I0R5 |
2009-09-12 00:27 |
0 |
200 |
|
I0R5 |
2009-09-12 00:29 |
2 |
207 |
|
I0R5 |
2009-09-12 00:33 |
3 |
215 |
|
I0R5 |
2009-09-12 00:36 |
0 |
216 |
|
I0R5 |
2009-09-12 00:39 |
1 |
219 |
The results are:
|
Tagname |
DateTime |
Value |
QualityDetail |
OPC |
wwRetrieval |
wwInter |
|---|---|---|---|---|---|---|
|
I0R5 |
2009-09-12 00:20 |
0.8 |
192 |
192 |
Interpolated |
Linear |
|
I0R5 |
2009-09-12 00:30 |
2.3 |
192 |
192 |
Interpolated |
Linear |
|
I0R5 |
2009-09-12 00:40 |
1.0 |
192 |
219 |
Interpolated |
Linear |
Note: Cyclic, Full, Delta, Maximum, Minimum, and BestFit do not have combined qualities; therefore, the rules are not applied to these modes..