...
Code Block |
---|
-- Create table word_count_table_snapshot_result from word_count_table CREATE TABLE word_count_table_snapshot_result LIKE word_count_table; -- Read snapshot 5 from word_table and write data to word_count_table_snapshot_result -- in batch mode INSERT INTO word_count_table_snapshot_result SELECT word, count(*) FROM word_table /*+ OPTIONS('scan.snapshot-id'='5') */ GROUP BY word; -- Compare the data in word_count_table_snapshot_result with -- snapshot 7 in word_count_table and get the diffs SELECT * FROM word_count_table_snapshot_result as L FULL OUTER JOIN word_count_table /*+ OPTIONS('scan.snapshot-id'='7') */ as R ON L.word=R.word where L.word IS NULL OR R.word IS NULL OR L.cnt != R.cnt; |
Public Interfaces
Briefly list any new interfaces that will be introduced as part of this proposal or any existing interfaces that will be removed or changed. The purpose of this section is to concisely call out the public contract that will come along with this feature.
Proposed Changes
Describe the new thing you want to do in appropriate detail. This may be fairly extensive and have large subsections of its own. Or it may be a few sentences. Use judgement based on the scope of the change.
Compatibility, Deprecation, and Migration Plan
- What impact (if any) will there be on existing users?
- If we are changing behavior how will we phase out the older behavior?
- If we need special migration tools, describe them here.
- When will we remove the existing behavior?
Test Plan
Describe in few sentences how the PIP will be tested. We are mostly interested in system tests (since unit-tests are specific to implementation details). How will we know that the implementation works as expected? How will we know nothing broke?
Rejected Alternatives
...
In addition to the above data validation, users can also debug their jobs. For example, users can modify and submit a new job which will read Snapshot 5 of word_table and product results in a new table. Then they can compare the data with Snapshot 7 in word_count_table to check whether the new job meets their expectations.
4. Users can also correct data based on table and data lineages. Suppose that users want to correct data for table1 from Snapshot 4, and recompute data for downstream tables.
draw.io Diagram | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
a) Full data correction
b) Increment data correction