From: | Bill Moran <wmoran(at)potentialtech(dot)com> |
---|---|
To: | schampailler(at)easynet(dot)be |
Cc: | pgsql-performance(at)postgresql(dot)org |
Subject: | Re: Impossibly slow DELETEs |
Date: | 2003-11-25 23:45:08 |
Message-ID: | 3FC3E984.3020508@potentialtech.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
Stefan Champailler wrote:
> Dear You all,
>
> (please tell me if this has already been discussed, I was unable to find any
> convincing information)
>
> I'm developing a small application, tied to a PG 7.4 beta 5 (i didn't
> upgrade). The DB i use is roughly 20 tales each of them containing at most 30
> records (I'm still in development). I can provide a whole dump if necessary.
> I access the DB throug IODBC (Suse Linux 8.1), through PHP. The machine
> everything runs on is 512M of Ram, 2.5GHz speed. So I assume it should be
> blazingly fast.
>
> So here's my trouble : some DELETE statement take up to 1 minute to complete
> (but not always, sometimes it's fast, sometimes it's that slow). Here's a
> typical one : DELETE FROM response_bool WHERE response_id = '125'
> The response_bool table has no foreing key and no index on response_id column.
> No foreign key reference the response_bool table. There are 6 rows in the
> table (given that size, I assumed that an index was not necessary).
>
> So 1 minute to complete look like I did something REALLY bad.
>
> It is my feeling that doing the same query with psql works without problem,
> but I can't be sure.
I think that last sentence is the crux of the problem. If you can establish
for sure that the unreasonable delay is _only_ there when the command is
issued through IODBC, then it's not a Postgresql problem.
Out of curiosity, why are you using ODBC for PHP anyway? PHP has Postgresql
libraries that work very well. I use them quite often without problems.
--
Bill Moran
Potential Technologies
http://www.potentialtech.com
From | Date | Subject | |
---|---|---|---|
Next Message | Neil Conway | 2003-11-25 23:55:33 | Re: Impossibly slow DELETEs |
Previous Message | Tom Lane | 2003-11-25 23:40:47 | Re: Wierd context-switching issue on Xeon |