Re: Syntax Error Inserting From STDIN?

From: Scott Marlowe <smarlowe(at)g2switchworks(dot)com>
To: Hunter's Lists <lists(at)lastonepicked(dot)com>
Cc: PostgreSQL <pgsql-general(at)postgresql(dot)org>
Subject: Re: Syntax Error Inserting From STDIN?
Date: 2005-12-20 22:41:32
Message-ID: 1135118492.18741.15.camel@state.g2switchworks.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

quick answer, try a different editor.

Are you editing in the same environment as the database is in, or are
you editing on windows and feeding the copy data in on another platform?

On Tue, 2005-12-20 at 14:40, Hunter's Lists wrote:
> Interesting.
>
> How would I go about solving that?
>
> I inserted an extra line between the two, no dice.
>
> > From: Scott Marlowe <smarlowe(at)g2switchworks(dot)com>
> > Date: Tue, 20 Dec 2005 13:53:37 -0600
> > To: Hunter's Lists <lists(at)lastonepicked(dot)com>
> > Cc: PostgreSQL <pgsql-general(at)postgresql(dot)org>
> > Subject: Re: [GENERAL] Syntax Error Inserting From STDIN?
> >
> > On Tue, 2005-12-20 at 13:30, Hunter's Lists wrote:
> >> I am trying to run the following:
> >>
> >> COPY departments (id, issue_id, title, description, feature_type) FROM
> >> stdin;
> >> 23 4 Local Buzz Things to do, people to see, places to go. aspen
> >>
> >> I get back:
> >>
> >> COPY departments (id, issue_id, title, description, feature_type) FROM
> >> stdin;
> >>
> >> 23 4 Local Buzz Things to do, people to see, places to go. aspen
> >>
> >> ERROR: syntax error at or near "23" at character 80
> >
> > Seeing that "character 80" I'm gonna guess this is a CR/LF issue. I.e.
> > pgsql on your machine is seeing the 23 as being on the same line as the
> > copy departments statement.
>
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Hunter's Lists 2005-12-20 23:04:56 Re: Syntax Error Inserting From STDIN?
Previous Message Tom Lane 2005-12-20 21:49:14 Re: Syntax Error Inserting From STDIN?