Re: [GENERAL] planer picks a bad plan (seq-scan instead of index) when adding an additional join

2006-11-09 Thread Tom Lane
I wrote: > This didn't matter a whole lot back when the planner couldn't reorder > outer joins, but now that it can, it's more important that the estimates > be accurate. > I'm not sure if this is feasible to fix before 8.2, but I'll take a > look. Actually, the changes were far more localized th

Re: [GENERAL] zero values in statistic views

2006-11-09 Thread Tom Lane
Cornelia Boenigk <[EMAIL PROTECTED]> writes: > I would like to see what is going on in a database using the statistic > views. > I am superuser, > stats_start_collector = on > stats_row_level = on > stats_block_level = on That all looks OK, but it sounds like the stats collector is not running a

Re: [GENERAL] Remote tables infrastructure.

2006-11-09 Thread Tom Lane
"Dawid Kuroczko" <[EMAIL PROTECTED]> writes: > Methinks it would be good idea to discuss a more general approach, > i.e. don't "create" links using existing infrastructure but rather > provide something conceptually similar to CREATE AGGREGATE statements. > In other words, make a remote link a fir

Re: [GENERAL] AutoVacuum on demand?

2006-11-09 Thread Richard Broersma Jr
> Cron yes, vacuumdb no. I would like to AUTO vacuum periodically. Just curious, what is auto_vacuum going to give that vacuumdb wont? Regards, Richard Broersma Jr. ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] dblink / plpgsql - definition list cheats for record

2006-11-09 Thread Matthew Peter
--- Richard Huxton wrote: > Matthew Peter wrote: > > Is there any way to use CREATE TYPE or an VIEW/TABLE defintion list instead > > of > > manually defining it? > > Yes, just define your function as returning that type rather than > RECORD. That way the calling context will know what to expe

Re: [GENERAL] RULE - special variables?

2006-11-09 Thread Matthew Peter
--- Richard Huxton wrote: > Matthew Peter wrote: > > Do rules get special variables like triggers? Can I set variables in them > > like > > triggers? > > You get NEW/OLD but they mean something subtly different. Rules act on a > query-tree so they are more like placeholders. > > You can't s

Re: [GENERAL] planer picks a bad plan (seq-scan instead of index) when adding an additional join

2006-11-09 Thread Thomas H.
I wrote: This didn't matter a whole lot back when the planner couldn't reorder outer joins, but now that it can, it's more important that the estimates be accurate. I'm not sure if this is feasible to fix before 8.2, but I'll take a look. Actually, the changes were far more localized than I

Re: [GENERAL] zero values in statistic views

2006-11-09 Thread Cornelia Boenigk
Tom, thanks for the quick response. stats_row_level and stats_block_level are disabled in postgresql.conf. I used the SET command to activate them. > If it's not running, look in the postmaster log right after > restarting the postmaster; there may be a message there about why > not. I canno

Re: [GENERAL] zero values in statistic views

2006-11-09 Thread Tom Lane
Cornelia Boenigk <[EMAIL PROTECTED]> writes: > stats_row_level and stats_block_level are disabled in postgresql.conf. > I used the SET command to activate them. That's not going to accomplish a lot --- it'll only cause the session you did the SET in to report to the stats collector. You need to

Re: [GENERAL] AutoVacuum on demand?

2006-11-09 Thread Glen Parker
Richard Broersma Jr wrote: Cron yes, vacuumdb no. I would like to AUTO vacuum periodically. Just curious, what is auto_vacuum going to give that vacuumdb wont? Hmm, I thought this would be obvious. Vacuumdb just issues "VACUUM" commands. I would like the get the functionality if autova

Re: [GENERAL] zero values in statistic views

2006-11-09 Thread Cornelia Boenigk
Hi Tom > But you didn't say what the ps output showed. ps aux | grep stats postgres 24979 0.0 0.0 24416 3780 ?SNov07 0:07 postgres: stats buffer process postgres 24980 0.0 0.0 24684 4024 ?SNov07 0:10 postgres: stats collector process Regards Conni ---

