Match historian data to the batch

Connect PI historian evidence to a Seal batch record. Work through a 60-minute phase, reproduce its temperature average and make ten minutes of unusable evidence visible.

21.6 °C describes only 50 of the 60 minutes

Fictional batch B-105, vessel V-4, hold occurrence H-01, 12 September 2026, 09:00–10:00 UTC. These are normalized intervals for an agreed step-held receiving calculation, not a native PI response or a default PI calculation. Each interval includes its start and excludes its end. An explicit bad status starts at 09:30; the absence of frequent archived points alone would not establish a gap.

Scroll across to see every column →

Worked temperature intervals — B-105 / V-4 / H-01; all times UTC
IntervalMinutesValue (°C)Usable for this calculationContribution (°C·min)
09:00–09:101020Yes200
09:10–09:302024Yes480
09:30–09:4010UnavailableNo: explicit bad statusExcluded
09:40–10:002020Yes400

Download the worked data (CSV)

  1. Usable duration

    10 + 20 + 20 = 50 minutes

    Report the excluded 09:30–09:40 interval alongside the full 60-minute window.

  2. Mean of usable time

    (200 + 480 + 400) / 50 = 21.6 °C

    The mean of the three usable interval values is 21.333… °C. It gives equal weight to unequal durations.

  3. Coverage

    50 / 60 × 100 = 83.333…%

    This is our duration-coverage calculation, not an assumed PI PercentGood response or acceptance threshold.

  4. Decision

    Full-window temperature evidence remains incomplete

    The observed maximum is 24 °C in usable evidence. Neither the mean nor the maximum establishes what occurred during the excluded interval.

Choose the read that answers the question.

PI Web API provides recorded, interpolated and summary reads. The vendor workbook demonstrates startTime/endTime, a maxCount limit for recorded data and an interval for interpolation. It also shows Timestamp, Value, Good, Questionable and Substituted in a response. Preserve those fields when they are returned; selecting only timestamps and values would discard quality context.

Start with a read-only request for one resolved stream and one closed phase window. Save the source server, point or AF attribute path, resolved WebId, absolute UTC bounds, action, all explicit query parameters and retrieval time. Resolve the same displayed tag against both the source system and equipment: V-4 temperature and V-5 temperature are different observations.

Choose recorded data for inspecting archived events, an interpolated series for an explicitly chosen reporting grid, or a summary for a specified statistic. An hourly reporting grid is a calculation choice. It does not show that the historian acquired a physical measurement on every hour. For a summary, record the installed service’s calculation basis, boundary treatment and bad-value behavior rather than relying on an omitted default.

Source: OSIsoft PI World 2020: Using PI Web API, exercises 2–3.

Separate missing acquisition from compressed history.

An archive can legitimately contain irregularly spaced events. Do not label every long interval between recorded events as missing data, and do not assume the last good value remains trustworthy indefinitely. Use the source status transitions, acquisition diagnostics and the approved interpolation or maximum-age rule to establish which time is usable.

The fictional example explicitly adopts a step-held rule: each listed value applies until the next listed boundary. At 09:30 a bad status interrupts that rule; at 09:40 usable data resumes. A linearly interpolated calculation would be a different model and must be reproduced separately. Never draw a continuous line across a bad interval simply to obtain 100% coverage.

Save the 1,080 °C·min numerator and the 50-minute usable denominator with 21.6 °C. Dividing by the full hour would produce 18 °C and would effectively give the missing interval a zero contribution. Store the excluded duration and reason so a reviewer can distinguish a partial statistic from a complete phase assessment.

Make neighboring phases and late corrections reproducible.

Resolve the batch-to-equipment relationship and the source occurrence ID before extracting data. In this example the review window is [09:00, 10:00) UTC. A source read may include values outside these bounds to construct a boundary estimate. Retain those supporting values but do not count them as observations belonging to a neighboring phase.

Use an absolute interval for a closed batch, not a moving expression such as the last hour. Record the source timezone and offset before converting. Around a daylight-saving clock change, the same local time can occur twice; a timezone-free timestamp leaves the association unresolved.

A later query can return corrected source values or a revised phase end. Retain the earlier extract, the new retrieval, and the changed source/query evidence. A new retrieval time alone does not imply a new process observation. Recalculate affected summaries as a visible revision and leave the previous review linked to the evidence it actually used.

Prove the retrieval finished before calculating coverage.

Before running a scheduled collection, demonstrate read access through the site-approved network route and record which service account can read the chosen stream. A cloud Script needs a reachable, approved interface or transferred file; configuring a private plant address does not create connectivity.

For the first run, inspect the complete source response, limits, continuation behavior and per-item failures. If a response reaches its requested cap, establish whether more data remains using the installed interface’s documented continuation or a verified subdivision of the window. Do not infer completeness from HTTP 200 or from a plausible first page.

