Skip to content

Commit acde366

Browse files
Minor fixes; add highlighted lines
1 parent 0676a89 commit acde366

2 files changed

Lines changed: 8 additions & 10 deletions

File tree

docs/guides/configuration.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -869,7 +869,7 @@ See [here](https://sqlglot.com/sqlglot/dialects/dialect.html#NormalizationStrate
869869

870870
You can also define gateway specific `model_defaults` in the `gateways` section, which override the global defaults for that gateway.
871871

872-
```yaml linenums="1"
872+
```yaml linenums="1" hl_lines="6 14"
873873
gateways:
874874
redshift:
875875
connection:
@@ -891,9 +891,9 @@ This allows you to tailor the behavior of models for each gateway without affect
891891

892892
For example, in some SQL engines identifiers like table and column names are case-sensitive, but they are case-insensitive in other engines. By default, a project that uses both types of engines would need to ensure the models for each engine aligned with the engine's normalization behavior, which makes project maintenance and debugging more challenging.
893893

894-
Gateway-specific `model_defaults` allow you to change how SQLMesh performs identifier normalization *by engine* to align the different engines' behavior.
894+
Gateway-specific `model_defaults` allow you to change how SQLMesh performs identifier normalization *by engine* to align the different engines' behavior.
895895

896-
In the example above, the project's default dialect is `snowflake` (line 14). The `redshift` gateway configuration overrides that global default dialect with `"snowflake,normalization_strategy=case_insensitive"` (line 6).
896+
In the example above, the project's default dialect is `snowflake` (line 14). The `redshift` gateway configuration overrides that global default dialect with `"snowflake,normalization_strategy=case_insensitive"` (line 6).
897897

898898
That value tells SQLMesh that the `redshift` gateway's models will be written in the Snowflake SQL dialect (so need to be transpiled from Snowflake to Redshift), but that the resulting Redshift SQL should treat identifiers as case-insensitive to match Snowflake's behavior.
899899

docs/guides/multi_engine.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,6 @@ In this setup, the PostgreSQL engine is set as the default, so it will be used t
9797
)
9898
```
9999

100-
Given this configuration, when a model’s gateway is set to duckdb, it will be materialized within the PostgreSQL `main_db` catalog, but it will be evaluated using DuckDB’s engine.
101-
102100
Given this configuration, when a model’s gateway is set to DuckDB, the DuckDB engine will perform the calculations before materializing the physical table in the PostgreSQL `main_db` catalog.
103101

104102
```sql linenums="1"
@@ -139,7 +137,7 @@ First, add the connections to your configuration and set the `gateway_managed_vi
139137

140138
=== "YAML"
141139

142-
```yaml linenums="1"
140+
```yaml linenums="1" hl_lines="30"
143141
gateways:
144142
redshift:
145143
connection:
@@ -178,7 +176,7 @@ variables:
178176
179177
=== "Python"
180178
181-
```python linenums="1"
179+
```python linenums="1" hl_lines="48"
182180
from sqlmesh.core.config import (
183181
Config,
184182
ModelDefaultsConfig,
@@ -255,7 +253,7 @@ FROM
255253

256254
For the `athena_schema.order_status` model, we explicitly specify the `athena` gateway:
257255

258-
```sql linenums="1"
256+
```sql linenums="1" hl_lines="4"
259257
MODEL (
260258
name athena_schema.order_status,
261259
table_format iceberg,
@@ -271,7 +269,7 @@ FROM
271269

272270
Finally, specifying the `snowflake` gateway for the `customer_orders` model ensures it is isolated from the rest and reads from a table within the Snowflake database:
273271

274-
```sql linenums="1"
272+
```sql linenums="1" hl_lines="4"
275273
MODEL (
276274
name snowflake_schema.customer_orders,
277275
table_format iceberg,
@@ -303,7 +301,7 @@ Models:
303301
Models needing backfill:
304302
├── awsdatacatalog.athena_schema.order_status: [full refresh]
305303
├── redshift_schema.order_dates: [full refresh]
306-
└── silver.snowflake_schema.customers: [full refresh]
304+
└── silver.snowflake_schema.customer_orders: [full refresh]
307305
Apply - Backfill Tables [y/n]: y
308306
```
309307

0 commit comments

Comments
 (0)