Looker Community

Key Awareness

i have a dimension with a primary key and a descriptive column to the primary key.

e.g. DIM_BOOK

columns:
book_id,
book_name
book_publisher

pk = book_id

Content:
book_id = 12345
book_name = 'Why Looker is great
book_publisher= ‘Looker’

WIe I can now safely filter to the book (via the book_id) but only show the customer the field book_name.

Is there such a thing as key awareness?
So a function where I define in the model what the PK is and which is the “talking” exchange field?

So I enter in the filter “Why Looker is great” and in the SQL it will automatically be where book_id = 12345

In my opinion, this would have both performance advantages and would greatly simplify the work of my team.
I only imagine 100 looks referencing the book “Why Looker is great” and then we find that there was a typo and the title is actually “Why LOOKER is genius”.
The PK doesn’t change, but the title does.

Are there any nice solutions?

1 Like

:point_up: