From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Marco Colombo <pgsql(at)esiway(dot)net> |
Cc: | Michael Fuhr <mike(at)fuhr(dot)org>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: plpython function problem workaround |
Date: | 2005-03-17 15:04:51 |
Message-ID: | 20050317150451.GD2609@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Thu, Mar 17, 2005 at 01:03:36PM +0100, Marco Colombo wrote:
> OMG! It's indenting the funtion body. I think you can't do that
> w/o being syntax-aware. I'm not familiar with the code, why is it
> adding a 'def' in front of it at all? I undestand that once you do
> it you'll have to shift the code by an indentation level.
Presumbly because it wants to create a function, which can later be
called. Since python is sensetive to whitespace it has to indent the
code to make it work.
There was an example on the web somewhere (the link has been posted to
this list) of a peice of python which you can load into the interpreter
which will allow it to accept \r\n terminated lines. I don't recall if
anyone actually tried it out or not...
Won't fix the indenting problem though...
--
Martijn van Oosterhout <kleptog(at)svana(dot)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.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2005-03-17 15:17:17 | Re: pg_dump large-file support > 16GB |
Previous Message | Marco Colombo | 2005-03-17 14:57:44 | Re: pg_dump large-file support > 16GB |