Projects are typically created during Looker setup, at the same time as model generation. This page assumes that you or someone else has already created a project. If your organization is just starting with Looker, you may want to coordinate with your Looker Analyst to ensure that project creation is done as cleanly as possible.
A LookML data model is stored in one or more “projects.” A project is a collection of LookML files that describe how your database tables are related to each other, and how Looker should interpret those tables. Looker uses Git for version control, to ensure that your developers can successfully collaborate on your data model. In general, one project represents a single Git repository.
Looker provides an integrated development environment (IDE) for creating and managing your project files. The IDE is often referred to as the LookML editor as that’s where you edit LookML files.
When you or someone else creates a new project, Looker’s project generator creates a baseline set of files, which you use as a template for building out the project. In many cases you will not need to write a LookML file from scratch.
A project lists its files in the following categories:
- Project Manifest: Possibly a single project manifest file that lists the names of other project files from which you can import other files into the current project. To have the option of adding a manifest file, the Looker admin must enable the Project Import experimental Labs feature.
- Documents: Possibly some documentation files written in Github-flavored Markdown.
- Models: One or more model files that define the project’s Explore options and joins.
- Views: Multiple view files, each corresponding to a database table or derived table.
- Dashboards: Possibly some dashboard files that define the data and layouts for dashboards, if you choose to use LookML Dashboards.
- Data: Possibly one or more data files, which are JSON files. These files can be used to specify custom maps.
- Other: Any file whose filetype is not recognized by the LookML IDE as belonging in one of the other categories. If you have defined a native derived table (NDT), for example, you would create an Explore file (
explore_filename.explore.lkml) on which to base the NDT. Explore files are stored in the Other category. If you would like to move a file from the Other section to another section, click the file’s gear and rename the file to have the appropriate file type extension for that section.
You can access LookML projects from the Develop navigation menu:
Read more about managing projects here.
Development Mode vs. Production Mode
Your Looker data model exists in two states: Production Mode and Development Mode.
Typically, business users are in Production Mode when they are exploring data in Looker. Use Production Mode when you are exploring data in Looker for your own analyses or to create saved content (Looks and dashboards) for your business users. The LookML files that make up the data model are treated as read-only in this mode.
Enter Development Mode when you’d like to make a change to your LookML. This mode accesses a completely separate version of your data model that only you can see and edit. (If you are familiar with Git terms, Development Mode is handled by a separate branch.) When you’re happy with your changes you can merge them into production and resolve any conflicts with other developers.
Development Mode enables you to make and test LookML changes without affecting business users; as mentioned above, these users are typically interacting with Looker in Production Mode.
Development Mode is frequently referred to as “dev mode” or “developer mode.”
Switching In and Out of Development Mode
You can switch Development Mode on and off by either of these methods:
- Using the keyboard shortcut Ctrl-Shift-D (Windows) or Control+Shift+D (Mac).
- Clicking Develop to open its menu and then clicking the Development Mode ON/OFF button.
While in Development Mode, you will notice the following changes:
- The LookML and Explore sections of Looker will be populated by your development version of the model.
- There will be a purple Development Mode bar at the top of the browser window.
To exit Development Mode, you can use any of these methods:
- Use the keyboard shortcut Ctrl-Shift-D (Windows) or Control+Shift+D (Mac)
- Click Exit Development Mode in the purple banner
- Open the Develop menu and click the Development Mode ON/OFF button
Looker’s IDE is integrated with Git for version control. This enables you to edit a private copy of the LookML files in Development Mode. When you’re ready for everyone to begin using any changes you’ve made, you can use Git to Commit and Push your changes to production.
Looker automatically manages the Git workflows for committing, pulling, and pushing changes. For details on using Looker’s version control see this page. For details on setting up Looker’s version control see this page.
Now that you know the basics of a project and how to get into Development Mode, the next step is to understand the model and view files that are a part of the project.