User Guide Getting Started Help Center Documentation Community Training
New LookML
Old LookML
New LookML
Looker
  
English
Français
Deutsch
日本語
view_label (for Fields)

This page refers to the view_label parameter that is part of a dimension, measure, or filter.

view_label can also be used as part of an Explore, described on this documentation page.

view_label can also be used as part of a join, described on this documentation page.

Usage

view: view_name {
  dimension: field_name {
    view_label: "desired label name"
  }
}

Hierarchy

view_label

Possible Field Types

Dimension, Dimension Group, Measure, Filter, Parameter

Accepts

A string

Definition

The view_label parameter enables you to change the name of the view under which the field is listed in the field picker without changing how it is referenced in LookML. If the label matches the name of an existing view, the field will now appear under that view. If you specify a new name, that name will appear in the field picker with the field under it. If not specified, the view label defaults to the name of the view.

Fields with view labels are still referenced with the normal ${view_name.field_name} syntax in LookML. The view label only impacts the appearance of the Field Picker. It does not alter an existing view or create a new view.

Also, note the difference between a field’s view_label and the field’s label. The view_label changes only the view name under which the field is listed, and not the name displayed for the field itself:

Examples

Make this dimension appear under the Identifiers view instead of the Distribution Centers view in the Field Picker.

view: distribution_centers { dimension: id { view_label: "Identifiers" type: number sql: ${TABLE}.id ;; } }

You can see examples of using view_label with a Liquid parameter to define dynamic labels in this Help Center article.

Top