python PyGreSQL

读书笔记 Add comments

postgres 官方推荐的python Postgres SQL 编程接口

下载地址:http://www.pygresql.org/readme.html

pg 模块文档

ex

  1. import pg
  2.  
  3. conn = pg.connect(dbname='zz', host='10.20.60.90', user='postgres', passwd='postgres')
  4. data = conn.query('select version();').getresult()
  5. print data

Leave a Reply

You must be logged in to post a comment.

Thx N.Design Studio for this Theme
Entries RSS Comments RSS Log in