Knowledge Drop

Should I hide or delete unnecessary LookML fields?

  • 8 July 2021
  • 1 reply

Userlevel 4

Last tested: Aug 6, 2020

The Problem

I have some LookML fields that I'm not using. They are currently hidden with `hidden: yes`. I'm concerned that it may be a performance cost to keep them. Should I delete them to save database strain?

An Answer

Writing a field in LookML does not immediately query the database. The database is only queried once you select that field in an Explore. So, if a field is hidden, and thus doesn't show up in the explore, it can't be selected, and so will never impact the database.

With that said, it doesn't matter too much whether you hide or delete.
The advantage of hiding is that you have the fields there in case you ever decide to unhide them.
The advantage of deleting is that your view file has slightly fewer characters, which makes LookML validation slightly faster.


This content is subject to limited support.                



1 reply

I’m currently in the process of building out a new project manifest that’s ultimately going to replace the existing one, which includes a new schema and complete overhaul of the tables/data, so I’m working with our engineers who maintain our db in Snowflake.  In my experience, especially throughout testing phases, I always keep fields in the LookML so long as they are in the db!  With fields I know aren’t going to be needed or used for my purposes, but are in production, I’ll just insert ‘#’ before each line of a given dimension (and sometimes I’ll even add notes just to make sure I keep track of things in a crazy world)!