简体   繁体   English

雅典娜 - CTAS 文件名

[英]Athena - CTAS file name

I used Athena's CTAS and INSERT commands and Avro files created at the external_location But the file name is very strange and the filename extension also disappear.我使用了 Athena 的 CTAS 和 INSERT 命令以及在 external_location 创建的 Avro 文件,但是文件名很奇怪,文件扩展名也消失了。 (That file don't have any filename extension. File has only their strange filename like hash code) How can I define filenames rule for Athena's file? (该文件没有任何文件扩展名。文件只有它们奇怪的文件名,如哈希码)如何为 Athena 的文件定义文件名规则? Thank you.谢谢你。

As stated on page 20 of AWS Athena's manual, ... "This location in Amazon S3 comprises all of the files representing your table. For more information, see Using Folders in the Amazon Simple Storage Service Console User Guide."正如 AWS Athena 手册第 20 页所述,... “Amazon S3 中的此位置包含代表您的表的所有文件。有关更多信息,请参阅 Amazon Simple Storage Service 控制台用户指南中的使用文件夹。” ... ...

Reference : https://docs.aws.amazon.com/athena/latest/ug/athena-ug.pdf参考https : //docs.aws.amazon.com/athena/latest/ug/athena-ug.pdf

So, no, you can't define the name of the file (or files, because more than one may be needed to represent a table).因此,不,您不能定义文件(或多个文件,因为可能需要多个文件来表示一个表)的名称。 BUT THE RIGHT WAY TO THINK is that the BUCKET/PATH is what represents the file name, or the output table.但正确的想法是BUCKET/PATH代表文件名或输出表。

We might get confused because you're genereting and AVRO file, which really is a file, like PARQUET, but remember that Athena can also output to other formats, which may be multi-file.我们可能会感到困惑,因为您正在生成 AVRO 文件,这实际上是一个文件,如 PARQUET,但请记住,Athena 也可以输出为其他格式,可能是多文件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM