X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 80958D7377 for ; Wed, 7 Sep 2005 00:27:00 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 74472-04 for ; Wed, 7 Sep 2005 03:26:55 +0000 (GMT) Received: from tigger.fuhr.org (tigger.fuhr.org [63.214.45.158]) by svr1.postgresql.org (Postfix) with ESMTP id B13B6D7C41 for ; Wed, 7 Sep 2005 00:26:53 -0300 (ADT) Received: from winnie.fuhr.org (winnie.fuhr.org [10.1.0.1]) by tigger.fuhr.org (8.13.3/8.13.3) with ESMTP id j873Qmf6035374 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 6 Sep 2005 21:26:51 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: from winnie.fuhr.org (localhost [127.0.0.1]) by winnie.fuhr.org (8.13.3/8.13.3) with ESMTP id j873QmdB010097; Tue, 6 Sep 2005 21:26:48 -0600 (MDT) (envelope-from mfuhr@winnie.fuhr.org) Received: (from mfuhr@localhost) by winnie.fuhr.org (8.13.3/8.13.3/Submit) id j873Qmel010096; Tue, 6 Sep 2005 21:26:48 -0600 (MDT) (envelope-from mfuhr) Date: Tue, 6 Sep 2005 21:26:48 -0600 From: Michael Fuhr To: =?iso-8859-1?Q?Jo=FFffffffffffe3o?= Carvalho Cc: PG-SQL lista de mail Subject: Re: Statistics from Sequences Message-ID: <20050907032648.GA10037@winnie.fuhr.org> References: <20050907024344.19853.qmail@web50606.mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20050907024344.19853.qmail@web50606.mail.yahoo.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.005 required=5 tests=[AWL=0.005] X-Spam-Level: X-Archive-Number: 200509/65 X-Sequence-Number: 22612 On Tue, Sep 06, 2005 at 11:43:44PM -0300, Jo˙ffffffffffe3o Carvalho wrote: > Is it possible to get from a sequence: > > The sequence owner > The min value > The max value > The increment value > The last used number See the output from the following example: CREATE SEQUENCE fooseq; SELECT u.usename FROM pg_class AS c JOIN pg_user AS u ON u.usesysid = c.relowner WHERE c.relname = 'fooseq'; SELECT * FROM fooseq; -- Michael Fuhr