Skip to Content
0
Former Member
Jun 11, 2007 at 11:58 AM

How improving the performances of a report

8 Views

Hi expert!

I have this scenario:

<b>data: begin of tab1 occurs 0,

tipval(3) type n,

mat(18) type c,

anno(4) type n,

mese(2) type n,

eser(4) type n,

per(3) type n,

vpro(6) type c,

div(3) type c,

um(3) type c,

imp(9) type p decimals 2,

qty(9) type p decimals 3,

end of tab1.

data: begin of tab2 occurs 0,

tipval(3) type n as key,

mat(18) type c,

zmat(18) type c,

anno(4) type n,

mese(2) type n,

vpro(6) type c,

org(4) type c,

can(2) type c,

set(2) type c,

all(10) type c,

cpd(10) type c,

grp1(10) type c,

sgr(10) type c,

clf(10) type c,

clc(10) type c,

com(10) type c,

div(3) type c,

um(3) type c,

umb(3) type c,

imp(9) type p decimals 2,

qty(9) type p decimals 3,

qtyf(9) type p decimals 3,

end of tab2.

data: begin of tab3 occurs 0,

tipval(3) type n,

anno(4) type n,

mese(2) type n,

mat(18) type c,

zmat(18) type c,

vpro(6) type c,

org(4) type c,

can(2) type c,

set(2) type c,

all(10) type c,

cpd(10) type c,

grp1(10) type c,

sgr(10) type c,

clf(10) type c,

clc(10) type c,

com(10) type c,

div(3) type c,

um(3) type c,

umb(3) type c,

imp(9) type p decimals 2,

qtyf(9) type p decimals 3,

qty(9) type p decimals 3,

end of tab3.

loop at tab2.

loop at tab1 where mat = tab2-mat

and mese = tab2-mese

and anno = tab2-anno.

tab3-imp = ( tab1-imp / tab1-qty ) * tab2-qtyf.

tab3-tipval = '100'.

tab3-mat = tab2-mat.

tab3-zmat = tab2-zmat.

................

collect tab3.

endloop.

endloop.</b>

How I can improve the performances of this report?

Could you show me some efficient alternatives?

The system is very very slow when it executes this code.

Help me please.

Thanks in advance.

C.