Apply always_filter to unquoted parameter

Problem Description

I have two identically structured datasets stored in different schemas. I am trying to create a workflow where...

  1. Edits to a single view apply to both datasets
  2. Edits to a single explore apply to both datasets
  3. A user can select the explore for the dataset they need, and filters are automatically applied to query the relevant dataset
I have managed to implement 1 and 2 using unquoted parameters in the view files that set the schema name and by creating base explores that I extend off of, but when I set the always_filter for the extended explore, the first option provided to the allowed_option parameter within the view file is always the default, no matter what I set the default value to when setting always_filter

Question

How do I set an unquoted view parameter within an explore?

Example Lookml

Views

 

 

view: view_one {
   sql_table_name: {% parameter schema_name %}.view_one ;; 
   parameter: schema_name {
        type: unquoted
        allowed_value: {
            label: "Dataset 1"
            value: "dataset_one"
        }
        allowed_value: {
            label: "Dataset 2"
            value: "dataset_2"
        }
    }
}

view: view_two {
   sql_table_name: {% parameter schema_name %}.view_two ;; 
   parameter: schema_name {
        type: unquoted
        allowed_value: {
            label: "Dataset 1"
            value: "dataset_one"
        }
        allowed_value: {
            label: "Dataset 2"
            value: "dataset_2"
        }
    }
}

 

 

Explores

 

 

explore: base_explore {
       view_name: view_1
       join: view_2 {
           sql_on: {
              type: inner
              sql_on: ${view_one.id} = ${view_2.id};;
              }
       }
}

explore: dataset_1 {
    extends: [base_explore]
    always_filter: {
    filters: [
      view_one.schema_name: "Dataset 1",
      view_two.schema_name: "Dataset 1",
      ]
   }
}

explore: dataset_2 {

    extends: [base_explore]
    always_filter: {
    filters: [
      view_one.schema_name: "Dataset 2",
      view_two.schema_name: "Dataset 2",
      ]
   }
}

 

 

Additional Comments
  1. I have tried setting the always_filter value to dataset_one/dataset_two but that doesn't change the result
  2. really wish an "explore_parameter" existed that could be passed to the view files. That would allow views to behave more like templates, but I'm fairly certain that feature doesn't exist.
  3. The docs for unquoted parameters are very limited
0 0 382