assign count() result to a declared variable in plpgsql - Mailing list pgsql-sql

From Joseph Syjuco
Subject assign count() result to a declared variable in plpgsql
Date
Msg-id 1024932336.15861.8.camel@Askr
Whole thread Raw
Responses Re: assign count() result to a declared variable in plpgsql  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: assign count() result to a declared variable in plpgsql  (Jeff Eckermann <jeff_eckermann@yahoo.com>)
List pgsql-sql
i want to put my count() result in a plpgsql declared integer variable


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

tried this one but it doesnt work











pgsql-sql by date:

Previous
From: Christoph Haller
Date:
Subject: Re: rowtype and ecpg
Next
From: Denis
Date:
Subject: Re: slow DELETE queries