Simple function

From: Christine Penner <christine(at)ingenioussoftware(dot)com>
To: Postgres-General <pgsql-general(at)postgresql(dot)org>
Subject: Simple function
Date: 2009-12-23 17:03:01
Message-ID: 19740415045640.C920234767BE8688@edmwaa02.telusplanet.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I'm trying to create a simple function but having a bit of trouble.
This is what I want to do.

I want to pass a key as a parameter (BKEY integer)
the code in the function should be
count(*) from F_BUILDINGS where B_PRIMARY_SEQ=BKEY

I want to return the count from the select statement.

Christine Penner
Ingenious Software
250-352-9495
<mailto:christine(at)ingenioussoftware(dot)com>christine(at)ingenioussoftware(dot)com

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Adrian Klaver 2009-12-23 17:14:38 Re: Simple function
Previous Message Tom Lane 2009-12-23 15:21:17 Re: reindex