bigquery

package
v1.12.0 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2023 License: AGPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Connect

func Connect(context context.Context, cred *BQCredentials) (*bigquery.Client, error)

Types

type BQCredentials added in v1.7.0

type BQCredentials struct {
	ProjectID   string
	Credentials string
}

type BigQuery added in v1.8.0

type BigQuery struct {
	// contains filtered or unexported fields
}

func New added in v1.8.0

func New(conf *config.Config, log logger.Logger) *BigQuery

func (*BigQuery) AddColumns added in v1.8.0

func (bq *BigQuery) AddColumns(ctx context.Context, tableName string, columnsInfo []warehouseutils.ColumnInfo) (err error)

func (*BigQuery) AlterColumn added in v1.8.0

func (*BigQuery) Cleanup added in v1.8.0

func (bq *BigQuery) Cleanup(context.Context)

func (*BigQuery) Connect added in v1.8.0

func (bq *BigQuery) Connect(ctx context.Context, warehouse model.Warehouse) (client.Client, error)

func (*BigQuery) CrashRecover added in v1.8.0

func (bq *BigQuery) CrashRecover(ctx context.Context)

func (*BigQuery) CreateSchema added in v1.8.0

func (bq *BigQuery) CreateSchema(ctx context.Context) (err error)

func (*BigQuery) CreateTable added in v1.8.0

func (bq *BigQuery) CreateTable(ctx context.Context, tableName string, columnMap model.TableSchema) error

func (*BigQuery) DeleteBy added in v1.8.0

func (bq *BigQuery) DeleteBy(ctx context.Context, tableNames []string, params warehouseutils.DeleteByParams) error

func (*BigQuery) DeleteTable added in v1.8.0

func (bq *BigQuery) DeleteTable(ctx context.Context, tableName string) (err error)

func (*BigQuery) DownloadIdentityRules added in v1.8.0

func (bq *BigQuery) DownloadIdentityRules(ctx context.Context, gzWriter *misc.GZipWriter) (err error)

func (*BigQuery) DropTable added in v1.8.0

func (bq *BigQuery) DropTable(ctx context.Context, tableName string) (err error)

func (*BigQuery) ErrorMappings added in v1.8.0

func (*BigQuery) ErrorMappings() []model.JobError

func (*BigQuery) FetchSchema added in v1.8.0

func (bq *BigQuery) FetchSchema(ctx context.Context) (model.Schema, model.Schema, error)

FetchSchema queries bigquery and returns the schema associated with provided namespace

func (*BigQuery) GetTotalCountInTable added in v1.8.0

func (bq *BigQuery) GetTotalCountInTable(ctx context.Context, tableName string) (int64, error)

func (*BigQuery) IsEmpty added in v1.8.0

func (bq *BigQuery) IsEmpty(ctx context.Context, warehouse model.Warehouse) (empty bool, err error)

func (*BigQuery) LoadIdentityMappingsTable added in v1.8.0

func (bq *BigQuery) LoadIdentityMappingsTable(ctx context.Context) (err error)

func (*BigQuery) LoadIdentityMergeRulesTable added in v1.8.0

func (bq *BigQuery) LoadIdentityMergeRulesTable(ctx context.Context) (err error)

func (*BigQuery) LoadTable added in v1.8.0

func (bq *BigQuery) LoadTable(ctx context.Context, tableName string) error

func (*BigQuery) LoadTestTable added in v1.8.0

func (bq *BigQuery) LoadTestTable(ctx context.Context, location, tableName string, _ map[string]interface{}, _ string) (err error)

func (*BigQuery) LoadUserTables added in v1.8.0

func (bq *BigQuery) LoadUserTables(ctx context.Context) (errorMap map[string]error)

func (*BigQuery) SetConnectionTimeout added in v1.8.0

func (*BigQuery) SetConnectionTimeout(_ time.Duration)

func (*BigQuery) Setup added in v1.8.0

func (bq *BigQuery) Setup(ctx context.Context, warehouse model.Warehouse, uploader warehouseutils.Uploader) (err error)

func (*BigQuery) TestConnection added in v1.8.0

func (*BigQuery) TestConnection(context.Context, model.Warehouse) (err error)

type StagingLoadTable added in v1.7.0

type StagingLoadTable struct {
	// contains filtered or unexported fields
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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