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 skeleton joins section on model creation #163

Merged
merged 7 commits into from
Sep 17, 2024

Conversation

sfc-gh-cnivera
Copy link
Collaborator

@sfc-gh-cnivera sfc-gh-cnivera commented Sep 16, 2024

We are gating join support behind an "experimental features" checkbox in the UI. When enabled, we will allow for new features such as joins to be supported in the semantic model generator. Note that users must have the prerequisite parameters enabled in their Snowflake accounts for this to properly work.

For now, we'd like to expose the joins via a commented out section to simply inform the user of the option. We will quickly follow up by building an actual UI for selecting tables and their join keys.

CleanShot 2024-09-17 at 11 09 53@2x

CleanShot 2024-09-17 at 11 11 07@2x


if in_section:
comment_indent = " " * section_indent_level
current_indent_level = len(line) - len(line.lstrip())
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just including some quick changes to preserve indentation level when sections are commented out - makes it a bit easier for the user to preserve the correct indentation if uncommenting

Copy link
Collaborator

@sfc-gh-rehuang sfc-gh-rehuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me, thanks for adding!
One thing:
can we comment in join_type and relationship_type fields only below values are supported?
for join_type: inner and left_outer
for relationship _type: one_to_one and many_to_one

(see semantic_model.proto definition in our cortex/ repo)

@sfc-gh-cnivera sfc-gh-cnivera merged commit 3d22da3 into main Sep 17, 2024
3 checks passed
@sfc-gh-cnivera sfc-gh-cnivera deleted the cnivera/skeleton-join branch September 17, 2024 20:02
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.

2 participants