sql alchemy - run a statement , postgres

This code example demonstrates Python programming techniques and best practices.

from sqlalchemy import create_engine
engine = create_engine('postgresql://<user>:<password>@localhost:5432/<database_name>')
engine.connect().execute("SQL TO EXECUTE")

Language: Python
Original Source: BlogEngine.NET Migration
Code Lines: 10

 

sql alchemy - run a statement , postgres

from sqlalchemy import create_engine engine = create_engine('postgresql://<user>:<password&