Keep a collection receipt containing query identity, extract revision, expected streams/windows, retrieved counts, completion evidence and source File reference. Distinguish retrieval complete from evidence adequate: all four intervals in this example can arrive successfully while the ten-minute quality gap still prevents a full-window conclusion.

Put the calculation beside the batch decision.

A practical Seal template links a batch to equipment, a phase occurrence and an extract File. Keep the observed value, unit, statistic, usable duration, full duration and calculation revision in typed fields, with separate fields for retrieval state and review outcome. This gives the team a concise batch view while preserving the underlying evidence.

Configure the mapping Script to update its imported fields and keep operator explanations and review decisions under their assigned ownership. A useful first delivery is one complete phase package whose source intervals, result and unresolved gap can be inspected together. Increase the tag population and cadence only after this package reconciles at the intended volume.

Vendor references for this workflow

  • OSIsoft PI World 2020: Using PI Web API, exercises 2–3. Vendor training illustrates recorded, interpolated and summary reads and timestamp/value/quality fields. Use the installed PI Web API help for version-specific parameters; the interval arithmetic below is our fictional receiving example.

Test it with your data.

Use these cases to agree and test the connection’s behaviour. They are proposed acceptance checks, not completed tests or automatic connector features.

Equal-weight averaging gives the wrong result

Use the four intervals above and average only the three usable interval values.

Expected behaviour
Detect 21.333… °C as inconsistent with the agreed duration-weighted calculation. Expect 21.6 °C over 50 minutes, with ten excluded minutes.
Evidence to keep
The interval rows, 1,080 °C·min numerator, both duration denominators and calculation rule.

A plausible response stops at the query limit

Limit a source read so that a closed phase needs more than one response or subwindow.

Expected behaviour
Keep retrieval incomplete until the entire requested population reconciles. Do not label the uncollected remainder a process-quality gap.
Evidence to keep
The request cap, continuation or subdivision receipts, overlap handling and final window reconciliation.

Later source correction changes a reviewed summary

Repeat the same absolute query after the historian owner corrects one source value.

Expected behaviour
Preserve both extracts and identify the changed content. Create a summary revision requiring the configured review; do not rewrite the earlier evidence.
Evidence to keep
Original and corrected source Files, query identity, comparison and affected review references.

An interpolated grid hides the status interval

Request ten-minute reporting points for the same phase, with a bad interval between good observations.

Expected behaviour
Retain source quality and apply the verified interpolation rule. Do not infer complete acquisition from regularly spaced returned timestamps.
Evidence to keep
Recorded/status evidence, interpolation settings and a comparison of the usable durations.
More checks for this connection
  • Test the same point at the phase end and at the next phase start without double attribution.
  • Resolve two identical tag labels on different equipment and prove the intended source identity.
  • Exercise an ambiguous local timestamp at a daylight-saving change.
  • Compare a source summary only after matching its weighting, boundaries and quality rules.

Apply this to your records

Use a closed phase from your historian. Record the actual read and observed results; the worked numbers are a comparison exercise.

Download the blank working review

Write your working notes here

Notes stay in this tab and are not submitted. Download them before leaving to keep a copy. Use record references to identify your evidence.

Record server, point/attribute and WebId, equipment, batch and occurrence IDs, source timezone, absolute bounds and boundary convention.

Attach the request and complete source response. Record action, limits, continuation, quality fields and how the requested population was reconciled.

Record interpolation/weighting, quality and maximum-age rules, included and excluded intervals, numerator, usable/full durations, unit and reported precision. Explain any difference from the historian-side result.

Record the capped-read, bad-status and revised-source exercises. Identify receipts, retained revisions and the actual receiving result.

Identify the decision this metric supports, unresolved periods, governing criteria, reviewer and next action. Separate retrieval completion from evidence adequacy.

Unanswered sections remain marked ‘Not recorded’ in the download.

Evidence needed to finish

Finish when another reviewer can reproduce the metric from retained evidence and can see every unresolved interval and retrieval. Do not convert a partial summary into a full-phase conclusion.

Before you connect

Can an 83.333% coverage figure be accepted?

The example defines no acceptance threshold. A reviewer needs the intended decision, applicable process criteria and the significance of the excluded interval. A useful partial summary remains distinct from evidence that the whole phase met its criteria.

Should Seal store every historian point as an entity?

Start with a phase record, typed review metrics and linked extracts. Choose a point-level model only when the intended analysis requires it and the actual query volume and delivery rate have been tested.

Check your system’s connection options.

Confirm the installed version, available exports and permissions. These pages cover the source interface and link to setup instructions.

For configuration: Seal Scripts and local-file collection.

Start with one export.

Bring the source evidence and the records it needs to connect to. For this workflow, a useful starting pack is:

  • One closed phase with source batch/equipment/occurrence IDs and unambiguous UTC boundaries.
  • The exact read request, point metadata and complete response including quality and continuation information.
  • A historian-side comparison and one known bad-status interval or incomplete retrieval to exercise recovery.
Discuss this connection