Re: URGENT: temporary table not recognized?

From: Adrian Klaver <adrian(dot)klaver(at)gmail(dot)com>
To: Phoenix Kiula <phoenix(dot)kiula(at)gmail(dot)com>
Cc: Steve Crawford <scrawford(at)pinpointresearch(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PG-General Mailing List <pgsql-general(at)postgresql(dot)org>
Subject: Re: URGENT: temporary table not recognized?
Date: 2012-01-06 23:54:58
Message-ID: 4F0789D2.9080105@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 01/06/2012 03:42 PM, Phoenix Kiula wrote:
> On Fri, Jan 6, 2012 at 6:20 PM, Adrian Klaver<adrian(dot)klaver(at)gmail(dot)com> wrote:
>
>> http://www.postgresql.org/docs/9.0/interactive/sql-copy.html
>>
>> Search for
>> NULL
>
>
>
> Thanks Adrian.
>
> Without examples, it's hard to predict syntax. If the value after a
> pipe is missing altogether, I suppose the missing value is "\n"
> (newline). But this doesn't work:
>
> copy vl from 'data.txt' WITH DELIMITER AS '|' NULL '\n';
>
> None of these work either:
>
> copy vl from 'data.txt' WITH DELIMITER AS '|' NULL \n;
> copy vl from 'data.txt' WITH DELIMITER AS '|' NULL \\n;
> copy vl from 'data.txt' WITH DELIMITER AS '|' NULL '';

Try:
copy vl from 'data.txt' WITH CSV DELIMITER '|';

If that doesn't work take a look at pgloader:
http://pgfoundry.org/projects/pgloader/

--
Adrian Klaver
adrian(dot)klaver(at)gmail(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Phoenix Kiula 2012-01-06 23:55:42 Re: URGENT: temporary table not recognized?
Previous Message Steve Crawford 2012-01-06 23:53:09 Re: URGENT: temporary table not recognized?