Class: Google::Apis::BigqueryV2::QueryResponse
- Inherits:
-
Object
- Object
- Google::Apis::BigqueryV2::QueryResponse
- 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
-
#cache_hit ⇒ Boolean
(also: #cache_hit?)
Whether the query result was fetched from the query cache.
-
#creation_time ⇒ Fixnum
Output only.
-
#dml_stats ⇒ Google::Apis::BigqueryV2::DmlStatistics
Detailed statistics for DML statements Corresponds to the JSON property
dmlStats. -
#end_time ⇒ Fixnum
Output only.
-
#errors ⇒ Array<Google::Apis::BigqueryV2::ErrorProto>
Output only.
-
#job_complete ⇒ Boolean
(also: #job_complete?)
Whether the query has completed or not.
-
#job_creation_reason ⇒ Google::Apis::BigqueryV2::JobCreationReason
Reason about why a Job was created from a
jobs.querymethod when used withJOB_CREATION_OPTIONALJob creation mode. -
#job_reference ⇒ Google::Apis::BigqueryV2::JobReference
A job reference is a fully qualified identifier for referring to a job.
-
#kind ⇒ String
The resource type.
-
#location ⇒ String
Output only.
-
#num_dml_affected_rows ⇒ Fixnum
Output only.
-
#page_token ⇒ String
A token used for paging results.
-
#query_id ⇒ String
Auto-generated ID for the query.
-
#rows ⇒ Array<Google::Apis::BigqueryV2::TableRow>
An object with as many results as can be contained within the maximum permitted reply size.
-
#schema ⇒ Google::Apis::BigqueryV2::TableSchema
Schema of a table Corresponds to the JSON property
schema. -
#session_info ⇒ Google::Apis::BigqueryV2::SessionInfo
[Preview] Information related to sessions.
-
#start_time ⇒ Fixnum
Output only.
-
#total_bytes_billed ⇒ Fixnum
Output only.
-
#total_bytes_processed ⇒ Fixnum
The total number of bytes processed for this query.
-
#total_rows ⇒ Fixnum
The total number of rows in the complete query result set, which can be more than the number of rows in this single page of results.
-
#total_slot_ms ⇒ Fixnum
Output only.
Instance Method Summary collapse
-
#initialize(**args) ⇒ QueryResponse
constructor
A new instance of QueryResponse.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ QueryResponse
Returns a new instance of QueryResponse.
8678 8679 8680 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8678 def initialize(**args) update!(**args) end |
Instance Attribute Details
#cache_hit ⇒ Boolean Also known as: cache_hit?
Whether the query result was fetched from the query cache.
Corresponds to the JSON property cacheHit
8548 8549 8550 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8548 def cache_hit @cache_hit end |
#creation_time ⇒ Fixnum
Output only. Creation time of this query, in milliseconds since the epoch.
This field will be present on all queries.
Corresponds to the JSON property creationTime
8555 8556 8557 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8555 def creation_time @creation_time end |
#dml_stats ⇒ Google::Apis::BigqueryV2::DmlStatistics
Detailed statistics for DML statements
Corresponds to the JSON property dmlStats
8560 8561 8562 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8560 def dml_stats @dml_stats end |
#end_time ⇒ Fixnum
Output only. End time of this query, in milliseconds since the epoch. This
field will be present whenever a query job is in the DONE state.
Corresponds to the JSON property endTime
8566 8567 8568 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8566 def end_time @end_time end |
#errors ⇒ Array<Google::Apis::BigqueryV2::ErrorProto>
Output only. The first errors or warnings encountered during the running of
the job. The final message includes the number of errors that caused the
process to stop. Errors here do not necessarily mean that the job has
completed or was unsuccessful. For more information about error messages, see
Error messages.
Corresponds to the JSON property errors
8575 8576 8577 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8575 def errors @errors end |
#job_complete ⇒ Boolean Also known as: job_complete?
Whether the query has completed or not. If rows or totalRows are present, this
will always be true. If this is false, totalRows will not be available.
Corresponds to the JSON property jobComplete
8581 8582 8583 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8581 def job_complete @job_complete end |
#job_creation_reason ⇒ Google::Apis::BigqueryV2::JobCreationReason
Reason about why a Job was created from a jobs.query method when used with
JOB_CREATION_OPTIONAL Job creation mode. For jobs.insert method calls it will
always be REQUESTED.
Corresponds to the JSON property jobCreationReason
8591 8592 8593 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8591 def job_creation_reason @job_creation_reason end |
#job_reference ⇒ Google::Apis::BigqueryV2::JobReference
A job reference is a fully qualified identifier for referring to a job.
Corresponds to the JSON property jobReference
8596 8597 8598 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8596 def job_reference @job_reference end |
#kind ⇒ String
The resource type.
Corresponds to the JSON property kind
8601 8602 8603 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8601 def kind @kind end |
#location ⇒ String
Output only. The geographic location of the query. For more information about
BigQuery locations, see: https://cloud.google.com/bigquery/docs/locations
Corresponds to the JSON property location
8607 8608 8609 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8607 def location @location end |
#num_dml_affected_rows ⇒ Fixnum
Output only. The number of rows affected by a DML statement. Present only for
DML statements INSERT, UPDATE or DELETE.
Corresponds to the JSON property numDmlAffectedRows
8613 8614 8615 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8613 def num_dml_affected_rows @num_dml_affected_rows end |
#page_token ⇒ String
A token used for paging results. A non-empty token indicates that additional
results are available. To see additional results, query the jobs.
getQueryResults method. For more information, see Paging through table
data.
Corresponds to the JSON property pageToken
8622 8623 8624 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8622 def page_token @page_token end |
#query_id ⇒ String
Auto-generated ID for the query.
Corresponds to the JSON property queryId
8627 8628 8629 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8627 def query_id @query_id end |
#rows ⇒ Array<Google::Apis::BigqueryV2::TableRow>
An object with as many results as can be contained within the maximum
permitted reply size. To get any additional rows, you can call GetQueryResults
and specify the jobReference returned above.
Corresponds to the JSON property rows
8634 8635 8636 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8634 def rows @rows end |
#schema ⇒ Google::Apis::BigqueryV2::TableSchema
Schema of a table
Corresponds to the JSON property schema
8639 8640 8641 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8639 def schema @schema end |
#session_info ⇒ Google::Apis::BigqueryV2::SessionInfo
[Preview] Information related to sessions.
Corresponds to the JSON property sessionInfo
8644 8645 8646 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8644 def session_info @session_info end |
#start_time ⇒ Fixnum
Output only. Start time of this query, in milliseconds since the epoch. This
field will be present when the query job transitions from the PENDING state to
either RUNNING or DONE.
Corresponds to the JSON property startTime
8651 8652 8653 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8651 def start_time @start_time end |
#total_bytes_billed ⇒ Fixnum
Output only. If the project is configured to use on-demand pricing, then this
field contains the total bytes billed for the job. If the project is
configured to use flat-rate pricing, then you are not billed for bytes and
this field is informational only.
Corresponds to the JSON property totalBytesBilled
8659 8660 8661 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8659 def total_bytes_billed @total_bytes_billed end |
#total_bytes_processed ⇒ Fixnum
The total number of bytes processed for this query. If this query was a dry
run, this is the number of bytes that would be processed if the query were run.
Corresponds to the JSON property totalBytesProcessed
8665 8666 8667 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8665 def total_bytes_processed @total_bytes_processed end |
#total_rows ⇒ Fixnum
The total number of rows in the complete query result set, which can be more
than the number of rows in this single page of results.
Corresponds to the JSON property totalRows
8671 8672 8673 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8671 def total_rows @total_rows end |
#total_slot_ms ⇒ Fixnum
Output only. Number of slot ms the user is actually billed for.
Corresponds to the JSON property totalSlotMs
8676 8677 8678 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8676 def total_slot_ms @total_slot_ms end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
8683 8684 8685 8686 8687 8688 8689 8690 8691 8692 8693 8694 8695 8696 8697 8698 8699 8700 8701 8702 8703 8704 8705 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 8683 def update!(**args) @cache_hit = args[:cache_hit] if args.key?(:cache_hit) @creation_time = args[:creation_time] if args.key?(:creation_time) @dml_stats = args[:dml_stats] if args.key?(:dml_stats) @end_time = args[:end_time] if args.key?(:end_time) @errors = args[:errors] if args.key?(:errors) @job_complete = args[:job_complete] if args.key?(:job_complete) @job_creation_reason = args[:job_creation_reason] if args.key?(:job_creation_reason) @job_reference = args[:job_reference] if args.key?(:job_reference) @kind = args[:kind] if args.key?(:kind) @location = args[:location] if args.key?(:location) @num_dml_affected_rows = args[:num_dml_affected_rows] if args.key?(:num_dml_affected_rows) @page_token = args[:page_token] if args.key?(:page_token) @query_id = args[:query_id] if args.key?(:query_id) @rows = args[:rows] if args.key?(:rows) @schema = args[:schema] if args.key?(:schema) @session_info = args[:session_info] if args.key?(:session_info) @start_time = args[:start_time] if args.key?(:start_time) @total_bytes_billed = args[:total_bytes_billed] if args.key?(:total_bytes_billed) @total_bytes_processed = args[:total_bytes_processed] if args.key?(:total_bytes_processed) @total_rows = args[:total_rows] if args.key?(:total_rows) @total_slot_ms = args[:total_slot_ms] if args.key?(:total_slot_ms) end |