Class: Google::Apis::BigqueryV2::ExternalDataConfiguration
- Inherits:
-
Object
- Object
- Google::Apis::BigqueryV2::ExternalDataConfiguration
- 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
-
#autodetect ⇒ Boolean
(also: #autodetect?)
Try to detect schema and format options automatically.
-
#bigtable_options ⇒ Google::Apis::BigqueryV2::BigtableOptions
[Optional] Additional options if sourceFormat is set to BIGTABLE.
-
#compression ⇒ String
[Optional] The compression type of the data source.
-
#csv_options ⇒ Google::Apis::BigqueryV2::CsvOptions
Additional properties to set if sourceFormat is set to CSV.
-
#google_sheets_options ⇒ Google::Apis::BigqueryV2::GoogleSheetsOptions
[Optional] Additional options if sourceFormat is set to GOOGLE_SHEETS.
-
#hive_partitioning_mode ⇒ String
[Optional, Trusted Tester] If hive partitioning is enabled, which mode to use.
-
#hive_partitioning_options ⇒ Google::Apis::BigqueryV2::HivePartitioningOptions
[Optional, Trusted Tester] Options to configure hive partitioning support.
-
#ignore_unknown_values ⇒ Boolean
(also: #ignore_unknown_values?)
[Optional] Indicates if BigQuery should allow extra values that are not represented in the table schema.
-
#max_bad_records ⇒ Fixnum
[Optional] The maximum number of bad records that BigQuery can ignore when reading data.
-
#schema ⇒ Google::Apis::BigqueryV2::TableSchema
[Optional] The schema for the data.
-
#source_format ⇒ String
[Required] The data format.
-
#source_uris ⇒ Array<String>
[Required] The fully-qualified URIs that point to your data in Google Cloud.
Instance Method Summary collapse
-
#initialize(**args) ⇒ ExternalDataConfiguration
constructor
A new instance of ExternalDataConfiguration.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ ExternalDataConfiguration
Returns a new instance of ExternalDataConfiguration
1690 1691 1692 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1690 def initialize(**args) update!(**args) end |
Instance Attribute Details
#autodetect ⇒ Boolean Also known as: autodetect?
Try to detect schema and format options automatically. Any option specified
explicitly will be honored.
Corresponds to the JSON property autodetect
1598 1599 1600 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1598 def autodetect @autodetect end |
#bigtable_options ⇒ Google::Apis::BigqueryV2::BigtableOptions
[Optional] Additional options if sourceFormat is set to BIGTABLE.
Corresponds to the JSON property bigtableOptions
1604 1605 1606 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1604 def @bigtable_options end |
#compression ⇒ String
[Optional] The compression type of the data source. Possible values include
GZIP and NONE. The default value is NONE. This setting is ignored for Google
Cloud Bigtable, Google Cloud Datastore backups and Avro formats.
Corresponds to the JSON property compression
1611 1612 1613 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1611 def compression @compression end |
#csv_options ⇒ Google::Apis::BigqueryV2::CsvOptions
Additional properties to set if sourceFormat is set to CSV.
Corresponds to the JSON property csvOptions
1616 1617 1618 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1616 def @csv_options end |
#google_sheets_options ⇒ Google::Apis::BigqueryV2::GoogleSheetsOptions
[Optional] Additional options if sourceFormat is set to GOOGLE_SHEETS.
Corresponds to the JSON property googleSheetsOptions
1621 1622 1623 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1621 def @google_sheets_options end |
#hive_partitioning_mode ⇒ String
[Optional, Trusted Tester] If hive partitioning is enabled, which mode to use.
Two modes are supported: - AUTO: automatically infer partition key name(s) and
type(s). - STRINGS: automatic infer partition key name(s). All types are
strings. Not all storage formats support hive partitioning -- requesting hive
partitioning on an unsupported format will lead to an error. Note: this
setting is in the process of being deprecated in favor of
hivePartitioningOptions.
Corresponds to the JSON property hivePartitioningMode
1632 1633 1634 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1632 def hive_partitioning_mode @hive_partitioning_mode end |
#hive_partitioning_options ⇒ Google::Apis::BigqueryV2::HivePartitioningOptions
[Optional, Trusted Tester] Options to configure hive partitioning support.
Corresponds to the JSON property hivePartitioningOptions
1637 1638 1639 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1637 def @hive_partitioning_options end |
#ignore_unknown_values ⇒ Boolean Also known as: ignore_unknown_values?
[Optional] Indicates if BigQuery should allow extra values that are not
represented in the table schema. If true, the extra values are ignored. If
false, records with extra columns are treated as bad records, and if there are
too many bad records, an invalid error is returned in the job result. The
default value is false. The sourceFormat property determines what BigQuery
treats as an extra value: CSV: Trailing columns JSON: Named values that don't
match any column names Google Cloud Bigtable: This setting is ignored. Google
Cloud Datastore backups: This setting is ignored. Avro: This setting is
ignored.
Corresponds to the JSON property ignoreUnknownValues
1650 1651 1652 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1650 def ignore_unknown_values @ignore_unknown_values end |
#max_bad_records ⇒ Fixnum
[Optional] The maximum number of bad records that BigQuery can ignore when
reading data. If the number of bad records exceeds this value, an invalid
error is returned in the job result. This is only valid for CSV, JSON, and
Google Sheets. The default value is 0, which requires that all records are
valid. This setting is ignored for Google Cloud Bigtable, Google Cloud
Datastore backups and Avro formats.
Corresponds to the JSON property maxBadRecords
1661 1662 1663 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1661 def max_bad_records @max_bad_records end |
#schema ⇒ Google::Apis::BigqueryV2::TableSchema
[Optional] The schema for the data. Schema is required for CSV and JSON
formats. Schema is disallowed for Google Cloud Bigtable, Cloud Datastore
backups, and Avro formats.
Corresponds to the JSON property schema
1668 1669 1670 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1668 def schema @schema end |
#source_format ⇒ String
[Required] The data format. For CSV files, specify "CSV". For Google sheets,
specify "GOOGLE_SHEETS". For newline-delimited JSON, specify "
NEWLINE_DELIMITED_JSON". For Avro files, specify "AVRO". For Google Cloud
Datastore backups, specify "DATASTORE_BACKUP". [Beta] For Google Cloud
Bigtable, specify "BIGTABLE".
Corresponds to the JSON property sourceFormat
1677 1678 1679 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1677 def source_format @source_format end |
#source_uris ⇒ Array<String>
[Required] The fully-qualified URIs that point to your data in Google Cloud.
For Google Cloud Storage URIs: Each URI can contain one '' wildcard character
and it must come after the 'bucket' name. Size limits related to load jobs
apply to external data sources. For Google Cloud Bigtable URIs: Exactly one
URI can be specified and it has be a fully specified and valid HTTPS URL for a
Google Cloud Bigtable table. For Google Cloud Datastore backups, exactly one
URI can be specified. Also, the '' wildcard character is not allowed.
Corresponds to the JSON property sourceUris
1688 1689 1690 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1688 def source_uris @source_uris end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 |
# File 'generated/google/apis/bigquery_v2/classes.rb', line 1695 def update!(**args) @autodetect = args[:autodetect] if args.key?(:autodetect) @bigtable_options = args[:bigtable_options] if args.key?(:bigtable_options) @compression = args[:compression] if args.key?(:compression) @csv_options = args[:csv_options] if args.key?(:csv_options) @google_sheets_options = args[:google_sheets_options] if args.key?(:google_sheets_options) @hive_partitioning_mode = args[:hive_partitioning_mode] if args.key?(:hive_partitioning_mode) @hive_partitioning_options = args[:hive_partitioning_options] if args.key?(:hive_partitioning_options) @ignore_unknown_values = args[:ignore_unknown_values] if args.key?(:ignore_unknown_values) @max_bad_records = args[:max_bad_records] if args.key?(:max_bad_records) @schema = args[:schema] if args.key?(:schema) @source_format = args[:source_format] if args.key?(:source_format) @source_uris = args[:source_uris] if args.key?(:source_uris) end |