Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id EF48A64FCE9 for ; Mon, 15 Sep 2008 14:57:22 -0300 (ADT) Received: from postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 30491-06 for ; Mon, 15 Sep 2008 14:57:20 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from rv-out-0506.google.com (rv-out-0506.google.com [209.85.198.226]) by postgresql.org (Postfix) with ESMTP id 42C3864FCE7 for ; Mon, 15 Sep 2008 14:57:20 -0300 (ADT) Received: by rv-out-0506.google.com with SMTP id b25so2958512rvf.43 for ; Mon, 15 Sep 2008 10:57:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=KaU4LSrJ9rKART9Xl+LrV13nk/SRLQNGEYG+bh6S/A4=; b=c14oLN3hgVibGpTWgu4XYSvY9hN5D7EZQKb4LoseDjRkyA2EyqDuYvEFY6L0GpQCP6 NCreiha0Wskpsf7dfqNq7XtX5IW1cIA5kpSATwZl0ev/mHz8RadJLVwqgUwG6IT+W5EQ 4mo/Fy1OaqBUTdIDMIVAZtapxwhILuEWASbyo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=hGapXEBAsZudsioHcuT4H6ws99C6JhuEl6kvYalCI63voidMqKjFCQ2ZJs/+k44V0H eJQ48RgY2zqkeIqjS7kjNJisEnFH0uDqNxtDCq6q0Kkma5ERRORjPkDke/AJaIbIcqal ZrK9krWmqHkg/SCM1NFI3yzJW6Yj97fphiquc= Received: by 10.141.13.16 with SMTP id q16mr4991158rvi.99.1221501439101; Mon, 15 Sep 2008 10:57:19 -0700 (PDT) Received: by 10.141.74.11 with HTTP; Mon, 15 Sep 2008 10:57:19 -0700 (PDT) Message-ID: Date: Mon, 15 Sep 2008 11:57:19 -0600 From: "Scott Marlowe" To: "c k" Subject: Re: [GENERAL] Functions Cc: "Richard Huxton" , pgsql-general@postgresql.org, pgsql-admin@postgresql.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <48CE9674.6020401@archonet.com> 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: 200809/140 X-Sequence-Number: 30233 On Mon, Sep 15, 2008 at 11:53 AM, c k wrote: > > > If I have a function having: > begin > insert into something ... > select max(primary key) from something.. > end; > > does the second statement within a function can view the results after > execution of first statement to get max(P.K.)? Yep.