Re: [GENERAL] AutoVacuum on demand?

2006-11-09 Thread Richard Broersma Jr
> Richard Broersma Jr wrote: > >> Cron yes, vacuumdb no. I would like to AUTO vacuum periodically. > > Just curious, what is auto_vacuum going to give that vacuumdb wont? > Hmm, I thought this would be obvious. Vacuumdb just issues "VACUUM" > commands. > I would like the get the functionality if

Re: [GENERAL] Remote tables infrastructure.

2006-11-09 Thread Dawid Kuroczko
On 11/10/06, Tom Lane <[EMAIL PROTECTED]> wrote: "Dawid Kuroczko" <[EMAIL PROTECTED]> writes:> Methinks it would be good idea to discuss a more general approach,> i.e.  don't "create" links using existing infrastructure but rather > provide something conceptually similar to CREATE AGGREGATE stateme

Re: [GENERAL] 8.1.2 locking issues

2006-11-09 Thread Ed L.
I have a few questions on pgsql locking terms and such... I created the following view to make viewing the locks a little easier: -- CREATE OR REPLACE VIEW locksview AS -- SELECT l.*, r.*, a.*, now() - a.query_start as query_age, --substring(replace(current_query, '\n', ' '), 1, 30) as

Re: [GENERAL] AutoVacuum on demand?

2006-11-09 Thread Hitoshi Harada
> Since our nightly window of relative inactivity continues to shrink, I'd > like to vacuum/analyze only the tables that autovacuum thinks need it, > all at once, and only when I tell it to (via cron). I thought as you did and posted a thread, where I proposed a C function smartvacuum() which you

[GENERAL] Multiple currencies in a application

2006-11-09 Thread novnov
I'm working on an application that will eventually need to support various currencies. I've never touched this area before, have dealt with dollars till now. I'm not sure what the regular practices are re mulitple currencies in the same application. The app includes calculations like price per un

Re: [GENERAL] 8.1.2 locking issues

2006-11-09 Thread Tom Lane
"Ed L." <[EMAIL PROTECTED]> writes: > Can someone explain why 6508 has a transactionid ExclusiveLock, > but now is waiting on a transactionid ShareLock? That seems > unintuitive. It would seem that if you hold a more exclusive > lock, getting a less exclusive lock would not be a problem. They're

RE : Re: RE : Re: [GENERAL] first steps in PhP and PostgreSQL

2006-11-09 Thread Desmond Coughlan
X-No-Archive: true   Ah...   [Wed Nov 08 09:32:56 2006] [error] [client 192.168.0.254] PHP Fatal error:  Call to undefined function:  pg_connect() in /usr/local/www/data/php_experimental/base.php on line 6   Ben <[EMAIL PROTECTED]> a écrit : No, that's the access log. Check the error log.On

RE : Re: [GENERAL] first steps in PhP and PostgreSQL

2006-11-09 Thread Desmond Coughlan
X-No-Archive: true   Yep...   192.168.0.254 - - [07/Nov/2006:10:12:57 +0100] "GET /php_experimental/base.php HTTP/1.1" 200 - "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" D.Ben <[EMAIL PROTECTED]> a écrit : Have you checked your webserver error logs?On Mon, 6 Nov 2006, Desmond Cou

[GENERAL] postgres at startup

2006-11-09 Thread Michael McCloskey
Title: postgres at startup Postgres is starting automatically for me at startup. When I boot up my machine and then check the running processes I see postmaster.exe and 4 postgres processes. How can I stop this? I don’t want Postgres starting up automatically. Thanks. -Michael

[GENERAL] Linux vs. FreeBSD

2006-11-09 Thread Bart McFarling
We are installing a new Postgresql server, it will not run anything else but postgresql. We are currently looking at moving from a RHEL 4.0 system to FreeBSD. Does one OS offer better performace over the other when running postgresql?   Thanks, Bart  

