Skip to content

Support selecting wildcards in node queries#993

Open
shangyian wants to merge 2229 commits intoDataJunction:mainfrom
shangyian:support-wildcards
Open

Support selecting wildcards in node queries#993
shangyian wants to merge 2229 commits intoDataJunction:mainfrom
shangyian:support-wildcards

Conversation

@shangyian
Copy link
Copy Markdown
Collaborator

@shangyian shangyian commented May 10, 2024

Summary

This PR adds support for writing SELECT * in node queries.

During the Wildcard compile stage, it expands out SELECT * to all available columns on the table references. This may include DJ node columns, CTE columns, or subquery columns. These expanded columns are saved to a node revision's associated columns, but in the saved query, we keep the wildcard syntax (i.e., we always preserve what the user wrote).

During node updates, we also update these columns based on the parent nodes' columns, if any has changed.

Test Plan

Deployment Plan

shangyian and others added 30 commits January 24, 2024 08:56
…alembic

Fix alembic migration for missing table attribute
… causes issues as our database client not support async, so every database call introduces blocking calls to the event loop, eventually resulting in the workers timing out.
Remove the mixture of async endpoints with a sync db connection
…n-0.0.1a41

Bump DataJunction version to 0.0.1a41
…lumns first in the columns list.

Switch default in graph view to five nodes
Additional Dimensions Info in the UI
…n-0.0.1a42

Bump DataJunction version to 0.0.1a42
…e validate the node query to get the list of columns) rather than text input.
…ke the metric's upstream node, its agg expression, and the required dimensions
…ggregate expression as input, which clarifies what we mean by a metric query. Also adds in some styling changes to the react-select dropdowns for both multi and single select.

- Modify the metrics page to display the upstream node and aggregate expression separately

- Refactor for better organization of form fields and fix tests
Alter metrics UI to use upstream + aggregate expression
Required dimensions, node tab links, node name/namespace validation,
…n-0.0.1a43

Bump DataJunction version to 0.0.1a43
…ence flow around draft nodes is less than ideal
Switch to 'published' as the default in the node creation UI
shangyian and others added 21 commits May 27, 2024 12:07
…ionlink

Fix an issue where removing dimension links was invalidating cubes incorrectly and taking a long time
Add loading stage to various parts of the UI
Add the ability to `update_if_exists` to `create_X` methods
Sort dimensions by order of usage when displaying them in the link dimensions popover
Add a node dependencies tab that displays the node graph in list form
FIX Remove fields from Source's UpdateNode that aren't actually update-able
…on-0.0.1a51

Bump DataJunction version to 0.0.1a51
@shangyian shangyian force-pushed the support-wildcards branch 2 times, most recently from ba853a0 to d51de7c Compare June 3, 2024 17:47
@shangyian shangyian force-pushed the support-wildcards branch from d51de7c to 0734396 Compare June 4, 2024 03:31
@shangyian shangyian marked this pull request as ready for review June 4, 2024 03:32
@agorajek
Copy link
Copy Markdown
Member

agorajek commented Dec 2, 2024

@shangyian what happened here? Was there a major issue or just a missed PR? I see that we can create nodes with SELECT * but we get one Wildcard column for them.

@shangyian
Copy link
Copy Markdown
Collaborator Author

@agorajek yeah, unfortunately I couldn't get one of the unit tests to pass (there was some non-deterministic issue that was hard to track down). I'll take another stab at it soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants