Psycopg2 connect tutorial. Execute the select query using the cursor.