I have a database(postgresql) with more than 100 columns and rows. Some cells in the table are empty,I am using python for scripting so None value is placed in empty cells but it shows the following error when I try to insert into table.
" psycopg2.ProgrammingError: column "none" does not exist"
Am using psycopg2 as python-postgres interface............Any suggestions??
Thanks in advance......
Here is my code:-
list1=[None if str(x)=='nan' else x for x in list1];
cursor.execute("""INSERT INTO table VALUES %s""" %list1;
);
;
semicolons. – Martijn Pieters♦ Jan 20 '14 at 17:27list1
hold just one value? Or are you trying to use this for multiple insertions? – Martijn Pieters♦ Jan 20 '14 at 17:39