【问题标题】:Apache Drill SYSTEM ERROR: UnsupportedOperationException: Unsupported formatApache Drill 系统错误:UnsupportedOperationException:不支持的格式
【发布时间】:2016-10-18 14:58:35
【问题描述】:

我正在使用 Drill 的 CTAS 函数来创建我的输出的 json 文件。我收到以下错误。

org.apache.drill.common.exceptions.UserRemoteException:系统错误:UnsupportedOperationException:工作区“hivetest1.hive”中不支持的格式“null”[错误 ID:centos6.qubida 上的 3e74fde2-b2e5-4799-a4f9-0236d003ab31。 io:31010]

如果我也在 defaultInputFormat 中使用 json,也会发生同样的错误。 工作区中不支持的格式“json”。我试图删除 defaultInputFormat 本身。但无法创建工作区。

我的存储空间是

{
  "type": "file",
  "enabled": true,
  "connection": "file:///",
  "config": null,
  "workspaces": {
    "hive": {
      "location": "/tmp/",
      "writable": true,
      "defaultInputFormat": null
    }
  },
  "formats": {
    "json": {
      "type": "json",
      "extensions": [
        "json"
      ]
    }
  }

我什至尝试过使用不同的 defaultInputFormat。我也将 store.format 设置为 JSON。我已将 store.mongo.all_text_mode 也更改为 true.store.json.all_text_mode 也是如此。但是,我仍然遇到同样的错误。需要改变什么。我正在使用钻头 1.6。我的 CTAS 查询是

create table hivetest1.hive.`output_json` as select distinct buildingid, country, temprange from hive.`sensorfiles`.`hvac_building` where extremetemp = '1'

我可以单独查看搜索查询的输出。有什么想法吗?

【问题讨论】:

    标签: apache-drill


    【解决方案1】:

    我试图复制您的问题。但它正在工作。

    我所做的只是:

    • 在嵌入式模式下开始钻取 1.6
    • 添加了您在问题中提到的插件
    • alter session set `store.format`='json';
    • create table hivetest1.hive.`output.json` as SELECT * FROM cp.`employee.json` LIMIT 20;

    一切正常。

    【讨论】:

    • 有没有要求我选择的表必须是json?
    • 即使对于 json 表也会出现相同的错误。有关如何配置钻头的任何问题?
    • 我能够保存为 0_0_0.parquet 文件,即使我将输出设置为 json 文件。当我从格式中删除 json 格式时会发生这种情况。有什么建议吗?
    • @Krishna 在选择查询中不可以使用任何表或文件。
    • @Krishna 是默认的 store.formatparquet 转到:localhost:8047/options 并检查
    猜你喜欢
    • 1970-01-01
    • 2012-08-02
    • 1970-01-01
    • 2018-02-05
    • 2011-07-14
    • 1970-01-01
    • 1970-01-01
    • 2019-09-14
    • 1970-01-01
    相关资源
    最近更新 更多