Received: from nsi.edu (amethea.nsi.edu [198.133.185.9]) by hub.org (8.9.1/8.8.8) with ESMTP id OAA05964 for ; Fri, 23 Oct 1998 14:55:53 -0400 (EDT) (envelope-from reina@nsi.edu) Received: from nsi.edu (IDENT:reina@bigred.nsi.edu [204.128.156.214]) by nsi.edu (8.9.1/8.9.1) with ESMTP id LAA11589; Fri, 23 Oct 1998 11:55:49 -0700 (PDT) Sender: reina@nsi.edu Message-ID: <3630D1A0.BBCD1F46@nsi.edu> Date: Fri, 23 Oct 1998 11:57:36 -0700 From: "G. Anthony Reina" Organization: The Neurosciences Institute X-Mailer: Mozilla 4.05 [en] (X11; I; Linux 2.0.34 i686) MIME-Version: 1.0 To: reina@nsi.edu, "pgsql-questions@postgresql.org" Subject: Reading and writing at the same time Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit I know that Postgres has table-level locking so that once a write is being performed on a table, no other reads or writes can be performed until that write finishes. I have a C program that performs several updates and inserts to a table. I found that I am able, despite any table locking, to use the front-end psql program at the same time to select data from the same table that is being written to. So in essence, I am able to have one program that is writing while at the same time another program reads (without running into aborted backends). So with table-level locking, does the postmaster completely abort any backends that make a request while a write is being done; or, does the postmaster simply tell the other backends to hold for a few seconds until the write is completed and then let the new backend process? -Tony Reina