My table,
Table "public.product_status"
Column | Type | Modifiers
--------+-----------------------+-----------
id | integer | not null
code | character varying(10) |
notes | text |
First line of my CSV file,
1,S,blah blah blah
Copy command,
=# copy product_status from 'status_table.csv' with csv;
ERROR: invalid input syntax for integer: "1"
CONTEXT: COPY product_status, line 1, column id: "1"
Really don't understand how that's invalid syntax for an integer! Even postgres seems to agree with me,
=# insert into product_status values (1,'S','blah blah blah');
=# copy product_status to STDOUT with csv;
1,S,blah blah blah
Any ideas? Other questions I found on the site didn't seem applicable to whatever I've done wrong here.