bigquery

package
v0.33.0 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package bigquery contributes the BIGQUERY statement family to spanner-mycli through the Feature registration seam (issue #778). It is imported only by the full binary (via internal/mycli/feature/all); the core internal/mycli package does not import it, so cloud.google.com/go/bigquery stays off the core import path. The cloud dependency is aliased as bq throughout this package.

Tracked debt: BigQuery values are exported as display strings, not typed values (see formatBigQueryValue). A BIGQUERY query result therefore cannot be consumed downstream with column types; this limitation is inherited from the original in-core implementation and tracked as the feature's debt in #778 §1.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Feature

func Feature() mycli.Feature

Feature returns the BIGQUERY Feature value. Each call allocates a FRESH config and wires fresh Variable/def/statement instances around it, so no state is shared between Feature values (#778 §4.4 session-isolation commitment).

Types

type BigQueryStatement

type BigQueryStatement struct {
	mycli.MutationClassifier
	mycli.MarksDetachedCompatible
	SQL string
	// contains filtered or unexported fields
}

BigQueryStatement executes a single BigQuery SQL statement. It embeds mycli.MutationClassifier (Classify wired in the constructor to the fail-closed first-keyword classifier over its own SQL) so the READONLY guard can reject mutating BigQuery statements, and mycli.MarksDetachedCompatible so it runs in detached session mode (admin-only, no Spanner database).

func (*BigQueryStatement) Execute

func (s *BigQueryStatement) Execute(ctx context.Context, session *mycli.Session) (*mycli.Result, error)

Execute runs the BigQuery SQL and returns the result rows as display strings.

Jump to

Keyboard shortcuts

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