Class: Google::Apis::BigqueryV2::ViewDefinition

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/bigquery_v2/classes.rb,
lib/google/apis/bigquery_v2/representations.rb,
lib/google/apis/bigquery_v2/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ViewDefinition

Returns a new instance of ViewDefinition.



8852
8853
8854
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8852

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#queryString

[Required] A query that BigQuery executes when the view is referenced. Corresponds to the JSON property query

Returns:

  • (String)


8828
8829
8830
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8828

def query
  @query
end

#use_explicit_column_namesBoolean Also known as: use_explicit_column_names?

True if the column names are explicitly specified. For example by using the ' CREATE VIEW v(c1, c2) AS ...' syntax. Can only be set using BigQuery's standard SQL: https://cloud.google.com/bigquery/sql-reference/ Corresponds to the JSON property useExplicitColumnNames

Returns:

  • (Boolean)


8835
8836
8837
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8835

def use_explicit_column_names
  @use_explicit_column_names
end

#use_legacy_sqlBoolean Also known as: use_legacy_sql?

Specifies whether to use BigQuery's legacy SQL for this view. The default value is true. If set to false, the view will use BigQuery's standard SQL: https://cloud.google.com/bigquery/sql-reference/ Queries and views that reference this view must use the same flag value. Corresponds to the JSON property useLegacySql

Returns:

  • (Boolean)


8844
8845
8846
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8844

def use_legacy_sql
  @use_legacy_sql
end

#user_defined_function_resourcesArray<Google::Apis::BigqueryV2::UserDefinedFunctionResource>

Describes user-defined function resources used in the query. Corresponds to the JSON property userDefinedFunctionResources



8850
8851
8852
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8850

def user_defined_function_resources
  @user_defined_function_resources
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



8857
8858
8859
8860
8861
8862
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8857

def update!(**args)
  @query = args[:query] if args.key?(:query)
  @use_explicit_column_names = args[:use_explicit_column_names] if args.key?(:use_explicit_column_names)
  @use_legacy_sql = args[:use_legacy_sql] if args.key?(:use_legacy_sql)
  @user_defined_function_resources = args[:user_defined_function_resources] if args.key?(:user_defined_function_resources)
end