Skip to content

Commit

Permalink
add documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-jcieslak committed Feb 1, 2024
1 parent d1be669 commit 7665938
Show file tree
Hide file tree
Showing 2 changed files with 87 additions and 0 deletions.
34 changes: 34 additions & 0 deletions docs/resources/grant_privileges_to_share.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ description: |-
---

~> **Note** This is a preview resource. It's ready for general use. In case of any errors, please file an issue in our GitHub repository.

# snowflake_grant_privileges_to_share (Resource)


Expand Down Expand Up @@ -106,3 +108,35 @@ resource "snowflake_grant_privileges_to_share" "example" {
### Read-Only

- `id` (String) The ID of this resource.

## Import

~> **Note** All the ..._name parts should be fully qualified names, e.g. for database object it is `"<database_name>"."<object_name>"`

Import is supported using the following syntax:

`terraform import "<share_name>|<privileges>|<grant_type>|<grant_identifier>"`

where:
- share_name - fully qualified identifier
- privileges - list of privileges, comma separated. See the available privileges for given object types: https://docs.snowflake.com/en/sql-reference/sql/grant-privilege-share#syntax
- grant_type - enum
- grant_identifier - fully qualified identifier

### OnDatabase
`terraform import "<share_name>|<privileges>|OnDatabase|<database_name>"`

### OnSchema
`terraform import "<share_name>|<privileges>|OnSchema|<database_name>.<schema_name>"`

### OnTable
`terraform import "<share_name>|<privileges>|OnTable|<database_name>.<schema_name>.<table_name>"`

### OnSchema
`terraform import "<share_name>|<privileges>|OnAllTablesInSchema|<database_name>.<schema_name>"`

### OnTag
`terraform import "<share_name>|<privileges>|OnTag|<database_name>.<schema_name>.<tag_name>"`

### OnView
`terraform import "<share_name>|<privileges>|OnView|<database_name>.<schema_name>.<view_name>"`
53 changes: 53 additions & 0 deletions templates/resources/grant_privileges_to_share.md.tmpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
---
# generated by https://github.com/hashicorp/terraform-plugin-docs
page_title: "{{.Name}} {{.Type}} - {{.ProviderName}}"
subcategory: ""
description: |-
{{ .Description | plainmarkdown | trimspace | prefixlines " " }}
---

~> **Note** This is a preview resource. It's ready for general use. In case of any errors, please file an issue in our GitHub repository.

# {{.Name}} ({{.Type}})

{{ .Description | trimspace }}

{{ if .HasExample -}}
## Example Usage

{{ tffile (printf "examples/resources/%s/resource.tf" .Name)}}
{{- end }}

{{ .SchemaMarkdown | trimspace }}

## Import

~> **Note** All the ..._name parts should be fully qualified names, e.g. for database object it is `"<database_name>"."<object_name>"`

Import is supported using the following syntax:

`terraform import "<share_name>|<privileges>|<grant_type>|<grant_identifier>"`

where:
- share_name - fully qualified identifier
- privileges - list of privileges, comma separated. See the available privileges for given object types: https://docs.snowflake.com/en/sql-reference/sql/grant-privilege-share#syntax
- grant_type - enum
- grant_identifier - fully qualified identifier

### OnDatabase
`terraform import "<share_name>|<privileges>|OnDatabase|<database_name>"`

### OnSchema
`terraform import "<share_name>|<privileges>|OnSchema|<database_name>.<schema_name>"`

### OnTable
`terraform import "<share_name>|<privileges>|OnTable|<database_name>.<schema_name>.<table_name>"`

### OnSchema
`terraform import "<share_name>|<privileges>|OnAllTablesInSchema|<database_name>.<schema_name>"`

### OnTag
`terraform import "<share_name>|<privileges>|OnTag|<database_name>.<schema_name>.<tag_name>"`

### OnView
`terraform import "<share_name>|<privileges>|OnView|<database_name>.<schema_name>.<view_name>"`

0 comments on commit 7665938

Please sign in to comment.