psycopg2 for insertion of binary data to PostgreSQL database

Julia Jacobson julia.jacobson at arcor.de
Mon Aug 23 03:37:13 EDT 2010


How can I assign the result of a SQL query to a variable?
The following code snippet doesn't work:
query_result=cur.execute("SELECT column_name FROM table_name WHERE 
my_variable = 'my_value'",)

 > Thomas Jollans wrote:
>
> * get the record you're interested in



More information about the Python-list mailing list