Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

Considerations and limitations

Focus mode
Considerations and limitations - Amazon Athena

Consider the following points when you use user defined function (UDFs) in Athena.

  • Built-in Athena functions – Built-in functions in Athena are designed to be highly performant. We recommend that you use built-in functions over UDFs when possible. For more information about built-in functions, see Functions in Amazon Athena.

  • Scalar UDFs only – Athena only supports scalar UDFs, which process one row at a time and return a single column value. Athena passes a batch of rows, potentially in parallel, to the UDF each time it invokes Lambda. When designing UDFs and queries, be mindful of the potential impact to network traffic of this processing.

  • UDF handler functions use abbreviated format – Use abbreviated format (not full format), for your UDF functions (for example, package.Class instead of package.Class::method).

  • UDF methods must be lowercase – UDF methods must be in lowercase; camel case is not permitted.

  • UDF methods require parameters – UDF methods must have at least one input parameter. Attempting to invoke a UDF defined without input parameters causes a runtime exception. UDFs are meant to perform functions against data records, but a UDF without arguments takes in no data, so an exception occurs.

  • Java runtime support – Currently, Athena UDFs support the Java 8 and Java 11 runtimes for Lambda. For more information, see Building Lambda functions with Java in the AWS Lambda Developer Guide.

  • IAM permissions – To run and create UDF query statements in Athena, the IAM principal running the query must be allowed to perform actions in addition to Athena functions. For more information, see Allow access to Athena UDFs: Example policies.

  • Lambda quotas – Lambda quotas apply to UDFs. For more information, see Lambda quotas in the AWS Lambda Developer Guide.

  • Row-level filtering – Lake Formation row-level filtering is not supported for UDFs.

  • Views – You cannot use views with UDFs.

  • Known issues – For the most up-to-date list of known issues, see Limitations and issues in the awslabs/aws-athena-query-federation section of GitHub.

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.