Re: [GENERAL] Performance problem with correlated sub-query

2004-04-29 Thread Shridhar Daithankar
Howard, Steven (US - Tulsa) wrote: I have created a web app that stores and displays all the messages from my database maintenance jobs that run each night. The web app uses Java servlets and has PostgreSQL 7.0 as the back end. When the user requests the first page, he gets a list of all the ser

Re: [GENERAL] Performance problem with correlated sub-query

2004-04-29 Thread Howard, Steven (US - Tulsa)
Tulsa) Cc: pgsql-general @ postgresql . org Subject: Re: [GENERAL] Performance problem with correlated sub-query On 29/04/2004 14:34 "Howard, Steven (US - Tulsa)" wrote: > I have created a web app that stores and displays all the messages from > my database maintenance jobs that ru

Re: [GENERAL] Performance problem with correlated sub-query

2004-04-29 Thread Paul Thomas
On 29/04/2004 14:34 "Howard, Steven (US - Tulsa)" wrote: I have created a web app that stores and displays all the messages from my database maintenance jobs that run each night. The web app uses Java servlets and has PostgreSQL 7.0 as the back end. 7.0? That's positively ancient! When the user req

Re: [GENERAL] Performance problem with correlated sub-query

2004-04-29 Thread Stephan Szabo
On Thu, 29 Apr 2004, Howard, Steven (US - Tulsa) wrote: > I have created a web app that stores and displays all the messages from > my database maintenance jobs that run each night. The web app uses Java > servlets and has PostgreSQL 7.0 as the back end. Step 1 is upgrade. ;) > However, if the w

Re: [GENERAL] Performance problem with correlated sub-query

2004-04-29 Thread Mike Mascari
Howard, Steven (US - Tulsa) wrote: select servername, databasename, message from messages o where o.date_of_msg = (select max(date_of_msg) from messages i where i.servername = o.servername); And this is a dog. It takes 15 – 20 minutes to execute the query (there are about 200,000 rows in the table)

[GENERAL] Performance problem with correlated sub-query

2004-04-29 Thread Howard, Steven (US - Tulsa)
I have created a web app that stores and displays all the messages from my database maintenance jobs that run each night. The web app uses Java servlets and has PostgreSQL 7.0 as the back end.   When the user requests the first page, he gets a list of all the servers with maintenance reco