正在尝试在配置单元中执行查询:
select regex_extract(col,'regex',1) from tbl;
验证我使用的正则表达式是否正确。错误:
FAILED: SemanticException [Error 10011]: Invalid function regex_extract
pw136qt21#
考虑使用 regexp_extract 而不是 regex_extract 在Hive里。下面是regexp\u摘录的正确语法:
regexp_extract
regex_extract
regexp_extract(string subject, string pattern, int index)
下面是hive文档中的一个示例
regexp_extract('foothebar', 'foo(.*?)(bar)', 2) returns 'bar.'
1条答案
按热度按时间pw136qt21#
考虑使用
regexp_extract
而不是regex_extract
在Hive里。下面是regexp\u摘录的正确语法:下面是hive文档中的一个示例