seafowl
seafowl copied to clipboard
Extend support for table time travel syntax to write statements
The current table time travel syntax doesn't support versioning in write subqueries (e.g. CREATE TABLE old_table AS SELECT * FROM new_table('2022-01-01 10:10:10 +00:00')
), and instead the table ref gets resolved to the latest table version. The reason is that we only do AST rewrites for the Query (aka SELECT) root node. For this to work we'd need to extend the visitor for more AST root nodes (CREATE, INSERT at least).