I have made a new model,
model_2, in my LookML project, and I would like my Looks to use it. However, I built my Looks based off an Explore in
How do I take my existing Look and move it to
model_2, rather than creating a new Look from scratch?
Solution 1: Content Validator
The Content Validator is a tool that checks Looks and dashboards for errors. But it also has a Find and Replace in All Content feature, which you can use to change the underlying model for all Looks or dashboard tiles that use
Things to note about this method:
- Users must have the
developpermission to use the Content Validator.
- The Find and Replace in All Content feature changes all Looks and dashboards on the Looker instance. To apply this change to only a few Looks, see the secondary solution below.
Solution 2: Edit the URL
To change the model for only a few Looks or query-based dashboard tiles (Look-linked dashboard tiles will automatically be updated with the new model reference), we can take advantage of the fact that Looker keeps all the information about a query in the expanded URL. To access this and update the model reference to
model_2, follow these steps:
- Click Explore From Here from the Look or dashboard tile.
- Click the cog in the upper right of the Explore page.
- Select Share.
- Copy the Expanded URL and paste it somewhere else, like in a new browser tab. (Don't visit the URL yet, or Looker will hash it into a shortened URL.)
- Change the model name referenced in the URL. The URL takes the following form:
- Visit the newly formatted URL.
- Save the Explore as a Look in the same folder (called "Spaces" before Looker 6.20), replacing the old Look. To replace a query-based dashboard tile, save the Explore onto a dashboard as a tile and delete the original tile from the dashboard.
This method can be repeated for each Look or query-based dashboard tile that needs to be changed!