resourceview

package
v1.0.36 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 2, 2024 License: MPL-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ResourceView

func ResourceView() *schema.Resource

Types

type CHView

type CHView struct {
	Database string `ch:"database"`
	Name     string `ch:"name"`
	Query    string `ch:"as_select"`
	Engine   string `ch:"engine"`
	Comment  string `ch:"comment"`
}

func (*CHView) ToResource

func (t *CHView) ToResource() (*ViewResource, error)

type CHViewService

type CHViewService struct {
	CHConnection *driver.Conn
}

func (*CHViewService) CreateView

func (ts *CHViewService) CreateView(ctx context.Context, viewResource ViewResource) error

func (*CHViewService) DeleteView

func (ts *CHViewService) DeleteView(ctx context.Context, viewResource ViewResource) error

func (*CHViewService) GetDBViews

func (ts *CHViewService) GetDBViews(ctx context.Context, database string) ([]CHView, error)

func (*CHViewService) GetView

func (ts *CHViewService) GetView(ctx context.Context, database string, view string) (*CHView, error)

type ViewResource

type ViewResource struct {
	Database     string
	Name         string
	Query        string
	Cluster      string
	Materialized bool
	ToTable      string
	Comment      string
}

func (*ViewResource) Validate

func (t *ViewResource) Validate() diag.Diagnostics

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL