Skip to content

Commit

Permalink
fix: Make generated temp table name escaped (#3797)
Browse files Browse the repository at this point in the history
* Fix critical issue with saving results in BigQuery

Need to encapsulate table path as tmp table path can contain symbols that can't be process by BigQuery without encapsulation

Signed-off-by: Dmytro Miedviediev <beardimon2001@gmail.com>

* update numpy

Signed-off-by: Dmytro Miedviediev <beardimon2001@gmail.com>

* revert numpy version

Signed-off-by: Dmytro Miedviediev <beardimon2001@gmail.com>

---------

Signed-off-by: Dmytro Miedviediev <beardimon2001@gmail.com>
Signed-off-by: James Crabtree <james.crabtree@sailpoint.com>
  • Loading branch information
BearDimonR authored and james-crabtree-sp committed Oct 23, 2023
1 parent c9ad760 commit 27a0b70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sdk/python/feast/infra/offline_stores/bigquery.py
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@ def to_bigquery(
temp_dest_table = f"{tmp_dest['projectId']}.{tmp_dest['datasetId']}.{tmp_dest['tableId']}"

# persist temp table
sql = f"CREATE TABLE `{dest}` AS SELECT * FROM {temp_dest_table}"
sql = f"CREATE TABLE `{dest}` AS SELECT * FROM `{temp_dest_table}`"
self._execute_query(sql, timeout=timeout)

print(f"Done writing to '{dest}'.")
Expand Down

0 comments on commit 27a0b70

Please sign in to comment.