I am trying to get a very simple piece of script to work via Python (Im not sure if this is the right place but please close the thread if its unsuitable)
The script is very simple and works correctly through postgresql
WHERE Table_A."Event" = 'Yes';
When i try to get this script to work through Python i am getting the error message
Table_A."Event" doesnt exist which is clearly not true as i can execute the previous statement without problems
Below is the python code
Any help would be greatly appreciated
conn = psycopg2.connect("dbname='Test_DB' user='Test_User' host='localhost' password='FakePWD'")
print "Unable to connect to the database"
SQLstatement =( "SELECT Table_A.""Event"" "
"FROM public.Table_A "
"WHERE Table_A.""Event"" = 'Yes';")
# Creates a Cursor which you can set an SQL Statement to and fetches the records
cur = conn.cursor()