Re: [GENERAL] 8.1.2 postmaster died

2006-11-09 Thread Ed Loehr
On Wednesday November 8 2006 12:30 pm, Shoaib Mir wrote: > To be specific you need to look at the syslogs to see if it > was actually some OOM killer or not. I checked all db logs + syslog, of course. All they show is the process receiving SIGKILL (followed by all others being shutdown as a res

[GENERAL] LIKE OPERATOR cardinality estimation

2006-11-09 Thread sumit kumar
Can any1 please please help me know how pgsql estimates the cardinality of LIKE operator ??ThanksSumit

[GENERAL] Survey...Please do help and Respond!!

2006-11-09 Thread d-licious
Hi, I am doing a project on the database industry and would appreciate if you all could answer a few questions for me! · What do you think of Oracle providing support for Red Hat Linux? · What database(s) are you currently using, what operating system does it run on, and what database options are

Re: [GENERAL] Problem with pg_dump

2006-11-09 Thread Brent Wood
A. Kretschmer wrote: am Thu, dem 09.11.2006, um 13:04:31 -0500 mailte Alex Turner folgendes: I seem to be having a problem with pg_dump in 8.1.2, it's not dumping indexes at all. Is this a known problem, should I just do an upgrade? I can't see a necessity to dump a index. But, i hop

[GENERAL] how can i prove that this issue on PG 8.0.0 ERROR: index "patient_pkey" is not a btree is solved in 8.0.9

2006-11-09 Thread surabhi.ahuja
hi I am using Postgres 8.0.0 and we found this issue "ERROR:  index "patient_pkey" is not a btree" I have been informed that we should shift to Postgres 8.0.9   I discussed this with my team member and they are asking if we can upgrade to the latest Postgres version i.e. 8.1.5   I have some

Re: [GENERAL] 8.1.2 postmaster died

2006-11-09 Thread Tom Lane
Ed Loehr <[EMAIL PROTECTED]> writes: > Is there any circumstance at all under which pgsql itself would > issue a sigkill to one of the backends? No. Other signals yes, but not SIGKILL. regards, tom lane ---(end of broadcast)--

Re: [GENERAL] LIKE OPERATOR cardinality estimation

2006-11-09 Thread Tom Lane
"sumit kumar" <[EMAIL PROTECTED]> writes: > Can any1 please please help me know how pgsql estimates the cardinality of > LIKE operator ?? See patternsel() and subsidiary routines in http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/selfuncs.c for whichever version you are inte

Re: [GENERAL] AutoVacuum on demand?

2006-11-09 Thread Richard Broersma Jr
> Hmm, I thought this would be obvious. Vacuumdb just issues "VACUUM" > commands. > > I would like the get the functionality if autovacuum so that I don't > waste cycles on tables that don't really need vacuuming. However, we've > had bad luck letting autovacuum run on its own terms, so we've

Re: [GENERAL] blocking function in PL/Python

2006-11-09 Thread Richard Huxton
Ottavio Campana wrote: suppose we have a stored procedure written in PL/Python. What happens if the function blocks for a while? Does the server still works for the other clients? Yes. Each client has its own backend process. Although, if you've taken locks that might block other clients. -

Re: [GENERAL] postgres at startup

2006-11-09 Thread Richard Huxton
Michael McCloskey wrote: Postgres is starting automatically for me at startup. When I boot up my machine and then check the running processes I see postmaster.exe and 4 postgres processes. How can I stop this? I don't want Postgres starting up automatically. On a linux machine, there are a set

Re: [GENERAL] autovacuum blues

2006-11-09 Thread Anton Melser
The idea is that you _can_ do without a cronjob. You may need to do a first ANALYZE just to get things warmed up, and then let autovacuum do its job. Thanks guys, I think I have it now! Cheers Antoine ---(end of broadcast)--- TIP 4: Have you sear

<    1   2