Documentation
¶
Index ¶
Constants ¶
View Source
const ( ModeRepeated string = "REPEATED" ModeRequired string = "REQUIRED" ModeNullable string = "NULLABLE" )
Different modes of a BigQuery field.
Variables ¶
This section is empty.
Functions ¶
func MarshalSchema ¶
MarshalSchema marshals a BigQuery schema to a valid BigQuery JSON schema based on default MarshalOptions. The JSON conforms to the format in this example: https://cloud.google.com/bigquery/docs/nested-repeated#example_schema
Types ¶
type Field ¶
type Field struct { Name string `json:"name"` Type bigquery.FieldType `json:"type"` Mode string `json:"mode"` Description string `json:"description,omitempty"` Fields []*Field `json:"fields,omitempty"` }
Field describes the schema of a field in BigQuery.
type MarshalOptions ¶ added in v0.18.0
type MarshalOptions struct { // Indent specifies the set of indentation characters to use in a formatted // output such that every entry is preceded by Indent and terminated by a newline. // Leave Indent empty to disable formatted output. Indent string }
MarshalOptions is a configurable BigQuery schema json marshaller.
func (MarshalOptions) MarshalSchema ¶ added in v0.18.0
func (o MarshalOptions) MarshalSchema(schema bigquery.Schema) ([]byte, error)
MarshalSchema marshals a BigQuery schema to a valid BigQuery JSON schema based on the given MarshalOptions. The JSON conforms to the format in this example: https://cloud.google.com/bigquery/docs/nested-repeated#example_schema
Click to show internal directories.
Click to hide internal directories.