Results 1 to 3 of 3

Thread: How to find sum

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2008
    Posts
    2

    How to find sum

    AccountNo.....Date........Amount
    1..................1/25/2008...500
    1..................1/26/2008...500
    1..................1/27/2008...500
    1..................1/27/2008...500
    1..................1/28/2008...500

    I have a table named Table1 that has following structure.
    I take three parameters from users as Starting Date , Ending Date and Account No
    for example if user give the follwing parameters
    Account No = 1
    Starting Date = 1/27/2008
    Ending Date = 1/28/2008

    result of Report
    AccountNo.....Date........Amount
    1..................1/27/2008...500
    1..................1/27/2008...500
    1..................1/28/2008...500


    Total Amount = 1500

    Now the problem is i want to show the last previous Sum of this account too
    for example in this case previous Balance will be

    Previous Balance = 1000

    plz guide me how can i take out prevous balance in Ctystal Report

  2. #2
    Frenzied Member
    Join Date
    Aug 2006
    Location
    India, Punjab, Bhatinda
    Posts
    1,689

    Re: How to find sum

    Now the problem is i want to show the last previous Sum of this account too
    for example in this case previous Balance will be

    Previous Balance = 1000
    what do you mean by previous balance and how would anybody know what was the prev transaction (unless you are holding the same in another table or something)
    pls elaborate...

  3. #3
    Frenzied Member
    Join Date
    May 2006
    Location
    some place in the cloud
    Posts
    1,886

    Re: How to find sum

    Try inserting a numeric formula
    Code:
    WhileReadingRecords;
    numberVar Balance := Balance + {Table1.Amount};

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width