[AWS] Twitter Analysis ~Part9: Execute queries by applying Amazon Athena~

Purpose

In part 9 section, I would like to explain how to execute queries to S3 bucket which stores analyzed tweet data by utilizing Amazon Athena. Let me show you the scope of this section as below.

Prerequisite
Create table schema by AWS Glue
Firstly, let’s create table schema by AWS Glue which is fully managed ETL (extract, transform, and load) service. The schema can be created by CloudFormation.
Firstly, Open CloudFormation console.

And click With new resources (standard).

And upload yaml file, glue_data_catalog.yaml, which is provided by AWS.
You can download it by below URL.
https://d1.awsstatic.com/Developer%20Marketing/jp/magazine/sample/twitter-dashboard.3e2afda65ad814c5603cadf8c12b8c78822d718d.zip

In this yaml file, three tables, tweets, tweetsentiment and tweetentities, in twitter_timeline_dashboard database are defined.


After creating the Database and Tables, CREATE_COMPLETE message will be displayed.

Execute Query by Amazon Athena
Firstly, open Athena console.

And click Explore the query editor button.

And click View settings button.

Then, set query result location and save it.

Your setting change will be saved as below.

OK, execute any query in Editor section and click Run command.

If your query is correct, query result can be displayed as below.

And the query result will be saved in the S3 bucket.

That’s all for this topic. I hope you could execute query successfully.
In my next article, let me show you how to analyze it by Amazon QuickSight.

Part10
https://eeengineer.com/aws-twitter-analysis-part10-analyze-twitter-data-by-amazon-quicksight/

Reference
Basically, I followed the procedure provided by AWS webpage. Please refer to below URL if necessary, though it is written in Japanese…
If you think this article is beneficial for you, I would be glad if you click below icon for my motivation.
ブログランキング・にほんブログ村へ

コメント