X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id B0C6952AA6 for ; Wed, 2 Mar 2005 06:45:58 +0000 (GMT) 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 46799-03 for ; Wed, 2 Mar 2005 06:45:49 +0000 (GMT) Received: from floppy.pyrenet.fr (news.pyrenet.fr [194.250.190.2]) by svr1.postgresql.org (Postfix) with ESMTP id 58F4152A4F for ; Wed, 2 Mar 2005 06:45:48 +0000 (GMT) Received: by floppy.pyrenet.fr (Postfix, from userid 106) id 0CA2F32064; Wed, 2 Mar 2005 07:45:49 +0100 (MET) From: stig erikson X-Newsgroups: pgsql.performance Subject: Re: What is the postgres sql command for last_user_id ??? Date: Wed, 02 Mar 2005 07:43:44 +0100 Organization: Hub.Org Networking Services Lines: 21 Message-ID: References: <1109691962.42248e3a3c898@webmail.moph.go.th> Mime-Version: 1.0 Content-Type: text/plain; charset=TIS-620; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@news.hub.org User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8b2) Gecko/20050226 In-Reply-To: <1109691962.42248e3a3c898@webmail.moph.go.th> To: pgsql-performance@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200503/83 X-Sequence-Number: 10788 amrit@health2.moph.go.th wrote: > I would like to know whether there is any command which the server will give the > record ID back to the client when client puts the data and the server generates > an autoincrement ID for that record. > For example if many clients try to put the money data to the server and each > record from each client has its own record ID by autoincrement process of the > server [x+1] and i don't need to lock the record since it will bring the system > to slow down. That client wil then want to know which ID that server gives to > that record in order to select that record to print the reciept [bill]. > I know that in mysql there is a command "last_record_id" which acts the same as > I mention above. Does anybody know that , please give me the detail? > > Amrit,Thailand > > > > ---------------------------(end of broadcast)--------------------------- > TIP 8: explain analyze is your friend > http://www.postgresql.org/docs/8.0/static/functions-sequence.html