- Newest
- Most votes
- Most comments
The above error will occur if you try to use features not supported by Athena as described in this document [1]. In your case Athena is complaining about the regexp_substr function used in your query.
See the list of Presto features supported by Athena :- https://docs.aws.amazon.com/athena/latest/ug/presto-functions.html
I looked for the "regexp_substr" function and found it to be an Oracle/PLSQL function. We recommend using an alternative regular expression function supported by Presto, such as regexp_extract. See [2] for a list of whether Presto supports regular expression functions. Alternatively, you can use custom functions in Athena to achieve your use case. See [3] which explains how to create and use custom functions in Athena.
References:
[1]https://aws.amazon.com/premiumsupport/knowledge-center/athena-syntax-function-not-registered/
[2]https://docs.aws.amazon.com/athena/latest/ug/presto-functions.html
[3]https://docs.aws.amazon.com/athena/latest/ug/querying-udf.html
Relevant content
- asked 3 years ago
