Question

Grouping Fields Within Views (3.44+)


Userlevel 3

Some users have wanted greater control over how fields are grouped in Looker’s field picker. Looker 3.44 adds the new group_label parameter to let you group fields together, even within the same view.


Existing Things You Could Already Do


Since 3.20 it’s been possible to adjust the first level of grouping (aka you can adjust the views) by using the view_label parameter.



type: time dimension groups have also automatically grouped together within each view for quite a while:



New Things You Can Do in 3.44


As of 3.44, you can control how the fields are grouped within each view by using the new group_label parameter. For example, you could create a group of shipping fields that would look like this:



You would achieve this with the following LookML:


dimension: shipping_city {
sql: ${TABLE}.shipping_city ;;
group_label: "Shipping Info"
}

dimension: shipping_state {
sql: ${TABLE}.shipping_state ;;
group_label: "Shipping Info"
}

dimension: shipping_street {
sql: ${TABLE}.shipping_street ;;
group_label: "Shipping Info"
}

group_label also interacts with dimension groups in pretty handy ways. For example, this LookML will add a special date calculation into the existing dimension group:


dimension_group: created {
type: time
timeframes: [date, week, month]
sql: ${TABLE}.created_date ;;
}

dimension: special_date_calculation {
sql: my_fancy_pants_sql ;;
group_label: "Created Date"
}

It would look like:




Please keep in mind that there must be at least two fields in a group label for it to appear. Also, you can’t group dimensions and measures together in the same group_label. Even if you give a dimension and measure exactly the same group_label there will still be one group under dimensions, and one group under measures.



36 replies

+1 to multilevel grouping

Jumping on this as well - +1 to multilevel grouping

Userlevel 4

Thanks @chobbs I’ve passed your +1 to the product team!

Userlevel 3

Bump! The feature request thread to add dimension groups underneath group labels is here. That’s a subset of this request, but it would be a great start. Go vote! I’ll send you an invisible internet hug. You might also be interested in this request to allow ordering of field picker list items, including groups.

+1 to @tuple’s request of multilevel grouping. A use case for us is to have a time dimension group within another dimension group. e.g. in your example above, ‘Shipping Info’ would be the first level, with shipping time/date/etc. as a time group within the ‘Shipping Info’ group.

Anyone knows if we have this feature yet? I’m encountering the exact same situation like this with a time dimension under a group

+1 to this request! Would be extremely helpful for unlimited levels of nesting to group related topics


+1, it looks like this is the ticket to vote on:
https://portal.feedback.us.pendo.io/app/#/case/17645?currentProductId=53ee6715-9dcb-471f-bd41-7846ac4d9e41&section=requests

+1 to this request

+1 to multilevel grouping, PLEASE!

Adding my +1 to multilevel grouping

+1 to multilevel grouping 

Reply