This section explains the use of stream operations to convert the results of analysis into an output stream data.
The stream operation specifies how the analysis results are to be output as stream data based on changes to the data in the output relation. A stream operation can output the following three types of tuples as stream data:
- Tuples that have been added to the output relation
- Tuples that have been deleted from the output relation
- Sets of tuples inside the output relation
- Hint
- A change to the data in the output relation means a change when the output relation is compared at two points in time. Even if a specific tuple in the output relation changes, it is not considered a change if the overall result remains the same.
- An example follows:
Figure 2-13 Example in which the relation has not changed
![[Figure]](figure/zc021300.gif)
- In the figure, as a tuple (Stock B, 1.1) is added to the output relation (Stock A, 0.9) at time t2, the output relation changes to (Stock A, 0.9)(Stock B, 1.1) at time t3. Then, at time t4, (Stock A, 0.9) disappears, but (Stock A, 0.9) is generated as another tuple at the same time, and therefore the content of the output relation remains the same as (Stock A, 0.9)(Stock B, 1.1). In this case, the output relation is considered not to have changed at time t4.
- Organization of this section
- 2.4.1 Stream operation types
- 2.4.2 Stream operation examples