Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-24 Thread Adrian Klaver
On 08/24/2011 10:06 AM, c k wrote: No, I have added the python directory in the PATH. Another thing is I created another language plpython2u and succeeded. Still I will try to figure out the problem. How did you create plpythonu2? Define succeed; the language was created or the languag

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-24 Thread John R Pierce
On 08/24/11 10:33 AM, c k wrote: Server and client both are a single machine. that doesn't answer my question. PATH, like other environment variables, is specific to the process. just because you change the default path of your login account via $HOME/.profile or whatever, doesn't have any

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-24 Thread c k
Server and client both are a single machine. Chaitanya Kulkarni On Wed, Aug 24, 2011 at 10:47 PM, John R Pierce wrote: > On 08/24/11 10:06 AM, c k wrote: > >> I have added the python directory in the PATH. Another thing is I created >> another language plpython2u and succeeded. Still I will try

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-24 Thread John R Pierce
On 08/24/11 10:06 AM, c k wrote: I have added the python directory in the PATH. Another thing is I created another language plpython2u and succeeded. Still I will try to figure out the problem. is it in the PATH that the server is using? the server doesn't know or care anything about the cl

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-24 Thread c k
No, I have added the python directory in the PATH. Another thing is I created another language plpython2u and succeeded. Still I will try to figure out the problem. Regards, Chaitanya Kulkarni On Wed, Aug 24, 2011 at 7:11 PM, Adrian Klaver wrote: > On Tuesday, August 23, 2011 11:10:19 pm c k wr

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-24 Thread Adrian Klaver
On Tuesday, August 23, 2011 11:10:19 pm c k wrote: > Yes, > ImportError: No module named site > ImportError: No module named site > ImportError: No module named site > > This last line is added every time I call any plpython function. Here is > the simple plpython function. > > CREATE OR REPLACE

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-23 Thread c k
Yes, Now I have removed python 2.7. Restarted the postgresql. When I call the above mentioned function, now server doesn't crash. It is running, but I get the error 'No connection to the server'. I am using PgAdmin to work with Postgresql. I tried to execute a simple function to show python version

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-22 Thread Adrian Klaver
On Monday, August 22, 2011 7:24:30 am c k wrote: > No i didn't removed any thing. Only I have installed python 2.6. And then > tried to create plpythonu. It got created, but when tries to execute > already mentioned function server crashes. > > I didn't have any clue. My guess is this is the clu

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-22 Thread c k
No i didn't removed any thing. Only I have installed python 2.6. And then tried to create plpythonu. It got created, but when tries to execute already mentioned function server crashes. I didn't have any clue. Thanks and regards. Chaitany Kulkarni On Sun, Aug 14, 2011 at 12:37 AM, Adrian Klave

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-13 Thread Adrian Klaver
On Saturday, August 13, 2011 8:35:08 am c k wrote: > I am not going to do stack trace right now, because I am using wireless > broadband and is much costlier to download. > But as other functions are working, may be it is related with other thing. > I have forgotten to told that I am using virtual

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-13 Thread c k
I am not going to do stack trace right now, because I am using wireless broadband and is much costlier to download. But as other functions are working, may be it is related with other thing. I have forgotten to told that I am using virtual machine for windows. For even this the normal python interp

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread Craig Ringer
On 11/08/2011 1:00 AM, c k wrote: I have renamed uuid-ossp.dll to 0uuid-ossp.dll in postgresql's lib directory. But it is also found that postgresql's bin directory is not included in the path. It doesn't have to be. On Windows, the directory containing the current executable is implicitly the

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread c k
I have renamed uuid-ossp.dll to 0uuid-ossp.dll in postgresql's lib directory. But it is also found that postgresql's bin directory is not included in the path. Then started the postgresql again, called the same plpython function again and again server crashed without any details in the log. Also se

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-10 Thread Adrian Klaver
On Tuesday, August 09, 2011 10:13:17 pm c k wrote: > Here is the actual function. > create or replace function software.python_test() returns text as > $body$ > import sys > from uuid import getnode as get_mac > mac = get_mac() > return mac > $body$ > language plpythonu volatile security definer; >

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-09 Thread c k
Here is the actual function. create or replace function software.python_test() returns text as $body$ import sys from uuid import getnode as get_mac mac = get_mac() return mac $body$ language plpythonu volatile security definer; When running the same code from python prompt, it run correctly witho

Re: [GENERAL] postgresql server crash on windows 7 when using plpython

2011-08-09 Thread Adrian Klaver
On Tue, Aug 9, 2011 at 7:54 AM, c k wrote: > Dear Friends, > For client requirements, I am testing postgresql 9.0.4 on windows 7 with > plpython. First I installed python 2.7 and then added python installation > path to windows PATH variable. Then installed postgresql from one-click > installer.