在Windows上的bq load命令中指定管道定界符时,google-bigquery错误 [英] google-bigquery Error while specifying pipe delimiter in bq load command on windows

查看:113
本文介绍了在Windows上的bq load命令中指定管道定界符时,google-bigquery错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试加载PIPE分隔文件并从Windows平台运行bq load命令.它不接受命令中的管道定界符.

I am trying to load a PIPE delimited file and running bq load command from windows platform. It is not accepting pipe delimiter in the command.

例如我正在尝试使用-F运算符来指定定界符,并且可以指定空间定界符,但是当我指定管道定界符时,它将停止工作.

E.g. I am trying to use -F operator to specify the delimiter and could specify space delimiter but it stops working when I specify pipe delimiter.

C:\Windows>bq load -F" " "cmdwh_bq_prod.testtabPIPE"  "c:\temp\testPIPE.txt" PlatformVersion:int64,AnalyticsSessionID:int64,OutletGroup:string
Upload complete.
..... rest of the processing......
..... rest of the processing......

但是当我指定管道定界符时,相同的命令停止工作...

But same command stops working when I specify pipe delimiter...

C:\Windows>bq load -F"|" "cmdwh_bq_prod.testtabPIPE"  "c:\temp\testPIPE.txt" PlatformVersion:int64,AnalyticsSessionID:int64,OutletGroup:string
The filename, directory name, or volume label syntax is incorrect.

C:\Windows>

请提出建议.

推荐答案

这对我有用:

bq加载--source_format = CSV --field_delimiter ="|" dataset.tablename gs://bucket/foldername/filename.txt ./myschema.json

bq load --source_format=CSV --field_delimiter="|" dataset.tablename gs://bucket/foldername/filename.txt ./myschema.json

这篇关于在Windows上的bq load命令中指定管道定界符时,google-bigquery错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