Search Postgresql Archives

Re: ora2pg and invalid command \N

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Mar 16, 2018 at 8:28 PM, Adrian Klaver
<adrian.klaver@xxxxxxxxxxx> wrote:
> On 03/16/2018 11:36 AM, Charlin Barak wrote:
>>
>> Thanks for your response.
>>
>> the NULL values from Oracle were indeed replaced by \N in the data output.
>> How do I go about loading this file? I hope I do not have to temporary
>> replace \N with a string in the flat file and then later update in Postgres.
>
>
> That should not be necessary:
>
> https://www.postgresql.org/docs/10/static/sql-copy.html
>
> "NULL
>
>     Specifies the string that represents a null value. The default is \N
> (backslash-N) in text format, and an unquoted empty string in CSV format.
> You might prefer an empty string even in text format for cases where you
> don't want to distinguish nulls from empty strings. This option is not
> allowed when using binary format."
>
>
> To  solve this is going to require more information. From my previous post:
>
> What was the complete command you used to generate the data file?
>
> Can we see the complete error?
>
> Also a section of the data file that contains the data that caused the
> error?

I pinged the original author, and he thinks it might be because of a
nested user defined type.  If that's the case, you should try with
current development version
(https://github.com/darold/ora2pg/archive/master.zip) where the issue
should be fixed.  If not, you should try to open an issue on
https://github.com/darold/ora2pg/issues.




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux