From: Volker Paul <vpaul@dohle.com>
To: Francisco Hernandez <xy0xy0@earthlink.net>
Cc: pgsql-sql@postgresql.org
Cc: pgsql-general@postgresql.org
Subject: Re: [SQL] variables in SQL??
Date: Wed, 16 Aug 2000 13:39:24 +0200
Message-ID: <399A7D6C.20593252@dohle.com> (raw)
References: <000f01c0074f$4dcd87e0$700c2304@francisco>
> what im trying to do is have a Sum of a colum.. as it goes forwards with the
> cursor..
> like so:
>
> Price|Sum
> 5|5
> 4|9
> 10|19
> 2|21
> 7|28
I think what you mean is called running sum, I had the same problem
before, and I found no other solution than creating a column for it,
and calculating its values by a function.
Yours,
V.Paul
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: vpaul@dohle.com, xy0xy0@earthlink.net, pgsql-general@postgresql.org
Subject: Re: [SQL] variables in SQL??
In-Reply-To: <399A7D6C.20593252@dohle.com>
References: <000f01c0074f$4dcd87e0$700c2304@francisco> <399A7D6C.20593252@dohle.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