【问题标题】:How to get schema of input in exec function in Pig UDF如何在 Pig UDF 的 exec 函数中获取输入模式
【发布时间】:2012-11-08 22:48:17
【问题描述】:

我想知道当我在 Piglatin 中构建 UDF 时,如何在 exec() 函数中获取输入模式。我可以从 outputSchema() 函数获取架构,但看起来后端函数无法利用结果。

任何提示将不胜感激!

【问题讨论】:

    标签: apache-pig udf


    【解决方案1】:

    据我所知,Pig 的 UDF (EvalFunc) 中有一个 getInputSchema 方法。你试过了吗?

    https://pig.apache.org/docs/r0.11.1/api/org/apache/pig/EvalFunc.html

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2012-11-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多