EOL on OS X

Lists: Postg배트맨 토토SQL
From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: PostgreSQL-ports <pgsql-ports(at)postgreSQL(dot)org>
Subject: EOL on OS X
Date: 2003-04-18 23:38:41
Message-ID: 200304182338.h3INcfR04165@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: Postg배트맨 토토SQL

What is the default end-of-line character on OS X? 7.4 COPY will
support \n, \r, and \r\n, and I need to know that to use as a default on
OS X.

--
Bruce Momjian | http://candle.pha.pa.us
pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
+ If your life is a hard drive, | 13 Roberts Road
+ Christ can be your backup. | Newtown Square, Pennsylvania 19073


From: "Henry B(dot) Hotz" <hotz(at)jpl(dot)nasa(dot)gov>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-ports <pgsql-ports(at)postgresql(dot)org>
Subject: Re: EOL on OS X
Date: 2003-04-19 00:36:43
Message-ID: p05111702bac649b4a827@[137.78.212.225]
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-ports

At 7:38 PM -0400 4/18/03, Bruce Momjian wrote:
>What is the default end-of-line character on OS X? 7.4 COPY will
>support \n, \r, and \r\n, and I need to know that to use as a default on
>OS X.

Traditional Mac is to use \r. However OSX is really Unix underneath
where Postgres works so I think it would be better to stick with \n.
I don't know exactly what they are doing, but I've noticed that OSX
applications don't seem to have a problem with \n in text files the
way they did under OS9.

AFAIK only Windows uses the \r\n combination.
--
The opinions expressed in this message are mine,
not those of Caltech, JPL, NASA, or the US Government.
Henry(dot)B(dot)Hotz(at)jpl(dot)nasa(dot)gov, or hbhotz(at)oxy(dot)edu


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Henry B(dot) Hotz" <hotz(at)jpl(dot)nasa(dot)gov>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, PostgreSQL-ports <pgsql-ports(at)postgresql(dot)org>
Subject: Re: EOL on OS X
Date: 2003-04-19 00:43:17
Message-ID: 18291.1050712997@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-ports

"Henry B. Hotz" <hotz(at)jpl(dot)nasa(dot)gov> writes:
> At 7:38 PM -0400 4/18/03, Bruce Momjian wrote:
>> What is the default end-of-line character on OS X? 7.4 COPY will
>> support \n, \r, and \r\n, and I need to know that to use as a default on
>> OS X.

> Traditional Mac is to use \r. However OSX is really Unix underneath
> where Postgres works so I think it would be better to stick with \n.

Yeah. I'd concur with accepting bare \r as newline, but not ever using
it as default.

regards, tom lane