Re: Multiline plpython procedure - Mailing list pgsql-general

From Martijn van Oosterhout
Subject Re: Multiline plpython procedure
Date
Msg-id 20050119122048.GD18648@svana.org
Whole thread Raw
In response to Re: Multiline plpython procedure  (Marco Colombo <pgsql@esiway.net>)
Responses Re: Multiline plpython procedure
List pgsql-general
On Wed, Jan 19, 2005 at 12:20:23PM +0100, Marco Colombo wrote:
> On Tue, 18 Jan 2005, Tom Lane wrote:
> >>followed by linefeed).  On Macintosh, it is the ASCII CR (return)
> >>character."
> >
> >Seems like Guido has missed a bet here: namely the case of a script
> >generated on one platform and fed to an interpreter running on another.
>
> I think you're missing that vendors define what a 'text file' is on their
> platform, not Guido. Guido just says that a Python program is a text file,
> which is a very sound decision, since it makes perfectlty sense to be able
> to edit it with native tools (text editors which do not support alien
> textfile formats).

Sure, some text editors don't. Some text editors do. But the C compiler
accepts programs in any of these formats. And consider multiple
machines working off the same file server. There is no "standard" text
format and everyone should just get along.

The C standard explicitly defines \r and \n as whitespace, thus neatly
avoiding the entire issue. Many other languages do the same. The fact
is the python is the odd one out.

Be liberal in what you receive. After, what's the benefit of having
python source that's not runnable on every computer. Without
conversion.

Hope this helps,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Attachment

pgsql-general by date:

Previous
From: "Peter Haworth"
Date:
Subject: Re: DBD::Pg behavior for large queries
Next
From: Richard Huxton
Date:
Subject: Re: Postgres crashed when adding a sequence column