google-cloud-bigquery 1.55.0 → 1.56.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 448f588a59a05dce2bc2deacac8b9976042ad075d2d88ab7c2f03cf26ed2e7ce
4
- data.tar.gz: 685ab418b60a7acc5f0b6d5ca806e7beb0d207d68fca21080d72eaba8c9f8922
3
+ metadata.gz: 3485b40defd1415a416e32191f08ab9fbb204679b74a7aa3798497b6106279af
4
+ data.tar.gz: 0f4edb30dcd40818937a90cc4e746ab79964201cdd02d3145a997e273d062523
5
5
  SHA512:
6
- metadata.gz: 586615af0965f08ab9d2aed90d884ede5a4ccbeb3ead1aa82ac6d79d82faa9f84e26890c0a42ff353658ff3a2de378d0bab279dd9d28324bb9cec9d39cd44025
7
- data.tar.gz: d484969612d8e0ed84a3aef824a606d45a98a376e62129b45b13318099d4b1dbe2c327983b92c06176a0e29046c0df996dda4efd9aa7c7f4d638274cf506ddcc
6
+ metadata.gz: 7caacb39dd2694de5dd70470274db28893f9841c17321c72b6b1ed82c2abc1c1f8b9ed65bf65271b2fc62939234b82fdc24150108ad6617093f938af278532b7
7
+ data.tar.gz: 97807b56c6ff51d7f039c30f2c096617e8ce76e12f4d9017e4e63bde6e705a1200b052c7b403a7c70c15e0565f8657f19186d2055bac4f59f4df8db7b4b73449
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Release History
2
2
 
3
+ ### 1.56.0 (2025-08-27)
4
+
5
+ #### Features
6
+
7
+ * Add support for preserve_ascii_control_characters in CSVOptions and LoadJobConfiguration ([#30857](https://github.com/googleapis/google-cloud-ruby/issues/30857))
8
+
3
9
  ### 1.55.0 (2025-08-26)
4
10
 
5
11
  #### Features
@@ -538,6 +538,53 @@ module Google
538
538
  @gapi.csv_options.source_column_match = source_column_match
539
539
  end
540
540
 
541
+ # Indicates if the embedded ASCII control characters (the first 32
542
+ # characters in the ASCII-table, from `\x00` to `\x1F`) are preserved.
543
+ # By default, ASCII control characters are not preserved.
544
+ #
545
+ # @return [Boolean, nil] whether or not ASCII control characters are
546
+ # preserved. `nil` if not set.
547
+ #
548
+ # @example
549
+ # require "google/cloud/bigquery"
550
+ #
551
+ # bigquery = Google::Cloud::Bigquery.new
552
+ #
553
+ # csv_url = "gs://bucket/path/to/data.csv"
554
+ # csv_table = bigquery.external csv_url do |csv|
555
+ # csv.preserve_ascii_control_characters = true
556
+ # end
557
+ #
558
+ # csv_table.preserve_ascii_control_characters #=> true
559
+ #
560
+ def preserve_ascii_control_characters
561
+ @gapi.csv_options.preserve_ascii_control_characters
562
+ end
563
+
564
+ # Sets whether the embedded ASCII control characters (the first 32
565
+ # characters in the ASCII-table, from `\x00` to `\x1F`) are preserved.
566
+ # By default, ASCII control characters are not preserved.
567
+ #
568
+ # @param [Boolean, nil] val whether or not ASCII control characters
569
+ # are preserved. `nil` to unset.
570
+ #
571
+ # @example
572
+ # require "google/cloud/bigquery"
573
+ #
574
+ # bigquery = Google::Cloud::Bigquery.new
575
+ #
576
+ # csv_url = "gs://bucket/path/to/data.csv"
577
+ # csv_table = bigquery.external csv_url do |csv|
578
+ # csv.preserve_ascii_control_characters = true
579
+ # end
580
+ #
581
+ # csv_table.preserve_ascii_control_characters #=> true
582
+ #
583
+ def preserve_ascii_control_characters= val
584
+ frozen_check!
585
+ @gapi.csv_options.preserve_ascii_control_characters = val
586
+ end
587
+
541
588
  ##
542
589
  # The schema for the data.
543
590
  #
@@ -736,6 +736,18 @@ module Google
736
736
  @gapi.configuration.load.time_zone
737
737
  end
738
738
 
739
+ ##
740
+ # When source_format is set to `CSV`, indicates if the embedded ASCII
741
+ # control characters (the first 32 characters in the ASCII-table, from
742
+ # `\x00` to `\x1F`) are preserved. By default, ASCII control
743
+ # characters are not preserved.
744
+ #
745
+ # @return [Boolean, nil] whether or not ASCII control characters are
746
+ # preserved. `nil` if not set.
747
+ def preserve_ascii_control_characters
748
+ @gapi.configuration.load.preserve_ascii_control_characters
749
+ end
750
+
739
751
  ##
740
752
  # Yielded to a block to accumulate changes for a patch request.
741
753
  class Updater < LoadJob
@@ -2752,6 +2764,18 @@ module Google
2752
2764
  @gapi.configuration.load.update! time_zone: time_zone
2753
2765
  end
2754
2766
 
2767
+ ##
2768
+ # When source_format is set to `CSV`, sets whether the embedded ASCII
2769
+ # control characters (the first 32 characters in the ASCII-table, from
2770
+ # `\x00` to `\x1F`) are preserved. By default, ASCII control
2771
+ # characters are not preserved.
2772
+ #
2773
+ # @param [Boolean, nil] val whether or not ASCII control characters
2774
+ # are preserved. `nil` to unset.
2775
+ def preserve_ascii_control_characters= val
2776
+ @gapi.configuration.load.update! preserve_ascii_control_characters: val
2777
+ end
2778
+
2755
2779
  def cancel
2756
2780
  raise "not implemented in #{self.class}"
2757
2781
  end
@@ -16,7 +16,7 @@
16
16
  module Google
17
17
  module Cloud
18
18
  module Bigquery
19
- VERSION = "1.55.0".freeze
19
+ VERSION = "1.56.0".freeze
20
20
  end
21
21
  end
22
22
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google-cloud-bigquery
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.55.0
4
+ version: 1.56.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Moore