Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Running Totals in AS400 Query

196 views
Skip to first unread message

excel-ant

unread,
Apr 3, 2007, 4:52:02 PM4/3/07
to
Hi,

Is there a way of creating a running total field in AS400 query
Lets say I have 2 fields
1. Date of Transaction
2. Amount. eg -2000 +50, -55

Date Amount Running Total
01/01/07 200 200
02/01/07 -50 150

I want to create the running total field using the Amount field
programmatically.
I plan to use the define report fields screens.

Any ideas or help appreciated,

Many Thanks,

Ant
AS400 Query Beginner

GB

unread,
Apr 3, 2007, 5:39:00 PM4/3/07
to
excel-ant wrote:
> Hi,
>
> Is there a way of creating a running total field in AS400 query

Nope.

CRPence

unread,
Apr 4, 2007, 11:26:54 PM4/4/07
to
.
IIRC, the Query/38 feature offered that function. That software
comes with OPTION(06) of i5/OS. If that option is installed, CALL QCL,
then issue DSNQRYAPP
Beyond that, I recall almost nothing about it except that F1=Exit.
Thus if your PF1 key is mapped to only Help, be sure to first remap your
keyboard to allow exit/save of the designed query report/application.
If you can create some SQL VIEW that gets the data in rows that the
Query/400 reporting can present, then you could replace the query of the
file with a report of the VIEW -- with or without summary processing in
the query definition, depending on what the VIEW achieves for you. I do
not want my brain to hurt, so I have not given this any thought for the
given example.

Regards, Chuck
-- All comments provided "as is" with no warranties of any kind whatsoever

excel-ant wrote:
> Is there a way of creating a running total field in AS400 query

> Let's say I have 2 fields

CRPence

unread,
Apr 13, 2007, 8:51:10 PM4/13/07
to
.
Correction: The Query/38 software comes with 5722DB1 -- System/38
Utilities. The OPTION(06) of i5/OS provides the S/38 Environment which
enables access to the environment, activated by the call to the QCL
program, where the DSNQRYAPP and QRYDTA commands run.

Regards, Chuck
-- All comments provided "as is" with no warranties of any kind whatsoever.

CRPence wrote:
> IIRC, the Query/38 feature offered that function. That software comes
> with OPTION(06) of i5/OS. If that option is installed, CALL QCL, then
> issue DSNQRYAPP

<<SNIP>>

0 new messages