play_common.py 文件源码

python
阅读 27 收藏 0 点赞 0 评论 0

项目:ansibleProject 作者: waitig 项目源码 文件源码
def get_connect(self):
        db = cx_Oracle.connect(self.username, self.password, self.host_string)

        # print db.version
        # versioning = db.version.split('.')
        # if versioning[0] == '10':
        #     print "Running 10g"
        # elif versioning[0] == '9':
        #     print "Running 9i"
        # print db.dsn

        # sql = 'SELECT * FROM' + self.table_name
        # # cursor.execute('SELECT * FROM %s',str)
        # cursor.execute(sql)
        # # pprint(cursor.fetchall())
        #
        # # for row in cursor:  ## notice that this is plain English!
        # #     print row
        #
        # column_data_types = cursor.execute('SELECT * FROM ADP_D_HOST')
        #
        # print column_data_types
        #
        # pprint(cursor.description)
        return db.cursor()
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号