Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 74003633952 for ; Wed, 4 Mar 2009 17:53:31 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 30699-05 for ; Wed, 4 Mar 2009 17:53:28 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from el-out-1112.google.com (el-out-1112.google.com [209.85.162.181]) by mail.postgresql.org (Postfix) with ESMTP id 7175E6326B5 for ; Wed, 4 Mar 2009 17:53:28 -0400 (AST) Received: by el-out-1112.google.com with SMTP id y26so3075459ele.10 for ; Wed, 04 Mar 2009 13:53:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=F9DdXsjVXE1RWjOXQMoBaNxetohTXyJngmB9tjB8r4A=; b=Mz3GJzVArWAymHj8qrB4P3Gd6ecCkuhVq/3OL1RK9yXz/8Jpr3Mdo+/QnSIrqbMip5 8UiCEBXPzbQzK4yy9He5UIEdp6w+OpDYljRDquoYpC3kezzZO2AQhBBnLa+K9RhvahUW 6TolZ+2ESF+2JidK4zbfHK7JcZGju71SV5ApQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=b7hGqUetRba5i0Xaioaw31aJE/qJGXY+t9+AbNPUyBDdBbzNwid4tE981P7WqlierF 4NCGFMlOrzm/rNLUiFj8fYlvi4QbV/BNZVgRrjZjdjDT/xAtMTvClldRonQ8neGE351R FUWjhGQGzo/T/nk7gMDtTPBb6IBVYtkm9lo1M= MIME-Version: 1.0 Received: by 10.150.12.10 with SMTP id 10mr896046ybl.126.1236203606925; Wed, 04 Mar 2009 13:53:26 -0800 (PST) In-Reply-To: <1B70D8AC-E1AF-42F2-85D9-92BF3C975ED7@indiana.edu> References: <23817.1236025942@sss.pgh.pa.us> <91CFD986-3CF6-4419-9908-2FEF9C469441@indiana.edu> <28543.1236029013@sss.pgh.pa.us> <27F905C5-A238-446A-A0E8-21174783E46C@indiana.edu> <1730.1236043881@sss.pgh.pa.us> <1B70D8AC-E1AF-42F2-85D9-92BF3C975ED7@indiana.edu> Date: Wed, 4 Mar 2009 14:53:26 -0700 Message-ID: Subject: Re: Database in use? From: Scott Marlowe To: Carol Walter Cc: pgsql-admin@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200903/63 X-Sequence-Number: 31563 On Wed, Mar 4, 2009 at 2:40 PM, Carol Walter wrote: > This has happened or is happening to me again, only this time, it's a > database that I just created. =A0I restored another database into a test > database. =A0One of the tables is empty. =A0I want to drop the test datab= ase and > create a new one. =A0When I try to drop the test database, I get this err= or - > template1=3D# drop database km_tezt; > ERROR: =A0database "km_tezt" is being accessed by other users > > template1=3D# select * from pg_prepared_xacts; > =A0transaction | gid | prepared | owner | database > -------------+-----+----------+-------+---------- > (0 rows) What does "select * from pg_stat_activity say about this db? > This database is one that I created just a few hours ago just to test som= e > things myself. =A0There can be no one in it except me. =A0I completely cl= osed Correct me if I'm wrong, but isn't that enough ((just you) to cause the drop database to fail?