I'd like to be able to do this, and maybe re-use the data table later.
CREATE TEMP TABLE data(x, y) AS (VALUES
('A', 5),
('B', 2),
('C', 4),
('D', 7),
('E', 6)
)
VISUALISE x, y FROM data
DRAW area
#> Failed to execute query: Data source error: Failed to execute SQL: Parser Error: syntax error at or near "CREATE"
#> LINE 1: ... TABLE "__ggsql_global_cab3d805ac3f47ef93a49a892627e943__" AS CREATE TEMP TABLE data(x, y) AS
#> (VALUES
Currently our options are:
- Use CTE, e.g.
WITH data(x, y) AS (VALUES ...). But that doesn't allow you to re-use the data later.
- If you're working in a jupyter notebook, you can split the SQL part from the visualise part and run them in separate cells. This is suboptimal in my opinion.
I'd like to be able to do this, and maybe re-use the
datatable later.Currently our options are:
WITH data(x, y) AS (VALUES ...). But that doesn't allow you to re-use the data later.