|
1 | 1 | --- |
2 | 2 | title: "lightdash.config.yml reference" |
3 | | -description: 'The lightdash.config.yml file allows you to configure project-wide settings for your Lightdash project, including spotlight and parameters.' |
| 3 | +description: 'The lightdash.config.yml file allows you to configure project-wide settings for your Lightdash project, including spotlight, parameters, and defaults.' |
4 | 4 | sidebarTitle: "lightdash.config.yml" |
5 | 5 | --- |
6 | 6 |
|
@@ -89,6 +89,10 @@ spotlight: |
89 | 89 | # Configuration for project-wide parameters |
90 | 90 | parameters: |
91 | 91 | # ... |
| 92 | +
|
| 93 | +# Configuration for project-wide defaults |
| 94 | +defaults: |
| 95 | + # ... |
92 | 96 | ``` |
93 | 97 |
|
94 | 98 |
|
@@ -198,4 +202,50 @@ Or using the shorter alias: |
198 | 202 | ${ld.parameters.region} |
199 | 203 | ``` |
200 | 204 |
|
201 | | -See the [Parameters guide](/guides/developer/using-parameters) for more information on how to use parameters. |
| 205 | +See the [Parameters guide](/guides/developer/using-parameters) for more information on how to use parameters. |
| 206 | + |
| 207 | + |
| 208 | +## Defaults configuration |
| 209 | + |
| 210 | +The `defaults` section allows you to set project-wide default settings that apply across all explores and dimensions. These defaults can be overridden at the explore or dimension level. |
| 211 | + |
| 212 | +```yaml |
| 213 | +defaults: |
| 214 | + case_sensitive: false |
| 215 | +``` |
| 216 | + |
| 217 | +| Property | Required | Value | Description | |
| 218 | +| :--------------- | :------- | :------ | :---------- | |
| 219 | +| `case_sensitive` | No | boolean | Default case sensitivity for string filters across the project. When `false`, all string filters will be case insensitive by default. Defaults to `true`. | |
| 220 | + |
| 221 | + |
| 222 | +### Case sensitivity hierarchy |
| 223 | + |
| 224 | +The `case_sensitive` setting follows a hierarchy where more specific settings override broader ones: |
| 225 | + |
| 226 | +1. **Dimension-level** (highest priority) - Set on individual dimensions |
| 227 | +2. **Explore/table-level** - Set on the explore or table |
| 228 | +3. **Project-level** - Set in `lightdash.config.yml` defaults |
| 229 | +4. **Default behavior** - Case sensitive (`true`) if nothing is specified |
| 230 | + |
| 231 | +This allows you to set organization-wide defaults while maintaining the flexibility to override them for specific explores or dimensions as needed. |
| 232 | + |
| 233 | +**Example**: Set case insensitivity as the project default, but override for a specific table: |
| 234 | + |
| 235 | +```yaml |
| 236 | +# lightdash.config.yml |
| 237 | +defaults: |
| 238 | + case_sensitive: false # Project-wide default |
| 239 | +``` |
| 240 | + |
| 241 | +```yaml |
| 242 | +# In your model yml file - override for a specific table |
| 243 | +models: |
| 244 | + - name: case_sensitive_table |
| 245 | + meta: |
| 246 | + case_sensitive: true # Override: this table uses case sensitive filters |
| 247 | +``` |
| 248 | + |
| 249 | +<Info> |
| 250 | + See [Tables reference](/references/tables#case-sensitive) for explore-level configuration and [Dimensions reference](/references/dimensions#case-sensitive) for dimension-level configuration. |
| 251 | +</Info> |
0 commit comments