运行parquet-tools jar的参数无效

cov*_*efe 5 java jar parquet

我正在尝试使用parquet-tools.jar(https://github.com/Parquet/parquet-mr/tree/master/parquet-tools)从镶木地板文件中打印一列。我正在使用以下命令:

java -jar parquet-tools-1.6.1-SNAPSHOT.jar dump -c COLUMNNAME someParquet.parquet

但是我得到:

Invalid arguments: missing required arguments

usage: parquet-dump [option...] <input>
where option is one of:
    -c,--column <arg>  Dump only the given column, can be specified more than
                       once
    -d,--disable-data  Do not dump column data
       --debug         Enable debug output
    -h,--help          Show this help string
    -m,--disable-meta  Do not dump row group and page metadata
       --no-color      Disable color output even if supported
where <input> is the parquet file to print to stdout
Run Code Online (Sandbox Code Playgroud)

不知道我在哪里弄错了语法。

ska*_*dya 5

选项 -c,--column 认为您已将多个列指定为“转储”commnad 的参数并最终吃掉所有参数。因此,您会看到缺少的需求参数异常。

一种解决方法,我建议您需要在 -c 选项之后添加一个附加选项。这将使 CLI 解析器停止使用 -c 选项的意外参数。

使用下面的命令(添加 --debug 选项),您应该能够执行程序:

java -jar parquet-tools-1.6.1-SNAPSHOT.jar dump -c COLUMNNAME --debug someParquet.parquet
Run Code Online (Sandbox Code Playgroud)

您也可以尝试 --no-color 而不是 --debug 。

希望这可以帮助。