Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for with blocks #2772

Closed
kaidaguerre opened this issue Nov 21, 2022 · 0 comments
Closed

Add support for with blocks #2772

kaidaguerre opened this issue Nov 21, 2022 · 0 comments
Assignees
Labels
autocomplete core complex or specific issues intended for implementation by the Steampipe core dev team issue

Comments

@kaidaguerre
Copy link
Contributor

kaidaguerre commented Nov 21, 2022

Query providers will allow a new block type called with. Similar to a with clause in a postgres CTE, the with block will allow users to specify additional queries or sql statements to run before running their sql/query.

A query provider may can contain 0 or more with blocks
With blocks are executed sequentially, in order (steampipe can parallelize them if it determines there are no dependencies).

The results of previous with queries are available to subsequent with queries, as well as to sql, args, and param.
with is not a top-level named resource - it is ONLY a block within query provider resources. The reuse pattern for with would be to use a named query, and reference that query in multiple with blocks.

@kaidaguerre kaidaguerre self-assigned this Nov 21, 2022
@kaidaguerre kaidaguerre added autocomplete core complex or specific issues intended for implementation by the Steampipe core dev team issue labels Nov 21, 2022
kaidaguerre added a commit that referenced this issue Nov 21, 2022
kaidaguerre added a commit that referenced this issue Nov 23, 2022
…ap `with` executions in LeafRuns to support runtime dependency resolution. Closes #2789. #2772
kaidaguerre added a commit that referenced this issue Nov 24, 2022
…ostgres can convert it. Fix multiple with blocks. #2789. #2772
kaidaguerre added a commit that referenced this issue Nov 25, 2022
…ing not map. Support argument definitions which make an array out of a runtime dependency. #2772, Closes #2802
kaidaguerre added a commit that referenced this issue Nov 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autocomplete core complex or specific issues intended for implementation by the Steampipe core dev team issue
Projects
None yet
Development

No branches or pull requests

1 participant