X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id B5915D1B4F6; Mon, 20 Oct 2003 17:51:33 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 72397-07; Mon, 20 Oct 2003 14:51:03 -0300 (ADT) Received: from fuji.krosing.net (217-159-136-226-dsl.kt.estpak.ee [217.159.136.226]) by svr1.postgresql.org (Postfix) with ESMTP id 095ACD1B51E; Mon, 20 Oct 2003 14:50:58 -0300 (ADT) Received: from fuji.krosing.net (localhost.localdomain [127.0.0.1]) by fuji.krosing.net (8.12.8/8.12.8) with ESMTP id h9KHoWqJ005597; Mon, 20 Oct 2003 20:50:35 +0300 Received: (from hannu@localhost) by fuji.krosing.net (8.12.8/8.12.8/Submit) id h9KHoMb4005595; Mon, 20 Oct 2003 20:50:22 +0300 X-Authentication-Warning: fuji.krosing.net: hannu set sender to hannu@tm.ee using -f Subject: Re: [PERFORM] Low Insert/Update Performance From: Hannu Krosing To: Rhaoni Chiu Pereira Cc: PostgreSQL ADMIN , PostgreSQL Performance In-Reply-To: <1066659206.3f93ed86b9907@sistemica.info> References: <1066659206.3f93ed86b9907@sistemica.info> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1066672221.5434.5.camel@fuji.krosing.net> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.5 Date: Mon, 20 Oct 2003 20:50:22 +0300 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200310/262 X-Sequence-Number: 10823 Rhaoni Chiu Pereira kirjutas E, 20.10.2003 kell 17:13: > Hi List, > > I got a P4 1.7Ghz , 512MB RAM , HD 7200 RPM, on RED HAT 9 running PostgreSQL > 7.3.2-3 Database. > I have a Delphi aplication that updates the Oracle database using .dbf > file's information ( converting the data from the old clipper aplication ) and > it takes about 3min and 45 seconds to update Jan/2003 . Have you tried contrib/dbase to do the same ? How fast does this run > My problem is that I must substitute this Oracle for a PostgreSQL database > and this same Delphi aplication takes 45 min to update Jan/2003. > All delphi routines are converted and optmized to work with PgSQL. Could it be that you try to run each insert in a separate transaction in PgSQL version ? Another possibility is that there is a primary key index created on empty tables which is not used in subsequent UNIQUE tests when tables start to fill and using index would be useful. An ANALYZE in a parallel backend could help here. Same can be true for foreign keys and unique constraints. --------------- Hannu