Using Boto3 to interact with amazon Aurora on RDS

故事扮演 提交于 2020-01-14 07:17:19

问题


I have set up a database in Amazon RDS using Amazon Aurora and would like to interact with the database using Python - the obvious choice is to use Boto.

However, their documentation is awful and does nopt cover ways in which I can interact with the databse to:

  • Run queries with SQL statements
  • Interact with the tables in the database
  • etc

Does anyone have an links to some examples/tutorials, or know how to do these tasks?


回答1:


When using Amazon RDS offerings (including Aurora), you don't connect to the database via any AWS API (including Boto). Instead you would use the native client of your chosen database. In the case of Aurora, you would connect using the MySQL Command Line client. From there, you can query it just like any other MySQL database.

There's a brief section of the "Getting Started" documentation that talks about connecting to your Aurora database:

Connecting to an Amazon Aurora DB Cluster



来源:https://stackoverflow.com/questions/35468372/using-boto3-to-interact-with-amazon-aurora-on-rds

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!