1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

  2. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

How to calculate total sum in one field in progress 4GL?

Discussão em 'StackOverflow' iniciado por fdantas, Março 17, 2019.

  1. fdantas

    fdantas Administrator Moderador

    I have written a query for calculating total sum in one field but i could get total records. Let me share what i written.

    DEFINE VARIABLE I AS INTEGER NO-UNDO.
    FIND FIRST shth_pus_head WHERE shth_pus_head.push_id = "P0000078" NO-LOCK
    NO-ERROR.
    FOR EACH shtd_pus_det OF shth_pus_head NO-LOCK:
    i = i + 1.
    END.
    DISPLAY i.


    What i need is when i calculate total sum in qty column i want sum = 1560.

    (Note- qty column table field is shtd_pus_det.qty)

    Check the attached image

    Continue reading...

Compartilhe esta Página