Skip to content

Commit

Permalink
remove tabs to test build
Browse files Browse the repository at this point in the history
  • Loading branch information
mikealfare committed Dec 7, 2023
1 parent bd6c4fc commit 5e904f1
Showing 1 changed file with 0 additions and 77 deletions.
77 changes: 0 additions & 77 deletions website/docs/reference/resource-configs/postgres-configs.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,83 +116,6 @@ with the following configuration parameters:
| `on_configuration_change` | <string> | no | `apply` | n/a |
| [`indexes`](#indexes) | [{<dictionary>}] | no | `none` | alter |

<Tabs
groupId="config-languages"
defaultValue="project-yaml"
values={[
{ label: 'Project file', value: 'project-yaml', },
{ label: 'Property file', value: 'property-yaml', },
{ label: 'Config block', value: 'config', },
]
}>

<TabItem value="project-yaml">

<File name='dbt_project.yml'>

```yaml
models:
[<resource-path>](/reference/resource-configs/resource-path):
[+](/reference/resource-configs/plus-prefix)[materialized](/reference/resource-configs/materialized): materialized_view
[+](/reference/resource-configs/plus-prefix)on_configuration_change: apply | continue | fail
[+](/reference/resource-configs/plus-prefix)[indexes](#indexes):
- columns: [<column-name>]
unique: true | false
type: hash | btree
```

</File>

</TabItem>


<TabItem value="property-yaml">

<File name='models/properties.yml'>

```yaml
version: 2
models:
- name: [<model-name>]
config:
[materialized](/reference/resource-configs/materialized): materialized_view
on_configuration_change: apply | continue | fail
[indexes](#indexes):
- columns: [<column-name>]
unique: true | false
type: hash | btree
```

</File>

</TabItem>


<TabItem value="config">

<File name='models/<model_name>.sql'>

```jinja
{{ config(
[materialized](/reference/resource-configs/materialized)="materialized_view",
on_configuration_change="apply" | "continue" | "fail",
[indexes](#indexes)=[
{
"columns": ["<column-name>"],
"unique": true | false,
"type": "hash" | "btree",
}
]
) }}
```

</File>

</TabItem>

</Tabs>

The `indexes` parameter corresponds to that of a table, as linked above.
It's worth noting that, unlike with tables, dbt will monitor this parameter for changes and apply the changes without dropping the materialized view.
This happens via a `DROP/CREATE` of the indexes, which could be thought of as a `ALTER` of the materialized view.
Expand Down

0 comments on commit 5e904f1

Please sign in to comment.