Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id 02E199FB2F2 for ; Tue, 3 Oct 2006 11:50:06 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 19178-09-2 for ; Tue, 3 Oct 2006 14:49:44 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey- Received: from wolff.to (wolff.to [66.93.197.194]) by postgresql.org (Postfix) with SMTP id 2769A9FB2EA for ; Tue, 3 Oct 2006 11:49:43 -0300 (ADT) Received: (qmail 30292 invoked by uid 500); 3 Oct 2006 14:59:58 -0000 Date: Tue, 3 Oct 2006 09:59:58 -0500 From: Bruno Wolff III To: Rodrigo Sakai Cc: pgsql-sql@postgresql.org Subject: Re: SEQUENCES Message-ID: <20061003145958.GA29003@wolff.to> Mail-Followup-To: Bruno Wolff III , Rodrigo Sakai , pgsql-sql@postgresql.org References: <001801c6e641$6093f5d0$4700a8c0@TREEZANTHUS> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001801c6e641$6093f5d0$4700a8c0@TREEZANTHUS> User-Agent: Mutt/1.4.2.1i X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200610/20 X-Sequence-Number: 26409 On Mon, Oct 02, 2006 at 13:39:38 -0300, Rodrigo Sakai wrote: > Hi all, > > > > I need to get all sequences and their respective current values! Is there > any catalog table or any other away to get this??? You can get their names from pg_class (with relkind = 'S') and then iterate over the names and look at the table underlying each table (at last_value).