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

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ ViewDefinition

Returns a new instance of ViewDefinition.


6809
6810
6811
# File 'generated/google/apis/bigquery_v2/classes.rb', line 6809

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)

6793
6794
6795
# File 'generated/google/apis/bigquery_v2/classes.rb', line 6793

def query
  @query
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)

6801
6802
6803
# File 'generated/google/apis/bigquery_v2/classes.rb', line 6801

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


6807
6808
6809
# File 'generated/google/apis/bigquery_v2/classes.rb', line 6807

def user_defined_function_resources
  @user_defined_function_resources
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object


6814
6815
6816
6817
6818
# File 'generated/google/apis/bigquery_v2/classes.rb', line 6814

def update!(**args)
  @query = args[:query] if args.key?(:query)
  @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