X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D73B4D1B1B3 for ; Thu, 22 Jul 2004 02:31:38 -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 27616-10 for ; Thu, 22 Jul 2004 05:31:35 +0000 (GMT) Received: from anchor-post-30.mail.demon.net (anchor-post-30.mail.demon.net [194.217.242.88]) by svr1.postgresql.org (Postfix) with ESMTP id D093CD1B377 for ; Thu, 22 Jul 2004 02:31:28 -0300 (ADT) Received: from lfix.demon.co.uk ([80.177.205.209] helo=cerberus.lfix.co.uk) by anchor-post-30.mail.demon.net with esmtp (Exim 3.35 #1) id 1BnWB3-000FTF-0U; Thu, 22 Jul 2004 06:31:33 +0100 Received: from linda.lfix.co.uk ([192.168.1.1]) by cerberus.lfix.co.uk with esmtp (Exim 4.34) id 1BnWAo-0002kk-Mh; Thu, 22 Jul 2004 06:31:18 +0100 Subject: Re: next integer in serial key From: Oliver Elphick Reply-To: olly@lfix.co.uk To: Kenneth Gonsalves Cc: pgsql-sql@postgresql.org In-Reply-To: <0407220815420P.01150@thenilgiris.com> References: <0407220815420P.01150@thenilgiris.com> Content-Type: text/plain Organization: LFIX Limited Message-Id: <1090474278.25749.173.camel@linda> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 Date: Thu, 22 Jul 2004 06:31:18 +0100 Content-Transfer-Encoding: 7bit X-LFIX-MailScanner: Found to be clean X-MailScanner-From: olly@lfix.co.uk X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200407/168 X-Sequence-Number: 18420 On Thu, 2004-07-22 at 03:45, Kenneth Gonsalves wrote: > hi, > how does one get the next number in a serial type row? When inserting a new row, do not mention the serial column in the list of columns, or else give it the value DEFAULT. -- Oliver Elphick olly@lfix.co.uk Isle of Wight http://www.lfix.co.uk/oliver GPG: 1024D/A54310EA 92C8 39E7 280E 3631 3F0E 1EC0 5664 7A2F A543 10EA ======================================== "Then Peter and the other apostles answered and said, We ought to obey God rather than men." Acts 5:29