寒玉 Blog
  • Home
  • Books
  • About Me
  • Categories
  • Tags
  • Archives

idea-查询athena


在使用aws的云服务的时候,我们把数据存储在s3上,如果要查询数据,可以使用aws的athena服务.athena基于Presto构建,可以查询S3的数据.

使用idea访问aws服务

配置idea的数据驱动

2019-03-28-17-41-37

  • 名称填写athena
  • 驱动类选择com.simbaathena.jdbc42.Driver
  • Dialect 选择Generic SQL
  • URL templates格式如下:
  • jdbc:awsathena://athena.[{host::eu-west-1}].amazonaws.com[:{port::443}][\?<;,UID={user:param},PWD={password:param},{:identifier}={:param}>]
  • 点击保存之后,在左侧的列表中可以看见一个Athena的Driver项目

创建连接

2019-03-28-17-50-15

  • name选项输入自己的连接名字
  • user输入自己aws的access key
  • password输入自己aws的Secret key
  • url按照之前的连接填写

这样操作之后就可以在idea中访问到aws的athena服务了.

查询数据

2019-03-28-17-57-44

这样就可以和其他数据源一样操作athena上的数据了.

参考

  • using-aws-athena-from-intellij-based-ide
  • Setting up AWS Athena datasource in JetBrains DataGrip
  • 将Athena与JDBC驱动程序结合使用
  • aws driver 安装与说明

  • « linux小技巧
  • flink源码系列-监控 »

Published

3 28, 2019

Category

aws

Tags

  • athena 3
  • aws 3
  • idea 1
  • Powered by Pelican. Theme: Elegant by Talha Mansoor