Reputation: 1475
I'm moving data from MySQL table that has columns of types :
binary(8)
varbinary(16)
And I can't find the equivalent types in BigQuery documentation https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types
What are the equivalent types? I need to know what to choose for the creation of the table in BigQuery
Upvotes: 0
Views: 2121
Reputation: 33755
BigQuery simply provides a BYTES
type, which is of variable length. To write a bytes literal, you prefix the string with b
, e.g.
SELECT b'\x10\x33';
You can read more in the data types documentation. Note that the BigQuery UI shows BYTES values in base64 format.
Upvotes: 4