如何在BigQuery(免费版本)中上传大型数据集?

huangapple go评论54阅读模式
英文:

How to upload Large Datasets in BigQuery (Free Version)?

问题

我正在进行Cyclistic营销案例研究 - Google毕业项目,这是Google数据分析课程的一部分。我使用Excel进行处理,但我想在BigQuery中进行操作。

当我使用Excel上传到BigQuery时(CSV文件有100,000+行),它未成功上传,因为它有16,000行的限制。

是否有其他方法可以将CSV文件上传到BigQuery?请帮助我。谢谢。

英文:

I am working on Cyclistic Marketing Case Study - Google Capstone Project, a part of Google Data Analytics Program. I used Excel to process but I want to like to manipulate in Big Query.

When I uploaded it to Big Query using Excel (CSV files 100,000+rows), it did not push because it has a limit of 16,000 rows.

Is there another way to upload CSV files to BigQuery? Please help me. Thank you.

答案1

得分: 1

您可以将CSV文件上传到GCS存储桶,然后按照此文档将其上传到BigQuery。

您可以按照以下步骤将CSV文件加载到BQ中:

步骤1. 在Google Cloud控制台中,转到BigQuery页面。在资源管理器窗格中,展开您的项目,然后创建一个数据集。

步骤2. 在数据集信息部分,点击3个点,然后选择创建表。在创建表面板中,指定以下详细信息:

  • 在来源部分,从列表中选择Google Cloud Storage中的Create table。然后执行以下操作:
  1. 从云存储桶中选择文件,或输入云存储URI。您不能在Google Cloud控制台中包含多个URI,但支持通配符。云存储桶必须与包含您要创建、追加或覆盖的表的数据集位于同一位置。

  2. 对于文件格式,请选择CSV。

  • 根据您的需求设置目标部分和模式部分。

步骤3. 点击创建表。

英文:

You can upload the CSV file in a GCS bucket and then upload it to BigQuery by following this Document.

You can follow below steps for loading the csv file into BQ

Step 1. In the Google Cloud console, go to the BigQuery page. In the Explorer pane, expand your project, and then create a dataset.

Step2. In the Dataset info section, click 3 dots then Create table. In the Create table panel, specify the following details:

  • In the Source section, select Google Cloud Storage in the Create table from the list. Then, do the following :
  1. Select file from the cloud storage bucket, or enter the cloud storage URI. You cannot include multiple URIs in the Google Cloud console, but wildcards are supported. The Cloud storage bucket must be in the same location as the dataset that contains the table you want to create, append, or overwrite.

  2. For File format, select CSV.

  • Setup the the Destination section and schema section as per your requirement.

Step3. Click the Create table.

huangapple
  • 本文由 发表于 2023年6月16日 11:27:48
  • 转载请务必保留本文链接:https://go.coder-hub.com/76486790.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定