You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2022/10/26 12:23:13 UTC

[GitHub] [flink-table-store] LadyForest commented on a diff in pull request #333: [FLINK-29760] Introduce snapshots metadata table

LadyForest commented on code in PR #333:
URL: https://github.com/apache/flink-table-store/pull/333#discussion_r1005607235


##########
docs/content/docs/development/query-table.md:
##########
@@ -90,3 +90,22 @@ SELECT * FROM orders WHERE order_id=29495;
 
 SELECT * FROM orders WHERE catalog_id=1025 OR order_id=29495;
 ```
+
+## Snapshots Table
+
+You can query the snapshot history information of the table through Flink SQL.
+
+```sql
+SELECT * FROM MyTable$snapshots;
+
++--------------+------------+-----------------+-------------------+--------------+-------------------------+
+|  snapshot_id |  schema_id |     commit_user | commit_identifier |  commit_kind |             commit_time |
++--------------+------------+-----------------+-------------------+--------------+-------------------------+
+|            2 |          0 | 7ca4cd28-98e... |                 2 |       APPEND | 2022-10-26 11:44:15.600 |
+|            1 |          0 | 870062aa-3e9... |                 1 |       APPEND | 2022-10-26 11:44:15.148 |
++--------------+------------+-----------------+-------------------+--------------+-------------------------+
+2 rows in set
+```
+
+By querying the snapshots table, you can know the snapshot committing information and expiration
+information of the table, and you can time travel through the information.

Review Comment:
   How about
   > By querying one table's snapshots table, you can know the commit and expiration information about that table and time travel through the data.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org