From: TJ O'Donnell <tjo@acm.org>
To: stephen.quinney@computing-services.oxford.ac.uk
Cc: pgsql-sql@postgresql.org
Date: Fri, 15 Apr 2005 05:52:52 -0700 (PDT)
Message-ID: <1168.12.10.164.2.1113569572.squirrel@gnova.com> (raw)
There some documentation about aggregate functions in the manual, for example:
http://www.postgresql.org/docs/7.4/static/sql-createaggregate.html
Here's a simple agg function that should work for you,
assuming your col types are int4.
CREATE AGGREGATE andsum (
sfunc = int4and,
basetype = int4,
stype = int4
);
TJ
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: tjo@acm.org, stephen.quinney@computing-services.oxford.ac.uk
Subject: Re:
In-Reply-To: <1168.12.10.164.2.1113569572.squirrel@gnova.com>
* 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