替换第一次出现。在蜂巢中

时间:2017-03-17 12:43:31

标签: hive hql

我想在列的字符串中找到第一个点(.)并将其替换为文本。

尝试Regexp_replace,但找不到

1 个答案:

答案 0 :(得分:0)

hive> select regexp_replace ('Hello ... World ...','^(.*?)\\.','$1{text}'); 

Hello {text}.. World ...