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

Implement parameter inheriting #1812

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

christopherswenson
Copy link
Contributor

I'm not 100% sure about this behavior yet, so adding the DO NOT MERGE label, and this implementation also feels a bit icky in a way I can't put my finger on yet.

Allows a source to be defined in a way that inherits a parameter from the extended source:

source: state_facts(
  state_filter::string is "CA"
) is duckdb.table('malloytest.state_facts') extend {
  where: state = state_filter
}

// inherits the default value 'CA' from `state_facts`
source: state_facts_ext(state_filter) is state_facts(state_filter)

// should only return one row, `{ state: 'CA' }`
run: state_facts_ext -> { group_by: state }

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

Successfully merging this pull request may close these issues.

1 participant