Re: [GENERAL] stored procedure multiple call call question

2012-10-03 Thread Chris McDonald
Thanks very much for that David - really appreciate your response - it works like a dream c On Tuesday, 2 October 2012 19:42:59 UTC+1, Chris McDonald wrote: > Hi, > > > > > > If I had a single table targ to insert into I would do an > > > > INSERT

Re: [GENERAL] stored procedure multiple call call question

2012-10-02 Thread Chris McDonald
my apologies - forgot to say I am on postgresql 8.4.9 on Fedora Linux x86_64 c -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] stored procedure multiple call call question

2012-10-02 Thread Chris McDonald
Hi, If I had a single table targ to insert into I would do an INSERT INTO targ SELECT thiscol, thatcol, theothercol FROM FOO. The problem is that I have tables targ1, targ2, targn to insert things into and a nice stored procedure myproc which does the insertion into all 3 tables - problem i

Re: [GENERAL] plpgsql Difference in behaviour between versions?

2011-11-23 Thread Chris McDonald
OK, I see it is the term open which fails the syntax checker - I guessed this might be because open is a reserved word but http://www.postgresql.org/docs/9.0/interactive/sql-keywords-appendix.html does not indicate whether open is either reserved or not in postgresql. Checking 8.4 doco, http:/

[GENERAL] plpgsql Difference in behaviour between versions?

2011-11-23 Thread Chris McDonald
Hi, I am upgrading a system from postgresql 8.4.8 (fedora 13 x64) to postgresql 9.0.5 (fedora 15 x64). As I build a database I've noticed that the following works on 8.4.8 but does not work on 9.0.5. Can someone tell me why this is not legal syntax in 9.0.5 but is legal in 8.4.8 please: ===snip

Re: [GENERAL] Query very slow when in plpgsql function

2010-01-01 Thread Chris McDonald
Thanks for your assistance guys, and special thanks to Greg for his blog page. This is exactly my problem which is resolved using dynamic SQL. I can now see how the function was behaving badly, and have been able to fix the query. Once again, thanks guys - and Happy New Year from a snow-covered pa

[GENERAL] Query very slow when in plpgsql function

2009-12-31 Thread Chris McDonald
Hi everyone. I am using postgresql 8.3.7 on Fedora Core 10. I have 1 table called evaluation which contains about 1 million records, and another called evaluationentry which contains about 9 million records. evaluationentry.veto and evaluation.relevancedt both have indexes on them. I have run ANAL

[GENERAL] Best way to import a plpythonu module

2008-11-22 Thread Chris McDonald
I am using plpythonu on linux version postgresql-plpython-8.2.9-1.fc7. Consider a python class called Wibble which is written into a python module wibble.py. I wish to use Wibble from within a plpythonu procedure. If I simply do: from wibble import Wibble then I am told the object was not found