#!/usr/bin/env python
# -*- coding: utf-8 -*-
from sqlalchemy import create_engine
connection = create_engine('mysql://user:[email protected]:3306/db').connect()
result = connection.execute("select * from table")
for v in result:
print v['id']
print v['name']
connection.close()
cách tôi có thể nhận TABLES COLUMNS NAMES động? trong trường hợp này id
và name
python sqlalchemy có được tên cột động?
không làm việc trong SQLAlchemy 1.1 – Ken