pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Joseph Syjuco <joseph@asti.dost.gov.ph>
To: postgres <pgsql-sql@postgresql.org>
Subject: assign count() result to a declared variable in plpgsql
Date: 24 Jun 2002 11:25:30 -0400
Message-ID: <1024932336.15861.8.camel@Askr> (raw)


i want to put my count() result in a plpgsql declared integer variable


declare f_count_var integer;
begin
	select into f_count_var count(empno) from employee
end;

tried this one but it doesnt work












view thread (3+ messages)  latest in thread

Message-ID: <1024932336.15861.8.camel@Askr>
Permalink:  ../1024932336.15861.8.camel@Askr/
Also on:    postgresql.org/message-id/1024932336.15861.8.camel@Askr

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: joseph@asti.dost.gov.ph
  Subject: Re: assign count() result to a declared variable in plpgsql
  In-Reply-To: <1024932336.15861.8.camel@Askr>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox