[ADMIN] parametrized query

2004-04-28 Thread Ben Kim
I tried but couldn't find an answer if this is possible in psql. Create a file named test.sql select * from mytable where id = ? (or use $1, $2...) Then in psql do \i test.sql 337 to achieve the same effect select * from mytable where id=337 as I would in perl $sth =

Re: [ADMIN] parametrized query

2004-04-28 Thread Andreas Schmitz
Put it into a shell script like echo select * from mytable where id = $1; | psql $DBNAME That can be executed using the shell function in psql \! [COMMAND] execute command in shell or start interactive shell regards, -Andreas On Wednesday 28 April 2004 17:46, Ben Kim wrote: I tried but

[ADMIN] postgresql 7.4.2 binary for Red Hat Enterprise Linux 2.1

2004-04-28 Thread Christopher Smith
Are there any binaries for the Red Hat Enterprise Linux 2.1.The OSshipped with Postgresql 7.1.3... I would like to upgrade. Are there any suggestions? Thanks Do you Yahoo!?Win a $20,000 Career Makeover at Yahoo! HotJobs

[ADMIN] Perl stored procedures

2004-04-28 Thread Rahul k
Im looking for some documentation on writing stored procedures using PL/Perl. The PostrgeSQL tutorials give only a brief introduction to this which is good but enough : http://www.postgresql.org/docs/7.4/static/plperl.html Can anyone pls send any links to more documentation. Thanks

Re: [ADMIN] postgresql 7.4.2 binary for Red Hat Enterprise Linux 2.1

2004-04-28 Thread Tom Lane
Christopher Smith [EMAIL PROTECTED] writes: Are there any binaries for the Red Hat Enterprise Linux 2.1. The OS shipped with Postgresql 7.1.3... I would like to upgrade. Are there any suggestions? Get a more recent SRPM and do rpmbuild --rebuild. I haven't tried it but I know of no reason it

Re: [ADMIN] [JDBC] [PERFORM] is a good practice to create an index on the

2004-04-28 Thread Christopher Kings-Lynne
do you mean that, declaring an index serial, I'd never have to deal with incrementing its primary key? good to know! Yep. You can use 'DEFAULT' as the value, eg: INSERT INTO blah (DEFAULT, ...); anyway in this particular situation I don't need such accurate behaviour: this table is filled up

Re: [ADMIN] [JDBC] [PERFORM] is a good practice to create an index on the

2004-04-28 Thread Edoardo Ceccarelli
do you mean that, declaring an index serial, I'd never have to deal with incrementing its primary key? good to know! anyway in this particular situation I don't need such accurate behaviour: this table is filled up with a lot of data twice per week and it's used only to answer queries. I could

Re: [ADMIN] [JDBC] [PERFORM] is a good practice to create an index on the

2004-04-28 Thread Bruno Wolff III
On Wed, Apr 28, 2004 at 10:13:14 +0200, Edoardo Ceccarelli [EMAIL PROTECTED] wrote: do you mean that, declaring an index serial, I'd never have to deal with incrementing its primary key? good to know! That isn't what is happening. Serial is a special type. It is int plus a default rule

[ADMIN] 7.4.2 out of memory

2004-04-28 Thread Jie Liang
All, After I upgraded postgres from 7.3.4 to 7.4.2, one of my program got following error: DRROR: out of memory DETAIL: Fail on request of size 92. any idea?? does memory management have big difference between 7.3.4 and 7.4.2??? this program using a chunk of share memory and a lot of temp