Re: [BUGS] 7.2 crash...

2002-04-15 Thread Bruce Momjian
I have applied a patch based on Tom's suggestion that will disable VACUUM in a function in 7.3. --- Rod Taylor wrote: > 7.2 crashes with the below function: > > CREATE OR REPLACE FUNCTION runMaintenance() > RETURNS BOOL AS

Re: [BUGS] 7.2 crash...

2002-04-14 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Oops, I see now. How is this? Better. A comment explaining what the thing is doing would help too. regards, tom lane ---(end of broadcast)--- TIP 6: Have you searched our list a

Re: [BUGS] 7.2 crash...

2002-04-14 Thread Bruce Momjian
Oops, I see now. How is this? Remember, I am not incredibly capable, just persistent. :-) --- Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > *** src/backend/commands/vacuum.c 12 Apr 2002 20:38:25 -

Re: [BUGS] 7.2 crash...

2002-04-14 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > *** src/backend/commands/vacuum.c 12 Apr 2002 20:38:25 - 1.223 > --- src/backend/commands/vacuum.c 14 Apr 2002 16:41:37 - > *** > *** 181,186 > --- 181,189 > if (IsTransactionBlock()) > elog(

Re: [BUGS] 7.2 crash...

2002-04-14 Thread Bruce Momjian
Here is a patch with a fix outlined by Tom: test=> CREATE OR REPLACE FUNCTION runMaintenance() test-> RETURNS BOOL AS ' test'> VACUUM; test'> SELECT TRUE; test'> ' LANGUAGE sql; CREATE test=> test=> select runMaintenanc

Re: [BUGS] 7.2 crash...

2002-03-21 Thread Bruce Momjian
Tom Lane wrote: > "Rod Taylor" <[EMAIL PROTECTED]> writes: > > 7.2 crashes with the below function: > > CREATE OR REPLACE FUNCTION runMaintenance() > > RETURNS BOOL AS ' > > VACUUM; > > SELECT TRUE; > > ' LANGUAGE sql; > > AFAICS there is no way that we can support VACUUM inside a function; >

Re: [BUGS] 7.2 crash...

2002-03-21 Thread Tom Lane
"Rod Taylor" <[EMAIL PROTECTED]> writes: > 7.2 crashes with the below function: > CREATE OR REPLACE FUNCTION runMaintenance() > RETURNS BOOL AS ' > VACUUM; > SELECT TRUE; > ' LANGUAGE sql; AFAICS there is no way that we can support VACUUM inside a function; the forced transaction commits that

Re: [BUGS] 7.2 crash...

2002-03-19 Thread Tom Lane
"Rod Taylor" <[EMAIL PROTECTED]> writes: > 7.2 crashes with the below function: > CREATE OR REPLACE FUNCTION runMaintenance() > RETURNS BOOL AS ' > VACUUM; > SELECT TRUE; > ' LANGUAGE sql; Ugh. The problem is that VACUUM's implicit CommitTransaction calls wipe out all the transient memory a

[BUGS] 7.2 crash...

2002-03-19 Thread Rod Taylor
7.2 crashes with the below function: CREATE OR REPLACE FUNCTION runMaintenance() RETURNS BOOL AS ' VACUUM; SELECT TRUE; ' LANGUAGE sql; I was going to toss a bunch of system maintenance stuff in a database function to make administration for those who administer the boxes (not me -- I just t