【问题标题】:BigQuery querying data directly from Storage with Datastore exported fileBigQuery 使用 Datastore 导出文件直接从 Storage 查询数据
【发布时间】:2019-08-02 19:46:19
【问题描述】:

我想知道 BigQuery 是否支持在 Cloud Storage 中查询 Datastore 导出的文件存储? sample code 仅显示如何查询 CSVGOOGLE_SHEETS,但 Datastore 导出的文件是“kinds.export_metadata”。如果支持,ExternalConfig 应该是什么?有什么例子可以参考吗?

欢迎提出任何建议,谢谢。

【问题讨论】:

    标签: google-cloud-platform google-bigquery google-cloud-datastore


    【解决方案1】:

    ExternalConfig 指的是外部源。

    BigQuery 支持Here 中定义的 3 种外部源类型

    云存储文件格式定义here

    逗号分隔值 (CSV)

    JSON(换行符分隔)

    Avro 文件

    云数据存储导出

    Cloud Firestore 导出

    作为参考,这是它在 Python 实现中的样子code from github

    CSV = 'CSV'
        """Specifies CSV format."""
    
        GOOGLE_SHEETS = 'GOOGLE_SHEETS'
        """Specifies Google Sheets format."""
    
        NEWLINE_DELIMITED_JSON = 'NEWLINE_DELIMITED_JSON'
        """Specifies newline delimited JSON format."""
    
        AVRO = 'AVRO'
        """Specifies Avro format."""
    
        DATASTORE_BACKUP = 'DATASTORE_BACKUP'
        """Specifies datastore backup format"""
    
        BIGTABLE = 'BIGTABLE'
        """Specifies Bigtable format."""
    

    因此,如果您的文件是其中一种格式,那么您就可以使用了

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-01-28
      • 2019-05-12
      • 1970-01-01
      • 2013-05-18
      • 1970-01-01
      • 2017-11-13
      • 2015-10-17
      • 2023-04-10
      相关资源
      最近更新 更多