Re: Load Data with COPY

From: Raymond O'Donnell <rod(at)iol(dot)ie>
To: dpopova(at)uvic(dot)ca, pgsql-general(at)postgresql(dot)org
Subject: Re: Load Data with COPY
Date: 2015-03-24 21:16:26
Message-ID: 5511D42A.6020703@iol.ie
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 24/03/2015 21:00, dpopova(at)uvic(dot)ca wrote:
> I have 7,000+ rows of data in Numbers. Exported to .csv file, tried to
> load into postgres table with COPY FROM, failed. Postgres does not
> recognize the format:
>
> ERROR: invalid input syntax for integer: "project_name,...
>
> Is there any way to export/convert the data in Numbers into a format
> recognizable by postgres?
> Mac OS 10.10.6; postgres 9.3.5.2

Well, the error says that you're trying to load a string,
"project_name", into an integer column.

Is there a header row in the CSV file? - if so, delete it and try again.

Ray.

--
Raymond O'Donnell :: Galway :: Ireland
rod(at)iol(dot)ie

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message John R Pierce 2015-03-24 21:34:05 Re: Load Data with COPY
Previous Message dpopova 2015-03-24 21:00:29 Load Data with COPY