Use the Amazon Athena SQL editor in EMR Studio - Amazon EMR

Use the Amazon Athena SQL editor in EMR Studio

Overview

You can use Amazon EMR Studio to develop and run interactive queries on Amazon Athena. That means that you can perform SQL analytics on Athena from the same EMR Studio interface that you use to run your Spark, Scala, and other workloads. With this integration, you can use auto-completion to develop queries quickly, browse data in your AWS Glue Data Catalog, create saved queries, view your query history, and more.

For more information on using Amazon Athena, see Using Athena SQL in the Amazon Athena User Guide.

Use the Athena SQL editor in EMR Studio

Use the following steps to develop and run interactive queries on Amazon Athena from your EMR Studio:

  1. Add the required permissions to the user role for the users who access the Workspaces in this Studio. The permissions are listed in the AWS Identity and Access Management permissions for EMR Studio users table in the column Access Amazon Athena SQL editor from your EMR Studio. Alternatively, you can choose to copy the Advanced policy contents from the Example user policies to grant users full permissions to EMR Studio capabilities including this one.

  2. Set up and create an EMR Studio.

  3. Navigate to your Studio and select Query editor from the sidebar.

You should now see the familiar Athena editor UI. For information on getting started and using Athena SQL to run interactive queries, see Getting started and Using Athena SQL in the Amazon Athena User Guide.

Note

If you have enabled trusted identity propagation through IAM Identity Center for your EMR Studio, then you must use Athena workgroups to control query access, and the workgroup that you use must also use trusted identity propagation. For steps to set up Identity Center and enable trusted identity propagation for your workgroup, see Using IAM Identity Center enabled Athena workgroups in the Amazon Athena User Guide.

Considerations for using the Athena SQL editor in EMR Studio

  • Integration with Athena is available in all commercial Regions where EMR Studio and Athena are available.

  • The following Athena features are not available in EMR Studio:

    • Admin features like creating or updating Athena workgroups, data sources, or capacity reservations

    • Athena for Spark or Spark notebooks

    • Amazon DataZone integration

    • Cost Based Optimizer (CBO)

    • Step functions